These instructions are based on the Robotis e-Manual for the Turtlebot3. Read the Quick Start Guide to gain an overall understanding of the process. Always click the tab for the ROS Version (i.e. Noetic).
Assuming the TB3 (waffel_pi version) contains a RPi3B+, OpenCR board, LDS-01 LIDAR, and an image running Ubuntu 20.04 with ROS Noetic based on these instructions. If there is no image, see your instructor.
- From a WREN Linux computer (Ubuntu 20.04), ssh into the TB3 using the IP address found on the lower waffel. Username is
ubuntu
and password isturtlebot
.
- Open the .bashrc
nano .bashrc
- Check that your .bashrc on the RPi has these settings:
source /opt/ros/noetic/setup.bash
source ~/catkin_ws/devel/setup.bash
export ROS_MASTER_URI=http://10.X.X.X:11311 # Remote PC
export ROS_HOSTNAME=10.X.X.X # RPI3
export LDS_MODEL=LDS-01
export OPENCR_PORT=/dev/ttyACM0
export OPENCR_MODEL=waffle_noetic
export TURTLEBOT3_MODEL=waffle_pi
-
Save the .bashrc (Ctrl-x).
-
Re-source the .bashrc.
source .bashrc
- Check the settings on the remote PC (Desktop):
nano .bashrc
- Check that your .bashrc on the remote PC has these settings:
source /opt/ros/noetic/setup.bash
source ~/catkin_ws/devel/setup.bash
export ROS_MASTER_URI=http://10.X.X.X:11311 # Remote PC
export ROS_HOSTNAME=10.X.X.X # Remote PC
export TURTLEBOT3_MODEL=waffle_pi
- Save and re-source the .bashrc.
source .bashrc
- All of the previous commands are based on the Quick Start Guide. Always click the tab for the ROS Version (i.e. Noetic).
Both the Remote PC (desktop or laptop) and TB3 (RPi) should be properly configured to communicate on the same ROS network over the WREN.
Follow the bringup instructions to start both the Remote PC and TB3.
If you get error messages on the RPi, re-load the firmware to the OpenCR board based on these instructions.
cd ./opencr_update
./update.sh $OPENCR_PORT $OPENCR_MODEL.opencr
After bringup, perform teleoperation using these instructions.
In order to run Raspberry Pi Camera Module, raspicam_node package
will be used.
- Access to TB3 via
ssh
ssh [email protected] # Turtlebot IP
- Update
turtlebot3
package
cd ~/catkin_ws/src/turtlebot3 && git pull
Remove broken work spaces. If you are using the following folders, do not run the command.
rm -r turtlebot3_description/ turtlebot3_teleop/ turtlebot3_navigation/ turtlebot3_slam/ turtlebot3_example/
Build.
cd ~/catkin_ws && catkin_make
- Install libcamera-based stack
sudo apt install libraspberrypi-bin libraspberrypi-dev
- Build
raspicam_node
cd ~/catkin_ws/src
git clone https://github.com/UbiquityRobotics/raspicam_node.git
sudo apt-get install ros-noetic-compressed-image-transport ros-noetic-camera-info-manager ros-noetic-diagnostic-updater
cd ~/catkin_ws && catkin_make --only-pkg-with-deps raspicam_node
- Enable camera module
sudo nano /boot/firmware/config.txt
Add the following lines below [all]
start_x=1
gpu_mem=128
sudo usermod -a -G video $USER
sudo reboot
- Testing the camera node
To see if the camera connected,
vcgencmd get_camera
If the output is supported=1 detected=1
, run raspicam_node
package by following steps
On your PC:
roscore
On the TB3:
roslaunch raspicam_node camerav2_1280x960.launch
On your PC:
rqt_image_view
At the top of the image viewer, select the raspicam_node topic.