Page 1 of 1

POSIX time functions in STUB

Posted: Sat Aug 05, 2023 6:12 pm
by aravind.h615
Hi All

[ Note: Without using SNTP server to get the current time , I can set the time and read the current time using POSIX functions in normal/non-stub mode]

Now , I am trying to read current time using POSIX functions in the Deep_sleep_wake_stubs . But , I keep getting "Guru Meditation Error: Core 0 panic'ed (Illegal instruction)...Stack dump detected" , when I call POSIX functions in stub.

I have followed the rules for custom wake stub as given in the programming guide [https://docs.espressif.com/projects/esp ... -stub.html]

Can anyone please tell me if we can call POSIx functions in stub?

Regards

Re: POSIX time functions in STUB

Posted: Tue Aug 08, 2023 1:45 pm
by ESP_igrr
Hi aravind.h615,

No, unfortunately you can't. POSIX time function depend on a large amount of code in C standard library which only gets loaded along with the application, most importantly the port layer which maps POSIX functions to hardware functions. That code simply can't fit into the RTC RAM.