Power off an USB device in software on Windows Power off an USB device in software on Windows windows windows

Power off an USB device in software on Windows


Some USB hubs have the ability to turn power off to its downstream devices.

"Is it possible to power up ports on a USB hub from Ubuntu?"https://askubuntu.com/questions/149242/is-it-possible-to-power-up-ports-on-a-usb-hub-from-ubuntuWhich points to some c source for hub-ctrl.c

See: http://www.gniibe.org/development/ac-power-control-by-USB-hub/index

I tested this on Ubuntu with a Dream-Cheeky USB LED unit, and it did seem to turn the power off - although when turned on again, the device had remembered (!) its LED on/off state ??? - This did not happen when I unplugged and repluged the USB lead to the LED...

It looks like someone has looked at compiling this for Windows, but I could not find the result, sorry.


You could do with a hardware relay and controlling it via software: http://pintant.cat/2012/05/12/power-off-usb-device/ (of course, will use 2 USB ports :-) one for the device, one for the relay).


Since it's for development/test instead of production, I'd recommend having a solid-state_relay as part of a second device and using that to cycle the power on the USB connection.