Created
June 19, 2022 13:50
-
-
Save zieru/eec780b36dd056c15e892fbc36a8c06d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| FILES=/dev/hidraw* | |
| for f in $FILES | |
| do | |
| FILE=${f##*/} | |
| DEVICE="$(cat /sys/class/hidraw/${FILE}/device/uevent | grep HID_NAME | cut -d '=' -f2)" | |
| printf "%s \t %s\n" $FILE "$DEVICE" | |
| done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment