summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xusb-devices7
1 files changed, 7 insertions, 0 deletions
diff --git a/usb-devices b/usb-devices
index 7daa139..296d432 100755
--- a/usb-devices
+++ b/usb-devices
@@ -49,6 +49,13 @@ print_endpoint() {
addr=`cat $eppath/bEndpointAddress`
attr=`cat $eppath/bmAttributes`
dir=`cat $eppath/direction`
+ if [ "$dir" = in ]; then
+ dir=I
+ elif [ "$dir" = out ]; then
+ dir=O
+ elif [ "$dir" = both ]; then
+ dir=B
+ fi
eptype=`cat $eppath/type`
maxps_hex="0x`cat $eppath/wMaxPacketSize`"
# Extract MaxPS size (bits 0-10) and multiplicity values (bits 11-12)