Skip to content

Update pico_sleep #79

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

Merged
merged 3 commits into from
Nov 9, 2024
Merged

Conversation

peterharperuk
Copy link
Contributor

Fixed to work for RP2040 and RP2350 using pico_aon_timer.

Fixed to work for RP2040 and RP2350 using pico_aon_timer.
@pspeybro
Copy link

Is there any chance that this update fixes the problem with locking up the pico after repeatedly calling stdio_init_all(); or stdio via USB that stops working after waking up?
See this issue for some of the attempts to find a solution: #41

@peterharperuk peterharperuk marked this pull request as ready for review November 7, 2024 19:19
@peterharperuk
Copy link
Contributor Author

I'm going to merge this...

@kilograham kilograham merged commit 1bf6ec2 into raspberrypi:master Nov 9, 2024
@Lecostarius
Copy link

Many thanks for looking into this!!
Can anyone confirm that the code is working for the Pico 2 (RP2350)? For me, the examples in pico_playground work nicely for the RP2040 (Pico), but not for the Pico 2 - it does not wake up. I can see however that the current consumption on the Pico 2 drops a lot when put to sleep, so the problem appears to be in the wake up part.

@peterharperuk
Copy link
Contributor Author

They worked for me! I pushed an update to pico_playground - can you check you have this change?

commit 3b2267d539738a36c054b93fad0715c3b2ee456f
Merge: 9930bb0 54e7410
Author: Peter Harper 77111776+peterharperuk@users.noreply.github.com
Date: Mon Nov 11 10:29:12 2024 +0000

Merge pull request #48 from peterharperuk/sleep_rp2350

Update pico_sleep examples

@Lecostarius
Copy link

OK, just saw your reply a moment ago. I will check it out and let you know. Thanks for the answer!

@Lecostarius
Copy link

Lecostarius commented Nov 22, 2024

I think I have used the latest update, but still no luck with pico2. I succeeded with switching it off completely using powman and it wakes up again, which is also solving my problem.
I should note that I was using the Arduino IDE for that which most likely is not a good idea.

@peterharperuk
Copy link
Contributor Author

peterharperuk commented Nov 22, 2024

@Lecostarius There are a few sleep examples, sleep and dormant, are none of them waking up? They should wake up when an interrupt goes off - it's odd that this wouldn't happen. Usually they don't go to sleep.

@Lecostarius
Copy link

They work on Pico. On Pico2, no wakeup. I could get the powman based example in pico-examples to work on the Pico2 though - shutdown and wakeup both work.

Probably the problem sits in front of the computer... if I find the time I will write an update here, but for now, I will go with the powman based shutdown.

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.

5 participants