esp8266 icon indicating copy to clipboard operation
esp8266 copied to clipboard

How to read time past between bootrom executions

Open HomeACcessoryKid opened this issue 5 years ago • 0 comments

Fun Repo ;-) I am coding a boot loader that will detect bad code or power cycles. If detected, it will start an OTA program that will try to download less buggy code. All in the esp-open-rtos eco-system. (ref).
Based on your experiments I wonder if you have an idea how to get a reference for the time that passes in the sequence

  • boot loader (t=x)
  • user code
  • crash/other event
  • boot loader (t=y)
  • calc y-x

I believe the ROM does not have the system_get_time() call and I have not been able to find an alternative so far. In RTC memory I could find the WDT values, but I do not yet see how I could leverage those...

Thanks in advance for a slice of your mind, HacK

HomeACcessoryKid avatar Jan 22 '20 22:01 HomeACcessoryKid