Page 1 of 1

ESP32 Clock Component

Posted: Wed Jan 19, 2022 9:52 pm
by mnfisher
Adding the ESP32 with NTP component introduces a lot of compilation errors. With just Initialise called...

timeinfo not found is the main issue..
../main/esp-project.c: In function 'FCD_04251_RTC_ESP32_NTP1__GetMins':
../main/esp-project.c:455:16: error: 'timeinfo' undeclared (first use in this function); did you mean 'fminf'?
return (FCR_RETVAL);
^~~~~~
fminf
../main/esp-project.c: In function 'FCD_04251_RTC_ESP32_NTP1__GetTimeString':
../main/esp-project.c:488:15: error: 'timeinfo' undeclared (first use in this function); did you mean 'fminf'?

^
fminf
../main/esp-project.c: In function 'FCD_04251_RTC_ESP32_NTP1__SetDate':
../main/esp-project.c:580:3: error: 'timeinfo' undeclared (first use in this function); did you mean 'fminf'?
Martin

Re: ESP32 Clock Component

Posted: Tue Jan 25, 2022 4:56 pm
by BenR
Hi Martin,

The example here is building correctly for me using the latest library updates.
https://www.flowcode.co.uk/wiki/index.p ... _(Storage)

Please can you give that a try. I can also look at your project if you attach it to the forums.

Re: ESP32 Clock Component

Posted: Tue Jan 25, 2022 8:20 pm
by mnfisher
Hi Ben,

This is the sample that 'fails' -
clock.fcfx
(6.73 KiB) Downloaded 130 times
- I see from another example that I need to add a timeinfo in supplementary code - which is easy enough.

The sample above opens as a 'text' listing in Edge (- so I can copy and save, but still odd and a little disconcerting?) I see this uses the supplementary code too:-)

Martin

Re: ESP32 Clock Component

Posted: Wed Jan 26, 2022 11:11 am
by BenR
Thanks Martin,

Aha maybe I've missed something. I'll get that supplementary code added into the component so it's not needed.

Re: ESP32 Clock Component

Posted: Fri Jan 28, 2022 11:41 am
by BenR
This should be all fixed for you now via the latest library updates, thanks again for letting us know.

Re: ESP32 Clock Component

Posted: Mon Apr 18, 2022 4:25 pm
by chipfryer27
Hi

Just starting to explore the ESP and so far so good. Minor issue in getting the toolchain to work but all good and flash test worked perfectly. Downloading Ben's ESP_Config_WiFi to allow me to set a specific SSID and Password worked a treat too.

Following on from that I thought it would be a good idea to try and sync the ESP RTC with a timeserver which lead me to this thread. However in the Wiki page Ben links to above, when you click on the example file it doesn't download a file, instead it opens up a page displaying code.

Regards