changes
This commit is contained in:
@ -14,13 +14,11 @@ static t_configBlock *config;
|
|||||||
|
|
||||||
|
|
||||||
static uint8_t sntpBuffer[MAX_SNTP_BUF_SIZE];
|
static uint8_t sntpBuffer[MAX_SNTP_BUF_SIZE];
|
||||||
const uint64_t UNIX_NTP_EPOCH_DIFF = 2208988800;
|
static const uint64_t UNIX_NTP_EPOCH_DIFF = 2208988800;
|
||||||
extern const uint8_t SNTP_SOCK;
|
extern const uint8_t SNTP_SOCK;
|
||||||
|
static uint64_t seconds;
|
||||||
|
|
||||||
|
void networkSntpEngine(void *handle) {
|
||||||
uint64_t networkSntpQuery() {
|
|
||||||
uint64_t seconds = 0;
|
|
||||||
|
|
||||||
if (isNetworkAvailable()) {
|
if (isNetworkAvailable()) {
|
||||||
coloredMsg(LOG_BLUE, "wizsq, about to call SNTP");
|
coloredMsg(LOG_BLUE, "wizsq, about to call SNTP");
|
||||||
|
|
||||||
@ -48,10 +46,12 @@ uint64_t networkSntpQuery() {
|
|||||||
coloredMsg(LOG_BLUE, "wizsq, error when querying ntp server name");
|
coloredMsg(LOG_BLUE, "wizsq, error when querying ntp server name");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return seconds;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
uint64_t networkSntpQuery() {
|
||||||
|
networkSntpEngine(NULL);
|
||||||
|
return seconds;
|
||||||
|
}
|
||||||
|
|
||||||
extern uint8_t SINK_SOCK;
|
extern uint8_t SINK_SOCK;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user