Skip to content

Commit

Permalink
Correct millis() error causes by micros() overflow every about 72 min…
Browse files Browse the repository at this point in the history
…utes (#2438)
  • Loading branch information
Jeroen88 authored and me-no-dev committed Feb 14, 2019
1 parent 8ec7640 commit 71ec3c3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cores/esp32/esp32-hal-misc.c
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ unsigned long IRAM_ATTR micros()

unsigned long IRAM_ATTR millis()
{
return (unsigned long) (esp_timer_get_time() / 1000);
return (unsigned long) (esp_timer_get_time() / 1000ULL);
}

void delay(uint32_t ms)
Expand Down

0 comments on commit 71ec3c3

Please sign in to comment.