From bbc9246ec4a6df0f5816d85c3bc102f0d979a3ec Mon Sep 17 00:00:00 2001 From: Tony Baltovski Date: Wed, 7 Jun 2023 08:20:25 -0400 Subject: [PATCH] [clearpath_platform] Added J100 MCU, FTDI and Logitech joy udev rules. --- .gitignore | 1 - clearpath_robot/debian/udev | 16 ++++++++++++++++ 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 clearpath_robot/debian/udev diff --git a/.gitignore b/.gitignore index e9a232d..a0293e0 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,3 @@ __pycache__/ *.py[cod] .obj-x86_64-linux-gnu/ -debian/ diff --git a/clearpath_robot/debian/udev b/clearpath_robot/debian/udev new file mode 100644 index 0000000..66184ce --- /dev/null +++ b/clearpath_robot/debian/udev @@ -0,0 +1,16 @@ +# Udev rule for the Prolific Serial-to-USB adapter shipped standard with Clearpath Husky A200 +SUBSYSTEMS=="usb", ATTRS{manufacturer}=="Prolific*", SYMLINK+="clearpath/prolific clearpath/prolific_$attr{devpath}", MODE="0666" + +# World-writeable permissions and a symlink for the Jackal J100 MCU. +SUBSYSTEM=="tty", ATTRS{idProduct}=="5740", ATTRS{idVendor}=="0483", MODE="0666", SYMLINK="clearpath/j100" + +# Recognize Clearpath flavoured FTDI cables. +SUBSYSTEM=="tty", ATTRS{idProduct}=="6001", ATTRS{idVendor}=="0403", ATTRS{product}=="Clearpath Robotics /*", MODE="0666", PROGRAM="/bin/echo '%s{product}'", SYMLINK+="clearpath%c{3}" + +# Rule to enable low latency mode for FTDI adaptors, regardless if flavoured or not. +SUBSYSTEM=="tty", KERNEL=="ttyUSB[0-9]*", ATTRS{idProduct}=="6001", ATTRS{idVendor}=="0403", MODE="0666", RUN+="/bin/bash -c 'echo 1 > /sys$devpath/device/latency_timer'", SYMLINK+="ftdi_%s{serial}" + +# Udev rule for the Logitech controllers +KERNEL=="js*", ATTRS{idVendor}=="046d", ATTRS{idProduct}=="c21f", SYMLINK+="input/f710" +KERNEL=="js*", ATTRS{idVendor}=="046d", ATTRS{idProduct}=="c219", SYMLINK+="input/f710" +KERNEL=="js*", ATTRS{idVendor}=="046d", ATTRS{idProduct}=="c21d", SYMLINK+="input/f310" \ No newline at end of file