mirror of
https://github.com/meshcore-dev/MeshCore.git
synced 2026-04-20 22:13:47 +00:00
changed ms to sec
This commit is contained in:
parent
39503ad0b4
commit
62e180dc0f
2 changed files with 4 additions and 4 deletions
|
|
@ -524,9 +524,9 @@ bool EnvironmentSensorManager::setSettingValue(const char* name, const char* val
|
||||||
if (strcmp(name, "gps_interval") == 0) {
|
if (strcmp(name, "gps_interval") == 0) {
|
||||||
uint32_t interval_seconds = atoi(value);
|
uint32_t interval_seconds = atoi(value);
|
||||||
if (interval_seconds > 0) {
|
if (interval_seconds > 0) {
|
||||||
gps_update_interval_ms = interval_seconds * 1000;
|
gps_update_interval_sec = interval_seconds;
|
||||||
} else {
|
} else {
|
||||||
gps_update_interval_ms = 1000; // Default to 1 second if 0
|
gps_update_interval_sec = 1; // Default to 1 second if 0
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
@ -717,7 +717,7 @@ void EnvironmentSensorManager::loop() {
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
next_gps_update = millis() + gps_update_interval_ms;
|
next_gps_update = millis() + gps_update_interval_sec;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ protected:
|
||||||
|
|
||||||
bool gps_detected = false;
|
bool gps_detected = false;
|
||||||
bool gps_active = false;
|
bool gps_active = false;
|
||||||
uint32_t gps_update_interval_ms = 1000; // Default 1 second
|
uint32_t gps_update_interval_sec = 1; // Default 1 second
|
||||||
|
|
||||||
#if ENV_INCLUDE_GPS
|
#if ENV_INCLUDE_GPS
|
||||||
LocationProvider* _location;
|
LocationProvider* _location;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue