voronwae wrote: ↑
Tue Jun 25, 2019 5:01 am
I had the same question. Just to be clear, are you saying that there is still no sleep mode for the Pi 4?
Lack of a true sleep mode is what's prevented me from using a Pi for several applications over the last couple of years - it pretty much prevents battery-powered apps. Is there some endemic feature that would be broken by adding a true deep sleep mode, one that doesn't require shutdown or halt? Is the Pi just always going to be that way?
Many thanks. I appreciate how much work you guys must have put into this whole endeavor.
For battery powered applications on a Pi4 it is possible to 'halt' to go into the very low power state. To wake up pull global_en e.g. a HAT with an RTC or some other event. To make things even better use buildroot (*) or similar to make the kernel boot as fast as possible and avoid running any background services.
This approach is considerably simpler than suspend to RAM or paging everything to SD so I think it's a reasonably approach so long as the wake up frequency isn't too high.
(*) Buildroot recipes are pretty similar to Pi3 so these should appear soon although not directly supported by Raspberry Pi.
Thanks for your reply.
The lack of a true sleep mode makes it fairly impossible to run a script that wakes up, does something, and goes back to sleep, say, every few minutes. That's a very common application, and rebooting on wake-up is basically the same as having a separate process running on another processor power the Pi on every few minutes. If you have a separate processor powering on the Pi every few minutes, you might as well skip the Pi...
A few years ago I chose the Edison over the Pi for this reason, despite the fact that the Pi was cheaper, better supported and had a much better version of Linux. The one huge advantage that the Edison had over the Pi was that the Edison could wake up and do something and the Pi couldn't. That meant that the Edison could run for a week on a small lithium battery, whereas the Pi needed something more like a large gel cell. And that meant that the Edison was portable, whereas the Pi was not.
Unfortunately, Intel's CEO stepped down, a new one stepped in, and the Edison was suddenly gone. The Pi 4 is small, and capable, but it still doesn't know how to go to sleep? Please forgive my ignorance, but is there a specific architectural feature that prevents all generations of Pi from having a sleep mode?
Or is the decision to leave out the RTC just a cost or real estate trade that always goes the same way with each new generation? It seems like RTCs can be extremely small, but maybe a battery or capacitor is the deciding factor.