ElektorLabs / 180662-mini-NTP-ESP32

mini NTP server with GPS and ESP32
GNU General Public License v3.0
31 stars 10 forks source link

Firmware v1.6 is doing weird things... [Bug] #11

Open dl9sec opened 2 years ago

dl9sec commented 2 years ago

Hi,

after a long time I updated my breadboard NTP server (AZ-Delivery ESP32 NodeMCU, DS3231, Perthold ST22 GPS, I2C display) from v1.2 (around the time where I discovered the GPS week rollover problem) to v1.6. I uploaded the new data to the FS and deleted the EEPROM at the first startup. Configuration went OK so far. Then I observed the following problems:

So currently the NTP server isn't usable for me.

Someone else having these problems? Any ideas, what I am probably doing wrong?

Regards, Thorsten

dl9sec commented 2 years ago

It seems, that the time displaying problems were caused by a defect of the RTC's backup battery. Will observe the webserver problem...

dl9sec commented 2 years ago

The RTC now seems to work, but there are still weird things: Sometimes the display task seems to freeze for several minutes (display stucks, no refresh anymore). After that the time sometimes lacks for minutes until the next GPS sync...

SchneHa commented 1 year ago

I can confirm that FW1.6 is buggy. I have a device built from WEMOS Lolin32 with OLED, OpenSmart GPS module and DS3231 RTC. FW 1.4 is working fine but if I flash FW1.6 my device freezes after a few minutes and has to restart again. Something must be wrong in 1.6

SchneHa commented 1 year ago

My issue is now solved, see https://github.com/ElektorLabs/180662-mini-NTP-ESP32/issues/13

lab-mathias-claussen commented 1 year ago

Seems the Framework for the ESP32 got updated and results in some strange "functions". We try to figure out what we need to patch to make it work with the latest library revisions

SchneHa commented 1 year ago

On my MacBook Pro time is set totally wrong if I use NTP Server. Date now is 1.12.2022 but date is set to 13.8.2037!!! Even time is wrong (13 instead of 20). Time in display is correct.

Edit: I think that the solution is that line 190 (ntp_req.txTm_s = htonl(ntp_req.txTm_s);) of ntp_server.cpp has to be uncommented.

PikuZheng commented 4 weeks ago

same issue, wrong date calc with latest code image