MCPcopy Create free account
hub / github.com/TactilityProject/Tactility / storeTimeInNvs

Function storeTimeInNvs

Tactility/Source/network/Ntp.cpp:22–29  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20#ifdef ESP_PLATFORM
21
22void storeTimeInNvs() {
23 time_t now;
24 time(&now);
25
26 auto preferences = std::make_unique<Preferences>("time");
27 preferences->putInt64("syncTime", now);
28 LOGGER.info("Stored time {}", now);
29}
30
31void setTimeFromNvs() {
32 auto preferences = std::make_unique<Preferences>("time");

Callers 1

onTimeSyncedFunction · 0.85

Calls 2

infoMethod · 0.80
putInt64Method · 0.45

Tested by

no test coverage detected