← index #5778Issue #12579
Related · high · value 3.141
QUERY · ISSUE

lightsleep results in machine reset on ESP32

openby jdstroyopened 2020-03-20updated 2020-03-23
port-esp32

Hello,

I'm running this version of MicroPython on ESP32:

MicroPython v1.12-262-g19ea30bdd on 2020-03-20; ESP32 module with ESP32

And I'm observing unexpected behavior with machine.lightsleep().

I would expect the following program code:

import machine
import time
while True:
    machine.lightsleep(10)

to behave in the same way as:

import machine
import time
while True:
    time.sleep_ms(10)

However, the prior always results in a WDT reset on my platform:

>>> import machine;
>>> while True:
...     machine.lightsleep(10);
...
...
...
ets Jun  8 2016 00:22:57

rst:0x10 (RTCWDT_RTC_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00

This seems like a bug in machine.lightsleep(), as I can reproduce this with any value given to lightsleep, and even performing consecutive machine.lightsleep(100); calls directly without a loop.

CANDIDATE · ISSUE

ESP32 timer wake up repeating

openby AndreoBotelhoopened 2023-10-03updated 2023-10-24
bugport-esp32

I'm using timer wakeup from light sleep with:

machine.lightsleep(30000) #sleep 30s

after 30 the esp32 wakes, disable peripherals and sleep indefinitely with:

machine.lightsleep()

but the 30s wake timer keeps repeating and didn't find any way to disable wake source

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