Sunday, April 28, 2024
 Popular · Latest · Hot · Upcoming
5
rated 0 times [  5] [ 0]  / answers: 1 / hits: 16033  / 3 Years ago, sat, may 1, 2021, 11:53:43

I have a D-Link DUB-H7 powered USB 2.0 hub connected to my computer. Occasionally when I reboot the system, I've noticed that some of the ports on the hub get powered down: the green light next to the port is turned off, and the device attached to that port is not visible to lsusb or similar commands. Devices attached to the other ports on the hub function as normal.



I am able to restore the ports by disconnecting power to the hub temporarily (from the computer, AC adapter and any devices that might provide any power such as my phone), but this is a bit of a hassle.



It seems like something that might be related to power management, so is there some way you can tell the USB hub to power up through software?


More From » usb

 Answers
0

hub-ctrl will do what you need.



sudo apt-get install libusb-dev
cc -o hub-ctrl hub-ctrl.c -l usb
sudo ./hub-ctrl -v
sudo ./hub-ctrl -P 2 -p 1 # turn on port 2
sudo ./hub-ctrl -P 2 -p 0 # turn off port 2


Disclaimer: although I have tested it on Ubuntu 12.04 (precise), I did not write this utility. It does require a hub with built in power control, but given that your hub is powering down certain ports it is a good bet your hub has it.


[#37717] Saturday, May 1, 2021, 3 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
llianconclad

Total Points: 65
Total Questions: 109
Total Answers: 127

Location: Mali
Member since Fri, Dec 3, 2021
2 Years ago
;