← index #5651Issue #4390
Off-topic · high · value 0.096
QUERY · ISSUE

ESP32: deep sleep seems to cut clock to ULP processor

openby flo-rianopened 2020-02-16updated 2025-09-23
port-esp32

It seems like going to deep sleep stops the ULP processor. I uploaded a counter code to the ULP and it counts nicely as long as main CPUs running. When going to deep sleep counting stops but the counter value remains so the ULP was not reset or memory erased. After coming back from deep sleep counting works again.

As a side note: I would like to suggest to also add the ULP as a wakeup source in the esp32 package (in addition to the EXT, timer and touch options).

CANDIDATE · ISSUE

NodeMCU v1.0 stuck at deep sleep rtc wakeup

closedby misan128opened 2019-01-01updated 2019-06-24

Following the docs i tried the deep sleep example

import machine

# configure RTC.ALARM0 to be able to wake the device
rtc = machine.RTC()
rtc.irq(trigger=rtc.ALARM0, wake=machine.DEEPSLEEP)

# check if the device woke from a deep sleep
if machine.reset_cause() == machine.DEEPSLEEP_RESET:
    print('woke from a deep sleep')

# set RTC.ALARM0 to fire after 10 seconds (waking the device)
rtc.alarm(rtc.ALARM0, 10000)

# put the device to sleep
machine.deepsleep()

but when it wakes up it gets stuck in booting and doesn't let me erase the flash memmory or anything cause everytime i reset the device it keeps "waking up" from deep sleep and it enters to it once again.

I have tried the esptool.py to erase memory but it doesn't find the device with the usbserial converter nor usb.

Keyboard

j / / n
next pair
k / / p
previous pair
1 / / h
show query pane
2 / / l
show candidate pane
c
copy suggested comment
r
toggle reasoning
g i
go to index
?
show this help
esc
close overlays

press ? or esc to close

copied