Учитываем часовой пояс при сохранении системного времени во внешнюю RTC

This commit is contained in:
2023-06-29 19:18:08 +03:00
parent b09fea39e7
commit 68585ad4b6

View File

@@ -50,7 +50,7 @@ class RTC : public IoTItem {
_watch->settimeUnix(ut);
SerialPrint("i", F("RTC"), "Устанавливаем время: " + value);
} else if (key == "setSysTime") {
_watch->settimeUnix(unixTime);
_watch->settimeUnix(unixTime + jsonReadInt(settingsFlashJson, F("timezone")) * 60 * 60);
SerialPrint("i", F("RTC"), F("Запоминаем системное время"));
}
}