[nRF52] sleep time passing too quickly

Discussion and questions about boards that can run MicroPython but don't have a dedicated forum.
Target audience: Everyone interested in running MicroPython on other hardware.
Post Reply
User avatar
WhiteHare
Posts: 129
Joined: Thu Oct 04, 2018 4:00 am

[nRF52] sleep time passing too quickly

Post by WhiteHare » Sun Oct 21, 2018 12:16 am

I'm using utime.sleep_ms(1000) to create a one second delay between packet transmissions by an nRF52840, and yet the delay seems to be lasting only about 250ms instead. Perhaps something is waking it up prematurely?

Is there a better way to create a more accurate delay?

uCTRL
Posts: 47
Joined: Fri Oct 12, 2018 11:50 pm

Re: [nRF52] sleep time passing too quickly

Post by uCTRL » Sun Oct 21, 2018 2:51 am

Is your main CPU oscillator configured correctly?
Check to see at frequency CPU is running, machine.freq().

Post Reply