Last active
May 28, 2019 17:21
-
-
Save tmcolby/6d374907decec2ef07b1453fa74718d9 to your computer and use it in GitHub Desktop.
helpful udev rules for usb-serial adapters on the raspberry pi
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
# predictable enumeration based on physical port the usb serial adapter is plugged into | |
# Hardware : BCM2835 raspberry pi 3b | |
# Revision : a02082 | |
# view looking at the ports of the pi | |
# usbSerial0 usbSerial1 | |
# usbSerial2 usbSerial3 | |
KERNELS=="1-1.2", SUBSYSTEMS=="usb", SUBSYSTEM=="tty", ATTRS{devpath}=="1.2", SYMLINK+="usbSerial0", GROUP="dialout", MODE="0666" | |
KERNELS=="1-1.3", SUBSYSTEMS=="usb", SUBSYSTEM=="tty", ATTRS{devpath}=="1.3", SYMLINK+="usbSerial2", GROUP="dialout", MODE="0666" | |
KERNELS=="1-1.4", SUBSYSTEMS=="usb", SUBSYSTEM=="tty", ATTRS{devpath}=="1.4", SYMLINK+="usbSerial1", GROUP="dialout", MODE="0666" | |
KERNELS=="1-1.5", SUBSYSTEMS=="usb", SUBSYSTEM=="tty", ATTRS{devpath}=="1.5", SYMLINK+="usbSerial3", GROUP="dialout", MODE="0666" |
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
# predictable enumeration based on physical port the usb serial adapter is plugged into | |
# Hardware : BCM2835 raspberry pi 3b+ | |
# Revision : a020d3 | |
# view looking at the ports of the pi | |
# usbSerial0 usbSerial1 | |
# usbSerial2 usbSerial3 | |
KERNELS=="1-1.1.2", SUBSYSTEMS=="usb", SUBSYSTEM=="tty", ATTRS{devpath}=="1.1.2", SYMLINK+="usbSerial0", GROUP="dialout", MODE="0666" | |
KERNELS=="1-1.3", SUBSYSTEMS=="usb", SUBSYSTEM=="tty", ATTRS{devpath}=="1.3", SYMLINK+="usbSerial1", GROUP="dialout", MODE="0666" | |
KERNELS=="1-1.1.3", SUBSYSTEMS=="usb", SUBSYSTEM=="tty", ATTRS{devpath}=="1.1.3", SYMLINK+="usbSerial2", GROUP="dialout", MODE="0666" | |
KERNELS=="1-1.2", SUBSYSTEMS=="usb", SUBSYSTEM=="tty", ATTRS{devpath}=="1.2", SYMLINK+="usbSerial4", GROUP="dialout", MODE="0666" |
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
# predictable enumeration based on vendor: FTDI FT232 USB-Serial UART (when plugged into any port) | |
SUBSYSTEM=="tty", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", SYMLINK+="usbSerial0", GROUP="dialout", MODE="0666" |
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
https://elinux.org/RPi_HardwareHistory | |
http://reactivated.net/writing_udev_rules.html | |
http://www.linux-usb.org/FAQ.html#i6 | |
https://askubuntu.com/questions/49910/how-to-distinguish-between-identical-usb-to-serial-adapters | |
https://unix.stackexchange.com/questions/81754/how-to-match-a-ttyusbx-device-to-a-usb-serial-device?noredirect=1&lq=1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment