I recently discovered that most USB hub chips support switching off power to a particular port. However there are only rare examples of active/powered hubs that have those switches populated on the circuit boards.
There is program called hub-ctrl that can tell the hub to switch power.
http://www.joeldare.com/wiki/usb_powere ... mas_lights
I compiled this program od raspi and this is the output
I know that Raspi does not have any switches to turn off power to usb but AFAIK the chip 9512 supports it.
Code: Select all
$ sudo ./hub-ctrl -v Hub #0 at 001:002 INFO: individual power switching. WARN: Port indicators are NOT supported. Hub Port Status: Port 1: 0000.0503 highspeed power enable connect Port 2: 0000.0103 power enable connect Port 3: 0000.0100 power Hub #1 at 001:001 INFO: ganged switching. WARN: Port indicators are NOT supported. Hub Port Status: Port 1: 0000.0503 highspeed power enable connect
http://ww1.microchip.com/downloads/en/D ... c/9512.pdf
It seems that PRTCTL3 and 2 are the pins could switch ports on/off.
I wonder if it feasible to solder leads to those pins and connect to a MOSFET and turn off a USB device. In Version A of the board is should be easier because you just have to replace 2 polyfuses that protect USB.
The main reason why I need to turn of an usb device is that my 3g modem sometimes hangs up. It says it's connected to the network but I can't get a connection. If I cycle the power it connects to the network.