This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <WiFi.h> | |
#include <NTPClient.h> | |
#include <WiFiUdp.h> | |
#define NTP_OFFSET -3 * 60 * 60 // In seconds | |
#define NTP_INTERVAL 60 * 1000 // In miliseconds | |
#define NTP_ADDRESS "0.pool.ntp.org" | |
WiFiUDP ntpUDP; | |
NTPClient timeClient(ntpUDP, NTP_ADDRESS, NTP_OFFSET, NTP_INTERVAL); |