ros controller topics not being published
I am trying to write a custum ros hardware interface following this tutorial. I am trying to make a hardware interface for rrbot for testing purpose as it provides already present rrbot descrition and some launch files. Here is the git repository of this catkin package, which sucessfully builds but when i try to view the position controller topics i'm only seeing following ros topics:
$ rostopic list
/rosout
/rosout_agg
/rrbot/joint_states
/tf
/tf_static
when i launch the hardware interface node with the controller with command:
roslaunch rrbot_control rrbot_hardware_interface.launch
the output of the terminal display is:
started core service [/rosout]
process[rrbot/rrbot_hw_interface-2]: started with pid [14994]
process[rrbot/controller_spawner-3]: started with pid [14998]
process[rrbot/robot_state_publisher-4]: started with pid [14999]
read
write
[INFO] [1589016205.926310]: Controller Spawner: Waiting for service controller_manager/load_controller
[INFO] [1589016205.932689]: Controller Spawner: Waiting for service controller_manager/switch_controller
[INFO] [1589016205.938694]: Controller Spawner: Waiting for service controller_manager/unload_controller
[INFO] [1589016205.944457]: Loading controller: joint_state_controller
read
write
read
write
^C[rrbot/robot_state_publishe
r-4] killing on exit
[rrbot/controller_spawner-3] killing on exit
[rrbot/rrbot_hw_interface-2] killing on exit
[INFO] [1589016208.067200]: Shutting down spawner. Stopping and unloading controllers...
read
write
I am using ubuntu 18.04, ros melodic.
You're most likely not
spin()
ing. Specifically: here.i tried that also. but still not working.
Have you tried using a ros::AsyncSpinner? If I remember correctly, it is needed to let the controller manager do its job while the hw is running...
And for future questions: "it does not work" is not a sufficient description of your problem.
No one can help you like this.