Welcome to the BeetleBot repository! This repository contains different configurations for the BeetleBot differential drive robot with Gazebo sim. Each branch in this repository represents a unique configuration of the same beetlebot robot in the world it operates in.
This repository has Two branches, each with a different configuration for the robot and the world.
Below is a summary of the differences between each branch:
1. SDF-format
In this branch beetlebot robot is writen in SDF format and spawnd inside the main world using spawner cmd
in the launch file.
2. URDF-format
In this branch beetlebot robot is writen as URDF and spawnd inside the main world using spawner cmd
in the launch file.
- Separate Robot Module: Each robot component is defined as a standalone SDF or URDF module for maximum flexibility and reusability.
- Custom World GUI Configuration Plugins: Includes a configurable GUI plugin to tailor the simulation interface to your needs.
- 360° LIDAR Plugin: Provides a simulated LIDAR sensor capable of full 360° scanning for obstacle detection and mapping.
- Differential Drive Plugin: Implements a differential drive controller for robot mobility, ensuring smooth and accurate navigation.
- RGB Camera: Equipped with an RGB camera for visual feedback.
- Position Joint Control: Allows changing the camera angle using position joint control.
Ensure you have the following:
- ROS 2 Jazzy installed on your system.
- Gazebo Harmonic for robot simulation.
-
Clone the repository:
git clone --branch <branch-name> https://github.com/KroNton/beetlebot.git
replace
<branch-name>
with one of the following branches :sdf-format_include-model-world
sdf-format_spawn-model-launch
urdf-format
-
Build the ROS 2 package:
colcon build
-
Source the setup file:
source install/setup.bash
ros2 launch beetlebot_gazebo beetlebot_empty_world.launch.py
-
Using gazebo
- add
key publisher
to gazebo form top right - Use the keyboard arrow keys to move the robot.
- Press
k
to stop the robot.
- add
-
Using ROS teleop node
ros2 run teleop_twist_keyboard teleop_twist_keyboard
ros2 launch beetlebot_gazebo beetlebot_warehouse.launch.py
ros2 launch beetlebot_gazebo beetlebot_track_world.launch.py
You can control the camera angle by publishing to the /camera_angle
topic.
- Open a new terminal.
- Publish a message to the
/camera_angle
topic to change the camera angle. For example, to set the camera angle to 0.5 radians:ros2 topic pub /camera_angle std_msgs/msg/Float64 "{data: 0.5}"
This file configures the ROS-Gazebo bridge for topic communication.
---
- ros_topic_name: "/cmd_vel"
gz_topic_name: "/cmd_vel"
ros_type_name: "geometry_msgs/msg/Twist"
gz_type_name: "gz.msgs.Twist"
direction: ROS_TO_GZ
- ros_topic_name: "/clock"
gz_topic_name: "/world/beetlebot_world/clock"
ros_type_name: "rosgraph_msgs/msg/Clock"
gz_type_name: "gz.msgs.Clock"
direction: GZ_TO_ROS
.....
- Add more sensor plugins.
- Improve the robot's navigation algorithms.
- Add support for additional simulation environments.