Browse Source

Introduced constant for the "no network" bail out

tags/v1.2.0
Bertrand Lemasle 7 years ago
parent
commit
ba971f712a
2 changed files with 2 additions and 1 deletions
  1. +1
    -0
      GpsTracker/Config.h
  2. +1
    -1
      GpsTracker/Network.cpp

+ 1
- 0
GpsTracker/Config.h View File

@@ -32,6 +32,7 @@

#define NETWORK_DEFAULT_INTERMEDIATE_TIMEOUT_MS 6000
#define NETWORK_DEFAULT_TOTAL_TIMEOUT_MS 180000
#define NETWORK_DEFAULT_NO_NETWORK_TRIES 10

#pragma endregion



+ 1
- 1
GpsTracker/Network.cpp View File

@@ -25,7 +25,7 @@ namespace network {
if (report.ssri == 0) noNetwork++;
else noNetwork = 0;
if (noNetwork > 10) {
if (noNetwork > NETWORK_DEFAULT_NO_NETWORK_TRIES) {
VERBOSE_MSG("waitForRegistered", "No signal");
break; //after a while, not network really means no network. Bailing out
}


Loading…
Cancel
Save