7

This question already has an answer here:

  1. Would like to enquire if anyone could list any/or all possible ways to achieve low power consumption on the raspberry pi.

  2. I have found that one could disable the USB ports of the raspberry pi . however i would require one of the usb port for my wifi usb dongle. Would it be possible to disable the remaining 3 usb ports only?

  3. What is the correct command to put the raspberry pi to sleep? and wake it up? ( I assume putting it to sleep has the same meaning/context as how one would put like a Macbook pro laptop to sleep and when the lid is flip upon its wakes up and awaits for user input)

  4. Any hardware hacks that allows to control the raspberry pi power management? (I have found SleepyPI to be expensive and was wondering if there a DIY solution or so?)

Any other suggestion for software and hardware power management control to achieve low power consumption of the raspberry pi?

Thank you for your help in advance

marked as duplicate by goldilocks Jul 23 '15 at 14:23

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • It may be useful to know what sort of savings you hope for. If you measure the wattage you might find it could use as litlle as 1.5 watts even with a wifi dongle (Pis with the 40 pin expansion header) when it is running. How much does your Macbook use when asleep? You will not achieve Arduino levels of power consumption. – joan Jul 23 '15 at 7:44
  • @joan would just like to know all possible means of power saving feature available. (as for the macbook I'm just giving an example on what i mean by it going to sleep) – peekaboo Jul 23 '15 at 12:37
  • Do you need ethernet? If not, you could consider the Raspberry Pi A+, with one USB port and lower power consumption. Disabling USB ports on the B model was done by powering down the network-and-USB chip, if I remember right, so then you cannot disable only some ports. I don't think the Pi has a sleep mode. – Frepa Jul 23 '15 at 14:22
4

There are two primary things you can do to reduce power consumption:

  1. Minimize the amount of power consuming peripherals attached and running.

  2. Minimize the workload. A major consumer of power is the CPU. When it is idle, it consumes less power.

That's it. The pi is a low power device compared to regular computers, but not so low power compared to many mobile devices such as smart phones. Unfortunately, there is not really much that can be done about that without adding more hardware.

What is the correct command to put the raspberry pi to sleep?

There isn't one because the hardware does not have ACPI or any other kind of power management. It is either plugged in, in which case it is on, or not.

There are commands you can issue that would work if the device did have ACPI, but it doesn't, so they won't.

Any hardware hacks that allows to control the raspberry pi power management?

No, since again, it does not have any power management.

Would it be possible to disable the remaining 3 usb ports only?

I'm not sure that doing this in the first place would really make any difference. It is like saying you would like to disconnect some empty plugs in your house to save power. If there is nothing plugged into them, they weren't using any in the first place.

Technically that's not quite true -- the USB bus itself is a microcontroller and so uses power (probably a minuscule amount when idle). However, I'm not sure that the normal recommended method for disabling USB power:

echo 0 > /sys/devices/platform/bcm2708_usb/buspower

Actually turns off the bus completely; more likely it just prevents USB devices from drawing power from the bus. Put another way, I've seen various people claiming they do this to save power, but the only evidence I've seen involves a LAN connection (the ethernet jack is on the same bus) and does not say how much simply unplugging the ethernet cable would have saved.

In any case, all the ports are on one bus, so if you disable that, you disable them all.

  • would just like to clarify would sleep and suspend mode mean the same thing? – peekaboo Jul 24 '15 at 6:34
  • They could, in which case it probably refers to "suspend to RAM", which is where the memory remains powered and everything else shuts down, making the system easy to restore when it starts up again. But there's also "suspend to disk", which on linux is done completely with software and thus in theory could be done on the pi although I've never tried (if you want, I could write up a Q&A on this). This would mean writing the memory state to a swap partition on the SD card or other storage, then shutting the system down completely (as in, no power).. – goldilocks Jul 24 '15 at 14:29
  • ..When you restart, the state can be retrieved from that partition. On normal PC's and laptops this is usually called "hibernation". I don't really consider it a form of power management because it isn't. Hardware wise, you are just turning the system on and off. It's not really "power saving", it's time saving if you want to bring your desktop up as is next time. – goldilocks Jul 24 '15 at 14:29
  • If it doesn't trouble you too much yes than a Qand A on this will be helpful. Do you know the commands for it to suspend to disk and to ram or website that has it? Would like to experiment and see if suspending to either disk or ram will work. – peekaboo Jul 25 '15 at 4:25
  • 1
    Sorry I took a little longer than I said to get around to this -- but no dice anyway. I compiled hibernation support into the kernel, and it creates a hibernation image to save to swap, but then seems to choke on being unable to freeze the USB bus (?)... So perhaps there is some hardware support required for that after all; those bits involve their own microcontrollers whose state can't be saved, I guess, meaning restarting them might leave things out of sync. – goldilocks Aug 2 '15 at 19:40

Not the answer you're looking for? Browse other questions tagged or ask your own question.