Hector Quadrotor [Error] Button 3 out of range, joy has 2 buttons
When I launch the Hector Quadrotor demos I receive a constant string of errors reading:
[Error] [1489003251.6321324, 135.9000000]: Button 3 out of range, joy has 2 buttons
I am also unable to control the quadcoptor through the keyboard teleop modules, or just writing the the /cmd_vel
topic directly via rostopic
. Are these two things related?
Asked by jdtf on 2017-03-08 15:03:38 UTC
Answers
Hi, I faced the same issue and although it seems you posted your question while ago, I answer so it might be helpful for other folks. Actually, this error, related to running last launch file in the demo launch file "hector_dronerace.launch" where "xbox_controller.launch" is launched. To avoiding this error, you need to connect "xbox joystick" to your laptop. If you don't have one (like me), you can still control the robot with keyboard teleop modules as you mentioned with command: rosrun tiers_drone_racing tello_controller.py However, as you mentioned, with running the default "hector_dronerace.launch", running of above command does not work, because the robot version that spawn in "hector_dronerace.launch" is "quadrotor_with_asus_with_hokuyo_utm30lx" which does not subscribe to /cmd_vel. If you replace:
with
in "hector_dronerace.launch" (using the default values in "spawn_quadrotor.launch"), you will be able to control the uav with keyboard teleop. Do not forget to enable motors with writing below command in another terminal rosservice call /enable_motors "enable: true"
Asked by Amirkhosro on 2020-12-22 14:49:47 UTC
Comments