From 470fe85a3e6a481d334fd9bb2b96de3ea8a2a980 Mon Sep 17 00:00:00 2001
From: Tommy Persson <tommmy.persson@liu.se>
Date: Tue, 29 Sep 2020 08:53:02 +0200
Subject: [PATCH] Work on development environment.

---
 doc/local_ros_installation.md | 31 ++++++++++++++++++++++++++++++-
 1 file changed, 30 insertions(+), 1 deletion(-)

diff --git a/doc/local_ros_installation.md b/doc/local_ros_installation.md
index 5d601d6..f880ba3 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
-- 
GitLab