mirror of
https://github.com/lumapu/ahoy.git
synced 2025-05-10 23:46:37 +02:00
implemented #336 set time manually or resync NTP
This commit is contained in:
parent
f53933b473
commit
e3532f4464
7 changed files with 71 additions and 13 deletions
|
@ -112,6 +112,14 @@ class app {
|
|||
return mTimestamp;
|
||||
}
|
||||
|
||||
inline void setTimestamp(uint32_t newTime) {
|
||||
DPRINTLN(DBG_DEBUG, F("setTimestamp: ") + String(newTime));
|
||||
if(0 == newTime)
|
||||
mUpdateNtp = true;
|
||||
else
|
||||
mTimestamp = newTime;
|
||||
}
|
||||
|
||||
void eraseSettings(bool all = false) {
|
||||
//DPRINTLN(DBG_VERBOSE, F("main.h:eraseSettings"));
|
||||
uint8_t buf[64];
|
||||
|
@ -239,6 +247,7 @@ class app {
|
|||
|
||||
eep *mEep;
|
||||
uint32_t mTimestamp;
|
||||
bool mUpdateNtp;
|
||||
|
||||
bool mShowRebootRequest;
|
||||
|
||||
|
@ -257,7 +266,6 @@ class app {
|
|||
|
||||
// timer
|
||||
uint32_t mTicker;
|
||||
|
||||
uint32_t mRxTicker;
|
||||
|
||||
// mqtt
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue