Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rp2040: rtc deep sleep #3405

Draft
wants to merge 2 commits into
base: dev
Choose a base branch
from
Draft

rp2040: rtc deep sleep #3405

wants to merge 2 commits into from

Conversation

ysoldak
Copy link
Contributor

@ysoldak ysoldak commented Jan 21, 2023

Builds on top of #3403 (hence includes a commit from there)

This PR implements deep sleep (not dormant state!) on RP2040.
Example added that shows how to use the feature with some power consumption stats for Nano RP2040 Connect board.

Example output

1970-01-01T00:00:05Z Base power, 5 sec, 0.11W
1970-01-01T00:00:10Z High power, 5 sec, 0.13W
1970-01-01T00:00:15Z  Low power, 5 sec, 0.03W
1970-01-01T00:00:15Z Base power, 5 sec, 0.11W
1970-01-01T00:00:20Z High power, 5 sec, 0.13W
1970-01-01T00:00:25Z  Low power, 5 sec, 0.03W
1970-01-01T00:00:25Z Base power, 5 sec, 0.11W
1970-01-01T00:00:30Z High power, 5 sec, 0.13W
1970-01-01T00:00:35Z  Low power, 5 sec, 0.03W

Observe how internal time (accessed by time.Now()) stops while system is in deep sleep.

Draft, because I still observe Serial console problems after wake up.
The application does work, judging by on-board led going on and off and measured power consumption, but output in Serial stops. No disconnects though, just nothing prints.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant