testing machine deepsleep

  • import machine
    import pycom
    import os
    import time
    while i==True:
        print('normal mode 5sec')
        i = False
    print('deepsleep mode 5sec')
    print('deepsleep done')

    I'm trying to run this code. But the last print never appear.
    I'm running the latest fw.


  • @serafimsaudade That would be the expected result, as when the board wakes up after deep sleep, it acts as a reset and it restarts from the top of boot.py + main.py. During deep sleep RAM etc. are not powered, so the board can't just resume execution at the next instruction.

Log in to reply

Pycom on Twitter

Looks like your connection to Pycom Forum was lost, please wait while we try to reconnect.