diff --git a/doc/local_ros_installation.md b/doc/local_ros_installation.md index 5d601d64de1080e4faaf4ff2e40da23295e1231d..f880ba3445318d5f32fa5f159c1886912d0abcf5 100644 --- a/doc/local_ros_installation.md +++ b/doc/local_ros_installation.md @@ -324,4 +324,33 @@ In the docker run wexec roslaunch lrs_launch djisimtst.launch simulator:=false ns:=/dji0 ``` -## Flying with Gamepad \ No newline at end of file +## Flying with Gamepad + +For this case it is more convenient to runt the roscore on the local machine. + +On the local machine run the joy ros node: + +Set the variable: +```bash +echo $JOY_EXTRA0 +usb-Logitech_Wireless_Gamepad_F710_2CAE9E79-joystick +``` + +To get the id for the Gamepad do: +```bash +tompe@philo:~$ ls /dev/input/by-id/ +usb-046d_C922_Pro_Stream_Webcam_B16031EF-event-if00 +usb-CNFEH73M102010001C32_Integrated_Webcam_HD-event-if00 +usb-ELAN_Touchscreen-event-if00 +usb-HP_HP_USB_1000dpi_Laser_Mouse__LiteON_-event-mouse +usb-HP_HP_USB_1000dpi_Laser_Mouse__LiteON_-mouse +usb-Logitech_USB_Keyboard-event-if01 +usb-Logitech_USB_Keyboard-event-kbd +usb-Logitech_Wireless_Gamepad_F710_2CAE9E79-event-joystick +usb-Logitech_Wireless_Gamepad_F710_2CAE9E79-joystick +``` + +Start the ROS driver for a joystick: +```bash +rosrun joy joy_node _dev:=/dev/input/by-id/${JOY_EXTRA0} _deadzone:=0.05 _autorepeat_rate:=0 _coalesce_interval:=0.1 __ns:=/extra0" +``` \ No newline at end of file