Connecting to real robots - RobotTeaching/COMP4034 GitHub Wiki
Connecting to the robots in the lab
Once you verified that your code works in simulation, you can test it with the real robots.
NOTE: make sure you have TERMINATED EVERYTHING EXCEPT ROSCORE on the lab machine BEFORE you bring-up the TurtleBot. If Gazebo or any code is running when you try and bring-up the robot, it won't work :)
In order to run your program with the robots,
- Turn on the robots, if you don't have a battery, ask one of your TAs.
- Leave the Turtlebots safely on the floor, or on the desk on top of realsense boxes, so that they don't move abruptly.
- Login to the lab machines with the team passwords given to you.
- In the lab machine,
ssh team@turtlebot
and login with the passwords sent to you on Teams (the turtlebot passwords are different than your team passwords. - You will see
team@turtlebot
on the terminal, check the name is the same with the robot on your desk. - On the robot,
cd catkin_ws
andsource devel/setup.bash
- On the robot, run
roslaunch turtlebot3_bringup turtlebot3_robot.launch
. Make sure you haveroscore
running on a local terminal! - Move onto your own machine and run your script.
- Enjoy the operation of your amazing program!
In order to connect the cameras:
- On the turtlebot, keep everything else running except for your code :) (i.e. roscore on PC and bringup on turtlebot),
- On the turtlebot: run
roslaunch realsense2_camera rs_camera.launch align_depth:=true
- Test that you receive the image topic with a
rostopic echo