ROS driver package for robotont.
This package handles low-level communication between ROS and robotont hardware.
2. Install ROS 2 Jazzy Installing ROS2 Jazzy
sudo apt install ros-jazzy-robotont-driver source /opt/ros/jazzy/setup.bash
ros2 launch robotont_driver driver_launch.pyLaunch parameters are defined in 3 different places. With the following hierarchy (lower number overwrites higher number):
- 1: The parameters defined in the parameters file
- 2: The parameters specified via command line, when using the launch file
- 3: The parameters hardcoded in the driver code
To change the launch parameters once, they can also be specified via the command line:
ros2 launch robotont_driver driver_launch.py device_name:='/dev/ttyACM0'2. Install ROS 2 Jazzy and create a workspace Creating a workspace
Navigate to workspace root folder
sudo rosdep init
rosdep update
rosdep install --from-paths src -y --ignore-srcThe driver also relies on the following packages:
- 1: io-context
- 2: serial-driver
- 3: asio-cmake-module
sudo apt install ros-jazzy-io-context ros-jazzy-serial-driver ros-jazzy-asio-cmake-moduleEnsure you are in your workspace root folder and enter the following commands to install them:
colcon buildsource install/local_setup.bash
ros2 launch robotont_driver driver_launch.pyLaunch parameters are defined in 3 different places. With the following hierarchy (lower number overwrites higher number):
- 1: The parameters defined in the parameters file
- 2: The parameters specified via command line, when using the launch file
- 3: The parameters hardcoded in the driver code
To change the launch parameters once, they can also be specified via the command line:
ros2 launch robotont_driver driver_launch.py device_name:='/dev/ttyACM0'The drivers for the simulated and the real robot both subscribe to a cmd_vel topic. To move the robot, we have to publish velocity messages to this exact topic.
Here we use the teleop_twist_keyboard node, which translates command line keypresses to velocity messages and published these by default on cmd_vel topic.
Run the node
ros2 run teleop_twist_keyboard teleop_twist_keyboard- Follow the printout in the console to learn how to control the robot. Enjoy the ride!
This plugin receives the ODOM packet from the robot and publishes the data on /odom (<nav_msgs::Odometry>) topic. This plugin also broadcasts an odom frame via TF.
This plugin subscribes to cmd_vel topic and relays the velocities to robotont's motors