Hey guys, I have finished creating a hardware power switch for the Raspberry Pi that communicates with the Pi. It has a micro-USB connector on one end that your normal power supply plugs in to and then a USB port for connecting the Pi to. It uses two leads that connect to GPIO pins and a short script runs in the background (I put it in /etc/rc.local).
When you turn off the switch, the GPIO pins pick this up and run a shutdown sequence. When the shutdown process is complete the switch cuts out power to the Pi board completely.
I've also made a version with two USB ports so your hub can draw power from it (The switch is rated to 1.8 - 2amps).
Also I've just about finished with a car supply/switch that senses when the ignition is turned off and runs the shutdown sequence and provides power until the Pi has safely run its shutdown sequence.
I've attached a video of the switch in action. If you want to buy one, I have the boards on the way and will be assembling them in this week.
$15 + shipping for the regular and dual-USB ones, the car versions will be a little bit more. The script for the Pi and instructions for setting it up (takes less than a minute via SSH) will be included with the switch. You can customize which GPIO pins you use in the script.
If you want a board just send me a message on here or email MausBerryCircuits@gmail.com
Here's the quick YouTube demo:
http://www.youtube.com/watch?v=0goSyz0_ ... e=youtu.be