This instructable is going to show you how to make it so that when you plug-in your usb cable or unplug it OR when you power-on or power-off your PC, PS3, Xbox, Wii or whatever your hard drive is plugged in will turn your hard drive on or off accordingly.
The Idea is very simple, a Relay will be used to turn on the power supply when it detects that the USB port is getting power.
-appropriate tools (soldering iron, screw drivers to open the casing etc.)
-hot glue gun (helps keep the wires in place so the solder does not break and so the relay stays in place)
-flux (helps make the connection to the USB pads easier, but not necessary)
-a relay with a 5vdc coil that can take at least 2amps on the pins at 12vdc (most normal power supplies are of 2 amps, but some are 2.5 and 4amps). There are many relays that can do the job, here are a few examples so you can find the most available one for yourself.
You only need ONE, these are all different models that can be used. Anything similar to this should do the job, the important part is the 5vdc coil and a minimum of 2amps at 12vdc as you will notice.
1-a digikey example: notice that this one can take 2 amps at 30vdc, meaning it can take more than that at 12vdc
2-this sparkfun example can take 1amp at 24vdc
3- this sparkfun one can take 5amps at 30vdc
4- finally, I used a R48-5D10-6 which was available at my local store for 2.70$ and can take 10amps at 28Vdc. This left me with plenty of headroom to work with or eventually use this in different projects and allows me to save on shipping costs as well as getting it immediately and supporting my local business.