... | ... | @@ -58,7 +58,7 @@ _TurtleBot 4_ is the next-generation of the world’s most popular open-source r |
|
|
|
|
|
For this course, the _Turtlebot 4_ is simulated, using a 2D simulator called _simple simulator_, which can run well in ThinLinc or the lab computers. The official project uses a 3D simulator, [https://gazebosim.org/](Gazebo), which works poorly on the IDA's computers.
|
|
|
|
|
|
Setup the environment
|
|
|
Setup the Environment
|
|
|
---------------------
|
|
|
|
|
|
### Setting up ```.bashrc``` file:
|
... | ... | @@ -96,16 +96,14 @@ Start Apptainer ROS |
|
|
start_ros
|
|
|
```
|
|
|
|
|
|
<div style="padding: 5pt;background-color: rgb(221, 250, 221);border-left: 3px solid rgb(106, 222, 106);margin-bottom: 1ex;">
|
|
|
|
|
|
**Important Note!**
|
|
|
|
|
|
```start_ros``` needs to be used to start ```bash``` terminal with ROS setup when you open a new Terminal window.
|
|
|
|
|
|
**This has to be run always before any commands discussed below when using new Terminal window (as shown in the "Starting the simulator section), otherwise ROS commands will not work.**
|
|
|
</div>
|
|
|
|
|
|
Starting the simulator
|
|
|
Starting the Simulator
|
|
|
-------------------
|
|
|
|
|
|
To start the robot platform with the simple simulator, open new Terminal and run:
|
... | ... | @@ -206,7 +204,7 @@ If you were successful, your Rviz window should look as on the screenshot blow. |
|
|
|
|
|
|
|
|
|
|
|
Sending commands to the robot
|
|
|
Sending Commands to the Robot
|
|
|
-------------------------
|
|
|
|
|
|
The robot is ready to accept commands. The first commands you can send to the robot are for docking and undocking, in a terminal:
|
... | ... | @@ -228,7 +226,7 @@ The following action can be used to move the robot to a specific position: |
|
|
ros2 action send_goal /navigate_to_position irobot_create_msgs/action/NavigateToPosition "{achieve_goal_heading: true,goal_pose:{pose:{position:{x: 3, y: 4,z: 0.0}, orientation:{x: 0.0,y: 0.0, z: 0.0, w: 1.0}}}}"
|
|
|
```
|
|
|
|
|
|
Managing topics from the command line
|
|
|
Managing Topics from the Command Line
|
|
|
-------------------------------------
|
|
|
|
|
|
The main communication medium for ROS is through the use of _topics_. Topics have a name and a type and follow a publisher-subscriber pattern. You can use the following command to list all available topics:
|
... | ... | @@ -287,7 +285,7 @@ You should see something like this: |
|
|
|
|
|

|
|
|
|
|
|
screen
|
|
|
GNU Screen Tool
|
|
|
------
|
|
|
|
|
|
As you can see, we ended up starting a lot of commands from the terminal. It can be annoying to have so many windows and terminals open, a solution is to use [GNU Screen](https://www.gnu.org/software/screen/), which allows to start all the processes in a single terminal window.
|
... | ... | |