Oct 142013
 

Pi Supply is an external power switch for your Raspberry Pi. I have to be scrupulously honest here and say that, when I first heard about it, I thought “well that solves a problem I haven’t got”. But in the Raspberry Pi forums, quite a lot of people complained about not having a power switch. It’s never been an issue for me. I don’t find unplugging a micro USB cable all that hard. I’ve never broken the capacitor off the Pi (although I have broken a couple of SD card slots and fried a couple of SPI ports).

But, recently, I built Jason Barnett’s MotorPiTX board, which has a similar, but different, ATX-style power switch. I found myself rather liking it.

So when Aaron Shaw, a MagPi editor and the guy behind the Pi Supply switch, sent me some review samples of his products, I was already a lot warmer to the idea than I had been in the past.

Kit Contents

Here’s what you get in the kit…

Pi Supply kit contents

The micro-usb port is pre-soldered. This is a nice touch because they’re quite fine pitch and really not that easy to solder well by hand. Aside from that you get…

  • 6 resistors
  • 2 diodes
  • an electrolytic capacitor
  • 2 transistors
  • a small red LED
  • 3 ‘tall’ buttons
  • a 2 pin header
  • an USB port
  • a teeny relay
  • a USB to micro-USB noodle cable
  • 2 female-female jumper cables
  • PCB with micro-USB

20 minute assembly

It took me about 20-30 minutes to put together. As usual, I was fussy to get everything straight and all the resistors the same way round etc. It looks better for the photos. Start with the lowest parts and build upwards. I did resistors first, then diodes, then LED, then transistors, electrolytic cap, USB port, header, buttons and then relay last.

It’s quite tightly packed, which gives you a small form factor.

What do the control buttons do?

Pi Supply Switch assembled


You’ve got three control buttons. From left to right, they are…

  1. Power OFF – hardware kill switch
  2. Soft OFF – software shutdown – requires 2 wires to pins 7 & 8 and a program to be running
  3. Power ON

Buttons 1 & 3 work independently of what’s happening on the Pi. You can use these as simple OFF and ON switches.

Button 2, the “shutdown” switch, is designed to work with 2 jumper wires (provided in the kit) connected to pins 7 and 8 on the P1 GPIO header of the Pi. Pressing this button initiates a shutown on the Pi. Depending on which script you run, you may have to hold it for a second.

Two example Python scripts to use with this can be found here.

Can I still shutdown “normally”?

Yes. If you shut down your Pi the “normal” way e.g. by typing sudo halt, or sudo shutdown -h now, after about a minute, the capacitor is discharged and the relay opens, isolating the power. You’ll hear the relay click and see the red LED on the Pi extinguish.

How Much and Where?

The Pi Supply costs £15 and you can buy one from the Pi Supply shop

Do I need one?

It’s one of those little extra items that is really nice to have, but not essential (for me at least). But we all have different uses for our Pis, and for many people, this seems to be a ‘must-have’ item.

It’s definitely a nice little board and it works well so far. I think I might envelop mine in some clear heat-shrink to protect the underside from shorting if I put it down on something conductive. You could also mount it on some sort of backing, as mount holes are provided.

  27 Responses to “Pi Supply – ATX style power switch for Raspberry Pi – Review”

  1. I was going to make one of these but do it as a GPIO daughter board (with a GPIO passthrough so you can still use the GPIO) and feed the power in through the GPIO inputs. That way you eliminate the USB cable and GPIO lead.

  2. I would use something like this, although this one seems just a touch pricey.

    I would guess that you mostly use your Pis in situations where you’re logged into them by one means or another. In a stand-alone application, however, it is useful to have a shutdown button to ensure you don’t pull the plug while it’s writing to the sd card. If it’s going to shut itself down then it might as well disconnect the power, too – otherwise you’re left wondering how long to leave it before you pull the plug out. And if you’ve got an auto off function then it makes sense to switch it on in a similar fashion. It is also consistent with how many other modern devices are operated.

  3. Do you mean a USB power pack?
    Yeah that might be a good starting point.

  4. If this came with a decent 5V 2A supply the price would be very reasonable.

  5. As an alternative for about the same cost you could use the RemotePi Board, which allows the use of an infrared remote control to switch power of the Raspberry Pi in addition to a pushbutton.

  6. How do I make the script run if I have other script running on boot? Perhaps is there a way to make it work without adding the script into my “Primary” program like your RasPiCamcorder?

    Thanks

  7. It does NOT work!
    I soldered everything following your instructions but when i press “soft OFF” button, it sends signal to GPIO 7 (forth line on the left) but never cuts off the power. If i try to press OFF button it cuts off the power correctly and ON button turns on everything.
    In my opinion there is something wrong with diode D2, it avoids to put the capacitor to ground.

    PS: what’s the reason to connect to GPIO 8 (aka UARD TXD) ?

    • I didn’t even try the ‘soft off’ for my review, so I’m not quite sure where you’re coming from with that comment.
      I believe you have to follow the instructions from Pi-Supply and have a python program running in the background for the ‘soft off’ to work.

      Your comment seems to think that this is my product. It isn’t! The above blog post is a review.

      • I had no intention to say it your product or your fault… just explaining my problem looking for a solution.

        • OK fair enough. Your wording was exactly as if you were addressing the manufacturer of the product. I just wanted to be clear that you knew it wasn’t me. :)

    • I don’t have a pi-supply myself, but I believe the pin 8 connection (you need to be careful with your terminology – pin 8 is different to GPIO 8 – see http://elinux.org/Rpi_Low-level_peripherals ) is used by the pi-supply to detect that the Pi has finished doing its “safe shutdown”, so it’s now safe to cut off the power (with no danger of causing SD card corruption).

  8. Hello, 1Aug15

    How much work would it be to add a clock to this?

    It would allow my RP2 to auto-start everyday. Run a job and shut itself down. That would be fantastic!!

    Eric.

  9. why is the power out bigger

    • a) having the power-in and power-out be different sizes, prevents you connecting the cables the wrong way round ;)
      b) at the time the PiSupply switch was designed, USB cables with a full-size on one end and a micro on the other end, were the only kinds of micro-USB cables commonly available

  10. My first test of the switch seemed to be ok for on and off but not soft stop. The red led does not illuminate. I see on the handbook chat that someone has got the schematic an parts layout from somewhere. I would like a copy of the schematic to assist diagnosis

  11. Can I also use it for Google Coral Dev Board?

Leave a Reply to Fabio Cancel reply