NIIBE Yutaka's glog
   


About
NIIBE Yutaka's glog, Eight disks, three pegs, and just a little hack.

Subscribe
Subscribe to a syndicated feed of this log.

Links


       
2006-01-14 (Sat)

Enhancement of code of USB HUB (3)
Gniibe implemented user space approach of usb power control (in the bullet train).

Here it is: hub-ctrl-2.c.

 HUB-CTRL  -  program to control port power/led of USB hub

  $ gcc -o hub-ctrl hub-ctrl.c -lusb

  # hub-ctrl -b 1 -d 2 -P 1 -p            // Power off at port 1
  # hub-ctrl -b 1 -d 2 -P 1 -p 1          // Power on at port 1
  # hub-ctrl -b 1 -d 2 -P 2 -l            // LED on at port 1
It found that there has been Python implementation by Vlado Handziski, and this is the discussion. Gniibe considered this tool should be in usbutils.

[/linux] permanent link