Gamepad#
Your robot might come with a wireless gamepad. It allows you to perform simple teleoperation such as moving the mobile base, moving the head and the torso. The gamepad communicates with the robot through a USB dongle, which is connected to the robot. The gamepad is powered by 2 AA batteries.
Note
A gamepad is included with the TIAGo base, TIAGo and TIAGo Pro robot packages. For other robots, you can use your own controller. Any wireless game controller compatible with the ROS package joy should work.
Controls#
Note
- Before moving the robot, press START in order to give command
priority to the gamepad.
This section gives you key mappings of the controller and their actions
(coloured commands indicate that you have to press 2 keys at a time in order to perform the action.)
Instruction |
Gamepad keys |
---|---|
Move |
RB + Left Joystick (toggle navigation with START) |
Rotate |
RB + Right Joystick (toggle navigation with START) |
Move Head (up, right, down, left) |
Y, B, A, X |
Modify linear velocity (increase , decrease) |
BACK+Y, BACK+A |
Modify angular velocity (increase , decrease) |
BACK+X, BACK+B |
Reset settings |
Troubleshoot#
If the robot is not responding as expected to the gamepad, the following steps can be followed to troubleshoot the problem.
1. Gamepad battery: Press the vibration button on the gamepad. If the joystick does not vibrate, the batteries of the gamepad have to be changed (2X AA battery).
2. Gamepad button configuration: In some cases the robot will respond to the gamepad, but not with the expected behavior. This can be due to the button configuration of the gamepad. To ensure the correct configuration check if the input switch (on the top of the gamepad) is set to D and not to X. Furthermore, the LED next to the mode button, should be off. If the LED is on, press the mode button to enable the correct configuration.
3. USB dongle: Check if the USB dongle is plugged in the robot. The dongle is not always plugged in an easily accessible place. By using the following command you can check if the dongle is connected to the robot:
ll /dev/joystick
# expected output:
# /dev/joystick -> input/js0
If an input device is found, this means the USB dongle is correctly plugged in the robot.
4. Gamepad diagnostics: Open the diagnostics tab in the WebGUI and check under Diagnostics->Hardware->Gamepad. Ensure the diagnostics are OK.
Gamepad module: Use the following command to show the log of the gamepad module.
pal module log jostick cat
When the robot is in self-collision, e.g. the arms are touching the base, the head and torso cannot be controlled with the gamepad. The log of the gamepad will explain which joints are in self-collision. To get out of self-collision, change to gravity compensation to move the arms to a different position.
6. Gamepad connection: Check if robot is receiving commands by from the gamepad by listening
to the topic /joy
while pressing buttons on the joystick:
ros2 topic echo /joy
If no output is shown, the gamepad might be out of reach of the robot.
See also#
General information about your robot’s hardware
Documentation of the underlying
joy
ROS node: https://index.ros.org/p/joy/#humble