teleop_node (teleop_twist_joy)¶
Converts joystick input to robot velocity commands.
| Entrypoint | 70-teleop-twist-joy.sh |
| Subscribes to | /joy (sensor_msgs/Joy) |
| Publishes | /cmd_vel (geometry_msgs/Twist) |
Axis mapping:
| Joy axis | Twist field | Control |
|---|---|---|
| Axis 0 (horizontal) | angular.z |
Turn left/right (1.0 rad/s max) |
| Axis 1 (vertical) | linear.x |
Forward/backward (1.0 m/s max) |
The Foxglove joystick's vertical axis is inverted (pushing up = negative value), so scale_linear.x is set to -1.0 to compensate. The deadman switch is disabled (require_enable_button:=false) so input goes straight to /cmd_vel. The cmd_vel_relay node then forwards to /cmd_vel_raw for Isaac Sim's OmniGraph differential drive (see Nav2 architecture). Used with the foxglove-joystick extension in Foxglove, publishing to /joy.
ROS2 Schema Fix Required
The original extension uses sensor_msgs/Joy (ROS1 schema). ROS2 requires sensor_msgs/msg/Joy, so the foxglove bridge rejects it with "Unknown message definition." Use the fixed build from MSSergeev's fork which adds ROS2 auto-detection.
Download: foxglove-joystick-ros2-fixed.foxe
Install by dragging the .foxe file onto the Foxglove Studio window. If you have the original extension installed, remove it first (Profile → Extensions → uninstall).