From c23da0257369a379d62634301ddd536120481747 Mon Sep 17 00:00:00 2001 From: Alastair Date: Mon, 1 Jan 2024 19:38:03 +1000 Subject: [PATCH] Fix USB register on boot --- docker/docker-compose.yml | 2 +- src/hardware/sensors/config/ellipse_D.yaml | 9 ++++++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/docker/docker-compose.yml b/docker/docker-compose.yml index fc3eeb606..74f573043 100644 --- a/docker/docker-compose.yml +++ b/docker/docker-compose.yml @@ -15,7 +15,7 @@ x-volumes-roscube: &volumes-roscube - ../../datasets:/home/${USERNAME}/driverless_ws/datasets # /dev/shm is mounted in so that two foxy containers can talk to each other when using net=host, see: https://answers.ros.org/question/370595/ros2-foxy-nodes-cant-communicate-through-docker-container-border/ - /dev/shm:/dev/shm - - /dev/ttyUSB-sbg:/dev/ttyUSB-sbg + - /dev/sbg:/dev/sbg x-volumes-jetson: &volumes-jetson volumes: diff --git a/src/hardware/sensors/config/ellipse_D.yaml b/src/hardware/sensors/config/ellipse_D.yaml index c865e1bba..6cfe3237e 100644 --- a/src/hardware/sensors/config/ellipse_D.yaml +++ b/src/hardware/sensors/config/ellipse_D.yaml @@ -32,7 +32,14 @@ # Uart configuration uartConf: # Port Name - portName: "/dev/ttyUSB-sbg" + ### IMPORTANT REQUIRES UDEV RULE TO BE CREATED + # sudo touch /etc/udev/rules.d/99-sbg_example.rules + # sudo nano /etc/udev/rules.d/99-sbg_example.rules + # SUBSYSTEMS=="usb", ATTRS{product}=="USB-RS232 Cable", ATTRS{serial}=="SERIAL_HERE", SYMLINK+="sbg" + ### Find serial by walking through ttyUSBs + # udevadm info --name=/dev/ttyUSB0 --attribute-walk # replace with ttyUSB1... etc until you find the RS232 + + portName: "/dev/sbg" # Baude rate (4800 ,9600 ,19200 ,38400 ,115200 [default],230400 ,460800 ,921600) baudRate: 115200