Joystick driver in ROS

asked 2022-06-30 12:36:48 -0500

pitosalas gravatar image

updated 2022-06-30 12:37:21 -0500

I am playing with the joystick driver in ROS. It works. Except that when I stop moving the joystick around, it stops sending out cmd_vels. In other words, even if the joystick is off the center position, it stops sending cmd_vels. Now this is "expected" in the case when the "autorepeat_rate" parameter is set to zero.

But I have set it to a higher number and it still is happening. I believe I have isolated it to joy_node.cpp in joytstick_drivers repo but I don't see a bug. I believe this is the source code: https://github.com/ros-drivers/joysti...

Any help will be appreciated! Here is the console output at launch:

========

PARAMETERS
 * /joy_node/autorepeat_rate: 8.00
 * /joy_node/coalesce_interval: 0.002
 * /joy_node/dev: /dev/input/js0
 * /rosdistro: noetic
 * /rosversion: 1.15.14
 * /teleop_twist_joy/axis_angular: 2
 * /teleop_twist_joy/axis_linear: 3
 * /teleop_twist_joy/enable_button: 6
 * /teleop_twist_joy/enable_turbo_button: 4
 * /teleop_twist_joy/scale_angular: 1.5
 * /teleop_twist_joy/scale_angular_turbo: 3.0
 * /teleop_twist_joy/scale_linear: 0.5
 * /teleop_twist_joy/scale_linear_turbo: 1.0

NODES
  /
    joy_node (joy/joy_node)
    teleop_twist_joy (teleop_twist_joy/teleop_node)

auto-starting new master
process[master]: started with pid [2171]
ROS_MASTER_URI=http://100.64.81.29:11311

setting /run_id to c5a730da-f891-11ec-9fc0-35161e517679
process[rosout-1]: started with pid [2181]
started core service [/rosout]
process[teleop_twist_joy-2]: started with pid [2188]
process[joy_node-3]: started with pid [2189]
edit retag flag offensive close merge delete