How to be connected to the real robot ROS 2 project

Good morning,

I would like to know how to make sure that my script is correctly sent to the real robot.

I have figured out how to connect to it, but when I do, the rostopic list and rviz commands are not recognized, and I used the bridge command to send my command in ROS2 to the robot in ROS 1, I guess.

Kind regards,

Hi @ClairePottier ,

If you are working with ROS2, you need the ros_bridge as you already noted.
Before you connect to the real robot, make sure that your packages are compiled - so that you do not waste time compiling the packages after the connection is established.

Once connected to the real robot, run the ros_bridge code on one terminal.
You can use the new terminals/shells to launch your program, while your bridge is running on the first terminal.
Your code shoudl work on the real robot directly, without any additional steps.

The procedure is exactly same as what you do in simulation, with only one minor change: You will not start the simulation, just assume that robot will work.

Also once the connection is established, make sure that all the three lights on the robot status screen goes green - I think it has /cmd_vel, /odom and /tf. Once all the 3 lights are green, rostopic list will work. After you confirm the output of rostopic list you can start the ros_bridge.

The robot uses ROS1, so it will respond to ROS1 commands by default. For ROS2 commands to work, you need to have the bridge running.

I hope this explanation is clear.


1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.