changed ms to sec

此提交包含在:
csrutil
2025-11-29 19:02:00 +08:00
父節點 39503ad0b4
當前提交 62e180dc0f
共有 2 個檔案被更改,包括 4 行新增4 行删除
+3 -3
查看文件
@@ -524,9 +524,9 @@ bool EnvironmentSensorManager::setSettingValue(const char* name, const char* val
if (strcmp(name, "gps_interval") == 0) {
uint32_t interval_seconds = atoi(value);
if (interval_seconds > 0) {
gps_update_interval_ms = interval_seconds * 1000;
gps_update_interval_sec = interval_seconds;
} 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;
}
@@ -717,7 +717,7 @@ void EnvironmentSensorManager::loop() {
}
#endif
}
next_gps_update = millis() + gps_update_interval_ms;
next_gps_update = millis() + gps_update_interval_sec;
}
#endif
}
+1 -1
查看文件
@@ -25,7 +25,7 @@ protected:
bool gps_detected = 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
LocationProvider* _location;