How to access compilation time inside ESP-IDF application code?

Garnagar
Posts: 1
Joined: Fri May 29, 2020 3:42 pm

How to access compilation time inside ESP-IDF application code?

Postby Garnagar » Fri May 29, 2020 3:47 pm

Is there a way to access compilation time from inside the ESP-IDF application code? Similarly to how you can access IDF version with IDF_VER?

markkuk
Posts: 37
Joined: Wed Mar 27, 2019 11:50 am

Re: How to access compilation time inside ESP-IDF application code?

Postby markkuk » Sat May 30, 2020 8:32 am

Use the __TIME__ and __DATE__ macros: https://gcc.gnu.org/onlinedocs/cpp/Stan ... acros.html

boarchuz
Posts: 566
Joined: Tue Aug 21, 2018 5:28 am

Re: How to access compilation time inside ESP-IDF application code?

Postby boarchuz » Sat May 30, 2020 8:58 am

Also there's some metadata embedded in the binary that includes these:

https://docs.espressif.com/projects/esp ... escription

https://docs.espressif.com/projects/esp ... sc_t4timeE

Who is online

Users browsing this forum: Bing [Bot], Google [Bot], llzzdd and 129 guests