I'm using:
Examples/ESP8266Wifi/NTPClient.ino
ESP8266/Arduino version 1.6.5-1160-gef26c5f
Arduino IDE 1.6.5
As supplied, once I update the ssid/pwd, the sample runs well. Minutes on end (many more than 5).
If I update the delay interval at the bottom of the loop() function (line 127):
delay(10000);
to
delay(1000 * 60 * 5); // wait 5 minutes
the sample fails to collect an NTP response after the first successful attempt. Line 80 catches an error, but I've not narrowed down which call is actually having issue. Originally I was seeing this problem in a much bigger sketch. There I was setting a sync interval (setSyncInterval) to 5 minutes and seeing a similar response failure. I went back to the sample to reproduce.
Anyone else seeing this? Hoping I've missed something obvious. If not, I'll continue to narrow.
Thanks,
ko