Hi,
I'm not able to understand the function of rtc.info(). When I enter this command in the REPL, I get an output which says 262147. The documentation says it gives information about the startup time and reset source.
-The lower 0xffff are the number of milliseconds the RTC took to start up.
-Bit 0x10000 is set if a power-on reset occurred.
-Bit 0x20000 is set if an external reset occurred.
I don't understand what this means. Can someone help me please?
rtc.info()
- pythoncoder
- Posts: 5956
- Joined: Fri Jul 18, 2014 8:01 am
- Location: UK
- Contact:
Re: rtc.info()
If you issue
you will see that bits 0x10000 and 0x20000 are zero. Your RTC took 3ms to start up.
If this isn't clear I suggest you look up information on binary and hexadecimal numbers. This forum is for MicroPython specific queries and it's not practicable to offer one-to-one tuition on basic programming topics.
Code: Select all
>>> hex(262147)
'0x40003'
>>>
If this isn't clear I suggest you look up information on binary and hexadecimal numbers. This forum is for MicroPython specific queries and it's not practicable to offer one-to-one tuition on basic programming topics.
Peter Hinch
Index to my micropython libraries.
Index to my micropython libraries.