Page 1 of 1

esp_timer_get_time gives wrong time after two or three hours

Posted: Fri Aug 30, 2019 6:30 am
by yuvraj.singh
I have observed the esp-idf API, esp_timer_get_time reports invalid time after a few hours. I have dumped pseudo-code below:

Code: Select all

/* Wait loop for 5ms */
unsigned long time = esp_timer_get_time() + (5 * 1000);
while(esp_timer_get_time() < time);
tick rate is 1000.

Any idea on this?