Fix ESP32 light sleep: prefer ext1 wakeup, remove RTC clock switching#7
Open
weebl2000 wants to merge 10 commits intoIoTThinks:MCdev-PowerSaving-for-all-esp32-repeaters-202602from
Conversation
- Use esp_sleep_enable_ext1_wakeup() on ESP32/S2/S3 instead of
gpio_wakeup_enable() which overwrites RadioLib's POSEDGE ISR on DIO1,
causing missed packets after wake ("deaf" device)
- Fall back to gpio_wakeup_enable() on C3/C6 (no ext1), with
hasPendingRadioIRQ() flag so RadioLib still reads buffered packets
- Remove rtc_clk_slow_src_set() that desynced FreeRTOS tick counting
- Add IRQ pin validation before configuring wake sources
2b663e4 to
ef6422b
Compare
002878e to
b45d567
Compare
30e37c5 to
c88813a
Compare
Owner
|
RTC wakeup does not work for all esp32 boards as not all boards use RTC-supported DIO1. Thanks for your effort. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I hope this fixes the reset issues.