From b5d08bd0c486d5fc53859ad454061b8d02fe4218 Mon Sep 17 00:00:00 2001 From: Jordan Sherer Date: Mon, 28 Jan 2019 20:40:40 -0500 Subject: [PATCH] Process GRID commands for everybody --- mainwindow.cpp | 50 +++++++++++++++++++++++++------------------------- 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/mainwindow.cpp b/mainwindow.cpp index 645d68f..e07a655 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -9657,6 +9657,31 @@ void MainWindow::processCommandActivity() { logCallActivity(cd, true); logHeardGraph(d.from, d.to); + // PROCESS BUFFERED GRID FOR EVERYONE + if (d.cmd == " GRID"){ + // 1. parse grids + // 2. log it to reporting networks + auto grids = Varicode::parseGrids(d.text); + foreach(auto grid, grids){ + CallDetail cd = {}; + cd.bits = d.bits; + cd.call = d.from; + cd.freq = d.freq; + cd.grid = grid; + cd.snr = d.snr; + cd.utcTimestamp = d.utcTimestamp; + cd.tdrift = d.tdrift; + + m_aprsCallCache.remove(cd.call); + m_aprsCallCache.remove(APRSISClient::replaceCallsignSuffixWithSSID(cd.call, Radio::base_callsign(cd.call))); + + logCallActivity(cd, true); + } + + // make sure this is explicit + continue; + } + // we're only responding to allcall, groupcalls, and our callsign at this point, so we'll end after logging the callsigns we've heard if (!isAllCall && !toMe && !isGroupCall) { continue; @@ -10084,31 +10109,6 @@ void MainWindow::processCommandActivity() { continue; } - // PROCESS BUFFERED GRID - else if (d.cmd == " GRID"){ - // 1. parse grids - // 2. log it to reporting networks - auto grids = Varicode::parseGrids(d.text); - foreach(auto grid, grids){ - CallDetail cd = {}; - cd.bits = d.bits; - cd.call = d.from; - cd.freq = d.freq; - cd.grid = grid; - cd.snr = d.snr; - cd.utcTimestamp = d.utcTimestamp; - cd.tdrift = d.tdrift; - - m_aprsCallCache.remove(cd.call); - m_aprsCallCache.remove(APRSISClient::replaceCallsignSuffixWithSSID(cd.call, Radio::base_callsign(cd.call))); - - logCallActivity(cd, true); - } - - // make sure this is explicit - continue; - } - #if 0 // PROCESS ALERT else if (d.cmd == "!" && !isAllCall) {