Repository Summary
Checkout URI | https://github.com/AutonomyLab/create_robot.git |
VCS Type | git |
VCS Version | humble |
Last Updated | 2023-05-21 |
Dev Status | MAINTAINED |
CI status | No Continuous Integration |
Released | RELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (0)
Good First Issues (0) Pull Requests to Review (0) |
Packages
Name | Version |
---|---|
create_bringup | 3.1.0 |
create_description | 3.1.0 |
create_driver | 3.1.0 |
create_msgs | 3.1.0 |
create_robot | 3.1.0 |
README
create_robot
ROS driver for iRobot Create 1 and 2. This package wraps the C++ library libcreate, which uses iRobot’s Open Interface Specification.
- ROS wiki page: http://wiki.ros.org/create_robot
- Support: ROS Answers (tag: create_robot)
- Author: Jacob Perron (Autonomy Lab, Simon Fraser University)
Build Status
- ROS Rolling (branch:
rolling
) - ROS Iron (branch:
iron
) - ROS Humble (branch:
humble
) - ROS Foxy (branch:
foxy
) - ROS Noetic (branch:
noetic
)
Supported Robots
Model | Support |
---|---|
Create 1 | Yes |
Create 2 (firmware >= 3.2.6) | Yes |
Roomba Original Series | No |
Roomba 400 Series | Yes |
Roomba 500 Series | Yes * |
Roomba 600 Series | Yes * |
Roomba 700 Series | Yes + |
Roomba 800 Series | Yes + |
Roomba 900 Series | No * |
+ Verified by third-party. Please note Odometry Issue #28 * Not verified. Anyone who is able to verify that this driver works or not is encouraged to contact Jacob with their findings or open an issue.
Features
Feature | Status |
---|---|
Odometry | Available |
Safe mode | Planned #13 |
Clean demo | Planned #14 |
Dock demo | Available |
Drive wheels | N/A |
Drive (v,w) | Available |
Brush motors | Available |
LEDs | Available |
Digit LEDs | Available |
Sound | Available |
Wheeldrop | Available |
Bumpers | Available |
Cliff sensor | Available |
Dirt detect | N/A |
Omni IR sensor | Available |
Left IR sensor | N/A |
Right IR sensor | N/A |
Battery info | Available |
Light sensors | Available |
Diagnostics | |
Corrupt packets | Available |
Overcurrent info | N/A |
Install
Prerequisites
- Internet connection
- ROS 2
- Ubuntu packages:
python3-rosdep
,python3-colcon-common-extensions
$ sudo apt install python3-rosdep python3-colcon-common-extensions
Compiling
- Create a colcon workspace
$ cd ~
$ mkdir -p create_ws/src
$ cd create_ws
- Clone this repo
$ cd ~/create_ws/src
$ git clone https://github.com/autonomylab/create_robot.git
$ git clone https://github.com/AutonomyLab/libcreate.git
- Install dependencies
$ cd ~/create_ws
$ rosdep update
$ rosdep install --from-paths src -i
- Build
$ cd ~/create_ws
$ colcon build
USB Permissions
- In order to connect to Create over USB, ensure your user is in the dialout group
$ sudo usermod -a -G dialout $USER
- Logout and login for permission to take effect
Running the driver
Setup
- After compiling from source, don’t forget to source your workspace:
$ source ~/create_ws/install/setup.bash
- Connect computer to Create’s 7-pin serial port
- If using Create 1, ensure that nothing is connected to Create’s DB-25 port
- Launch one of the existing launch files or adapt them to create your own.
Launch files
For Create 2 (Roomba 600/700 series):
$ ros2 launch create_bringup create_2.launch
For Create 1 (Roomba 500 series):
$ ros2 launch create_bringup create_1.launch
For Roomba 400 series:
$ ros2 launch create_bringup roomba_400.launch
Launch file arguments
-
config - Absolute path to a configuration file (YAML). Default:
create_bringup/config/default.yaml
-
desc - Enable robot description (URDF/mesh). Default:
true
For example, if you would like to disable the robot description and provide a custom configuration file:
$ ros2 launch create_bringup create_2.launch config:=/abs/path/to/config.yaml desc:=false
Parameters
Name | Description | Default |
---|---|---|
dev |
Device path of robot | /dev/ttyUSB0 |
base_frame |
The robot’s base frame ID | base_footprint |
odom_frame |
The robot’s odometry frame ID | odom |
latch_cmd_duration |
If this many seconds passes without receiving a velocity command the robot stops | 0.2 |
loop_hz |
Frequency of internal update loop | 10.0 |
publish_tf |
Publish the transform from odom_frame to base_frame
|
true |
robot_model |
The type of robot being controlled (supported values: ROOMBA_400 , CREATE_1 and CREATE_2 ) |
CREATE_2 |
baud |
Serial baud rate | Inferred based on robot model, but is overwritten upon providing a value |
oi_mode_workaround |
Some Roomba models incorrectly report the current OI mode in their sensor streams. Setting this to true will cause libcreate to decrement the OI mode received in the sensor stream by 1
|
false |
Publishers
Topic | Description | Type |
---|---|---|
battery/capacity |
The estimated charge capacity of the robot’s battery (Ah) | std_msgs/msg/Float32 |
battery/charge |
The current charge of the robot’s battery (Ah) | std_msgs/msg/Float32 |
battery/charge_ratio |
Charge / capacity | std_msgs/msg/Float32 |
battery/charging_state |
The chargins state of the battery | create_msgs/msg/ChargingState |
battery/current |
Current flowing through the robot’s battery (A). Positive current implies charging | std_msgs/msg/Float32 |
battery/temperature |
The temperature of the robot’s battery (degrees Celsius) | std_msgs/msg/Int16 |
battery/voltage |
Voltage of the robot’s battery (V) | std_msgs/msg/Float32 |
bumper |
Bumper state message (including light sensors on bumpers) | create_msgs/msg/Bumper |
cliff |
Cliff state message | create_msgs/msg/Cliff |
clean_button |
‘clean’ button is pressed (‘play’ button for Create 1) | std_msgs/msg/Empty |
day_button |
‘day’ button is pressed | std_msgs/msg/Empty |
hour_button |
‘hour’ button is pressed | std_msgs/msg/Empty |
minute_button |
‘minute’ button is pressed | std_msgs/msg/Empty |
dock_button |
‘dock’ button is pressed (‘advance’ button for Create 1) | std_msgs/msg/Empty |
spot_button |
‘spot’ button is pressed | std_msgs/msg/Empty |
ir_omni |
The IR character currently being read by the omnidirectional receiver. Value 0 means no character is being received | std_msgs/msg/UInt16 |
joint_states |
The states (position, velocity) of the drive wheel joints | sensor_msgs/msg/JointState |
mode |
The current mode of the robot (See OI Spec for details) | create_msgs/msg/Mode |
odom |
Robot odometry according to wheel encoders | nav_msgs/msg/Odometry |
wheeldrop |
At least one of the drive wheels has dropped | std_msgs/msg/Empty |
/tf |
The transform from the odom frame to base_footprint . Only if the parameter publish_tf is true
|
tf2_msgs/msg/TFMessage |
diagnostics |
Info about the battery charge, wheeldrop/cliff state, robot mode, and serial connection | diagnostic_msgs/msg/DiagnosticArray |
Subscribers
Topic | Description | Type |
---|---|---|
cmd_vel |
Drives the robot’s wheels according to a forward and angular velocity | geometry_msgs/msg/Twist |
debris_led |
Enable / disable the blue ‘debris’ LED | std_msgs/msg/Bool |
spot_led |
Enable / disable the ‘spot’ LED | std_msgs/msg/Bool |
dock_led |
Enable / disable the ‘dock’ LED | std_msgs/msg/Bool |
check_led |
Enable / disable the ‘check robot` LED | std_msgs/msg/Bool |
power_led |
Set the ‘power’ LED color and intensity. Accepts 1 or 2 bytes, the first represents the color between green (0) and red (255) and the second (optional) represents the intensity with brightest setting as default (255) | std_msgs/msg/UInt8MultiArray |
set_ascii |
Sets the 4 digit LEDs. Accepts 1 to 4 bytes, each representing an ASCII character to be displayed from left to right | std_msgs/msg/UInt8MultiArray |
dock |
Activates the demo docking behaviour. Robot enters Passive mode meaning the user loses control (See OI Spec) | std_msgs/msg/Empty |
undock |
Switches robot to Full mode giving control back to the user | std_msgs/msg/Empty |
define_song |
Define a song with up to 16 notes. Each note is described by a MIDI note number and a float32 duration in seconds. The longest duration is 255/64 seconds. You can define up to 4 songs (See OI Spec) | create_msgs/msg/DefineSong |
play_song |
Play a predefined song | create_msgs/msg/PlaySong |
Commanding your Create
You can move the robot around by sending geometry_msgs/msg/Twist messages to the topic cmd_vel
:
linear.x (+) Move forward (m/s)
(-) Move backward (m/s)
angular.z (+) Rotate counter-clockwise (rad/s)
(-) Rotate clockwise (rad/s)
Velocity limits
` -0.5 <= linear.x <= 0.5 and
-4.25 <= angular.z <= 4.25`
Teleoperation
create_bringup
comes with a launch file for teleoperating Create with a joystick.
$ ros2 launch create_bringup joy_teleop.launch joy_config:=xbox360
There exists configuration files for the Xbox 360 wired controller and the Logitech F710 controller. You can adapt these files for your preferred joystick configuration.
Contributions
Contributing to the development and maintenance of create_autonomy is encouraged. Feel free to open issues or create pull requests on GitHub.
Contributors
-
Michael Browne
- Confirms driver works with Roomba 700 and 800 series.
-
Clyde McQueen
- Added support for sound (#37).
- Ben Wolsieffer
-
Pedro Grojsgold
- Ported to ROS 2 (commit).
-
Josh Gadeken
- Added parameter for libcreate’s OI Mode reporting workaround (#95)
CONTRIBUTING
Repository Summary
Checkout URI | https://github.com/AutonomyLab/create_robot.git |
VCS Type | git |
VCS Version | melodic |
Last Updated | 2023-05-21 |
Dev Status | MAINTAINED |
CI status | No Continuous Integration |
Released | RELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (0)
Good First Issues (0) Pull Requests to Review (0) |
Packages
Name | Version |
---|---|
create_bringup | 2.0.0 |
create_description | 2.0.0 |
create_driver | 2.0.0 |
create_msgs | 2.0.0 |
create_robot | 2.0.0 |
README
create_robot
ROS driver for iRobot Create 1 and 2. This package wraps the C++ library libcreate, which uses iRobot’s Open Interface Specification.
- ROS wiki page: http://wiki.ros.org/create_robot
- Support: ROS Answers (tag: create_robot)
- Author: Jacob Perron (Autonomy Lab, Simon Fraser University)
Build Status
- ROS Rolling (branch:
rolling
) - ROS Iron (branch:
iron
) - ROS Humble (branch:
humble
) - ROS Foxy (branch:
foxy
) - ROS Noetic (branch:
noetic
) - ROS Melodic (branch:
melodic
)
Supported Robots
Model | Support |
---|---|
Create 1 | Yes |
Create 2 (firmware >= 3.2.6) | Yes |
Roomba Original Series | No |
Roomba 400 Series | Yes |
Roomba 500 Series | Yes * |
Roomba 600 Series | Yes * |
Roomba 700 Series | Yes + |
Roomba 800 Series | Yes + |
Roomba 900 Series | No * |
+ Verified by third-party. Please note Odometry Issue #28 * Not verified. Anyone who is able to verify that this driver works or not is encouraged to contact Jacob with their findings or open an issue.
Features
Feature | Status |
---|---|
Odometry | Available |
Safe mode | Planned #13 |
Clean demo | Planned #14 |
Dock demo | Available |
Drive wheels | N/A |
Drive (v,w) | Available |
Brush motors | Available |
LEDs | Available |
Digit LEDs | Available |
Sound | Available |
Wheeldrop | Available |
Bumpers | Available |
Cliff sensor | Planned #22 |
Dirt detect | N/A |
Omni IR sensor | Available |
Left IR sensor | N/A |
Right IR sensor | N/A |
Battery info | Available |
Light sensors | Available |
Diagnostics | |
Corrupt packets | Available |
Overcurrent info | N/A |
Install
Prerequisites
- Internet connection
- ROS
- Ubuntu packages:
python3-rosdep
,python3-catkin-tools
$ sudo apt-get install python3-rosdep python3-catkin-tools
Compiling
- Create a catkin workspace
$ cd ~
$ mkdir -p create_ws/src
$ cd create_ws
$ catkin init
- Clone this repo
$ cd ~/create_ws/src
$ git clone https://github.com/autonomylab/create_robot.git --branch noetic
- Install dependencies
$ cd ~/create_ws
$ rosdep update
$ rosdep install --from-paths src -i
- Install dependencies
$ cd ~/create_ws
$ rosdep update
$ rosdep install --from-paths src -i
- Build
$ cd ~/create_ws
$ catkin build
USB Permissions
- In order to connect to Create over USB, ensure your user is in the dialout group
$ sudo usermod -a -G dialout $USER
- Logout and login for permission to take effect
Running the driver
Setup
- After compiling from source, don’t forget to source your workspace:
$ source ~/create_ws/devel/setup.bash
- Connect computer to Create’s 7-pin serial port
- If using Create 1, ensure that nothing is connected to Create’s DB-25 port
- Launch one of the existing launch files or adapt them to create your own.
Launch files
For Create 2 (Roomba 600/700 series):
$ roslaunch create_bringup create_2.launch
For Create 1 (Roomba 500 series):
$ roslaunch create_bringup create_1.launch
For Roomba 400 series:
$ roslaunch create_bringup roomba_400.launch
Launch file arguments
-
config - Absolute path to a configuration file (YAML). Default:
create_bringup/config/default.yaml
-
desc - Enable robot description (URDF/mesh). Default:
true
For example, if you would like to disable the robot description and provide a custom configuration file:
$ roslaunch create_bringup create_2.launch config:=/abs/path/to/config.yaml desc:=false
Parameters
Name | Description | Default |
---|---|---|
dev |
Device path of robot | /dev/ttyUSB0 |
base_frame |
The robot’s base frame ID | base_footprint |
odom_frame |
The robot’s odometry frame ID | odom |
latch_cmd_duration |
If this many seconds passes without receiving a velocity command the robot stops | 0.2 |
loop_hz |
Frequency of internal update loop | 10.0 |
publish_tf |
Publish the transform from odom_frame to base_frame
|
true |
robot_model |
The type of robot being controlled (supported values: ROOMBA_400 , CREATE_1 and CREATE_2 ) |
CREATE_2 |
baud |
Serial baud rate | Inferred based on robot model, but is overwritten upon providing a value |
Publishers
Topic | Description | Type |
---|---|---|
battery/capacity |
The estimated charge capacity of the robot’s battery (Ah) | std_msgs/Float32 |
battery/charge |
The current charge of the robot’s battery (Ah) | std_msgs/Float32 |
battery/charge_ratio |
Charge / capacity | std_msgs/Float32 |
battery/charging_state |
The chargins state of the battery | create_msgs/ChargingState |
battery/current |
Current flowing through the robot’s battery (A). Positive current implies charging | std_msgs/Float32 |
battery/temperature |
The temperature of the robot’s battery (degrees Celsius) | std_msgs/Int16 |
battery/voltage |
Voltage of the robot’s battery (V) | std_msgs/Float32 |
bumper |
Bumper state message (including light sensors on bumpers) | create_msgs/Bumper |
clean_button |
‘clean’ button is pressed (‘play’ button for Create 1) | std_msgs/Empty |
day_button |
‘day’ button is pressed | std_msgs/Empty |
hour_button |
‘hour’ button is pressed | std_msgs/Empty |
minute_button |
‘minute’ button is pressed | std_msgs/Empty |
dock_button |
‘dock’ button is pressed (‘advance’ button for Create 1) | std_msgs/Empty |
spot_button |
‘spot’ button is pressed | std_msgs/Empty |
ir_omni |
The IR character currently being read by the omnidirectional receiver. Value 0 means no character is being received | std_msgs/UInt16 |
joint_states |
The states (position, velocity) of the drive wheel joints | sensor_msgs/JointState |
mode |
The current mode of the robot (See OI Spec for details) | create_msgs/Mode |
odom |
Robot odometry according to wheel encoders | nav_msgs/Odometry |
wheeldrop |
At least one of the drive wheels has dropped | std_msgs/Empty |
/tf |
The transform from the odom frame to base_footprint . Only if the parameter publish_tf is true
|
tf2_msgs/TFMessage |
diagnostics |
Info about the battery charge, wheeldrop/cliff state, robot mode, and serial connection | diagnostic_msgs/DiagnosticArray |
Subscribers
Topic | Description | Type |
---|---|---|
cmd_vel |
Drives the robot’s wheels according to a forward and angular velocity | geometry_msgs/Twist |
debris_led |
Enable / disable the blue ‘debris’ LED | std_msgs/Bool |
spot_led |
Enable / disable the ‘spot’ LED | std_msgs/Bool |
dock_led |
Enable / disable the ‘dock’ LED | std_msgs/Bool |
check_led |
Enable / disable the ‘check robot` LED | std_msgs/Bool |
power_led |
Set the ‘power’ LED color and intensity. Accepts 1 or 2 bytes, the first represents the color between green (0) and red (255) and the second (optional) represents the intensity with brightest setting as default (255) | std_msgs/UInt8MultiArray |
set_ascii |
Sets the 4 digit LEDs. Accepts 1 to 4 bytes, each representing an ASCII character to be displayed from left to right | std_msgs/UInt8MultiArray |
dock |
Activates the demo docking behaviour. Robot enters Passive mode meaning the user loses control (See OI Spec) | std_msgs/Empty |
undock |
Switches robot to Full mode giving control back to the user | std_msgs/Empty |
define_song |
Define a song with up to 16 notes. Each note is described by a MIDI note number and a float32 duration in seconds. The longest duration is 255/64 seconds. You can define up to 4 songs (See OI Spec) | create_msgs/DefineSong |
play_song |
Play a predefined song | create_msgs/PlaySong |
side_brush_motor |
Set duty cycle for the side brush. Accepts -1.0 to 1.0 range | create_msg/MotorSetpoint |
main_brush_motor |
Set duty cycle for the main brush. Accepts -1.0 to 1.0 range | create_msg/MotorSetpoint |
vacuum_motor |
Set duty cycle for the vacuum. Accepts 0.0 to 1.0 range | create_msg/MotorSetpoint |
Commanding your Create
You can move the robot around by sending geometry_msgs/Twist messages to the topic cmd_vel
:
linear.x (+) Move forward (m/s)
(-) Move backward (m/s)
angular.z (+) Rotate counter-clockwise (rad/s)
(-) Rotate clockwise (rad/s)
Velocity limits
` -0.5 <= linear.x <= 0.5 and
-4.25 <= angular.z <= 4.25`
Teleoperation
create_bringup
comes with a launch file for teleoperating Create with a joystick.
$ roslaunch create_bringup joy_teleop.launch [joy_config:=xbox360]
There exists configuration files for the Xbox 360 wired controller and the Logitech F710 controller. You can adapt these files for your preferred joystick configuration.
Contributions
Contributing to the development and maintenance of create_robot is encouraged. Feel free to open issues or create pull requests on GitHub.
Contributors
-
Michael Browne
- Confirms driver works with Roomba 700 and 800 series.
-
Clyde McQueen
- Added support for sound (#37).
- Ben Wolsieffer
CONTRIBUTING
Repository Summary
Checkout URI | https://github.com/AutonomyLab/create_robot.git |
VCS Type | git |
VCS Version | foxy |
Last Updated | 2023-05-21 |
Dev Status | MAINTAINED |
CI status | No Continuous Integration |
Released | RELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (0)
Good First Issues (0) Pull Requests to Review (0) |
Packages
Name | Version |
---|---|
create_bringup | 3.0.0 |
create_description | 3.0.0 |
create_driver | 3.0.0 |
create_msgs | 3.0.0 |
create_robot | 3.0.0 |
README
create_robot
ROS driver for iRobot Create 1 and 2. This package wraps the C++ library libcreate, which uses iRobot’s Open Interface Specification.
- ROS wiki page: http://wiki.ros.org/create_robot
- Support: ROS Answers (tag: create_robot)
- Author: Jacob Perron (Autonomy Lab, Simon Fraser University)
Build Status
- ROS Rolling (branch:
rolling
) - ROS Iron (branch:
iron
) - ROS Humble (branch:
humble
) - ROS Foxy (branch:
foxy
) - ROS Noetic (branch:
noetic
)
Supported Robots
Model | Support |
---|---|
Create 1 | Yes |
Create 2 (firmware >= 3.2.6) | Yes |
Roomba Original Series | No |
Roomba 400 Series | Yes |
Roomba 500 Series | Yes * |
Roomba 600 Series | Yes * |
Roomba 700 Series | Yes + |
Roomba 800 Series | Yes + |
Roomba 900 Series | No * |
+ Verified by third-party. Please note Odometry Issue #28 * Not verified. Anyone who is able to verify that this driver works or not is encouraged to contact Jacob with their findings or open an issue.
Features
Feature | Status |
---|---|
Odometry | Available |
Safe mode | Planned #13 |
Clean demo | Planned #14 |
Dock demo | Available |
Drive wheels | N/A |
Drive (v,w) | Available |
Brush motors | Available |
LEDs | Available |
Digit LEDs | Available |
Sound | Available |
Wheeldrop | Available |
Bumpers | Available |
Cliff sensor | Available |
Dirt detect | N/A |
Omni IR sensor | Available |
Left IR sensor | N/A |
Right IR sensor | N/A |
Battery info | Available |
Light sensors | Available |
Diagnostics | |
Corrupt packets | Available |
Overcurrent info | N/A |
Install
Prerequisites
- Internet connection
- ROS 2
- Ubuntu packages:
python3-rosdep
,python3-colcon-common-extensions
$ sudo apt install python3-rosdep python3-colcon-common-extensions
Compiling
- Create a colcon workspace
$ cd ~
$ mkdir -p create_ws/src
$ cd create_ws
- Clone this repo
$ cd ~/create_ws/src
$ git clone https://github.com/autonomylab/create_robot.git
$ git clone https://github.com/AutonomyLab/libcreate.git
- Install dependencies
$ cd ~/create_ws
$ rosdep update
$ rosdep install --from-paths src -i
- Build
$ cd ~/create_ws
$ colcon build
USB Permissions
- In order to connect to Create over USB, ensure your user is in the dialout group
$ sudo usermod -a -G dialout $USER
- Logout and login for permission to take effect
Running the driver
Setup
- After compiling from source, don’t forget to source your workspace:
$ source ~/create_ws/install/setup.bash
- Connect computer to Create’s 7-pin serial port
- If using Create 1, ensure that nothing is connected to Create’s DB-25 port
- Launch one of the existing launch files or adapt them to create your own.
Launch files
For Create 2 (Roomba 600/700 series):
$ ros2 launch create_bringup create_2.launch
For Create 1 (Roomba 500 series):
$ ros2 launch create_bringup create_1.launch
For Roomba 400 series:
$ ros2 launch create_bringup roomba_400.launch
Launch file arguments
-
config - Absolute path to a configuration file (YAML). Default:
create_bringup/config/default.yaml
-
desc - Enable robot description (URDF/mesh). Default:
true
For example, if you would like to disable the robot description and provide a custom configuration file:
$ ros2 launch create_bringup create_2.launch config:=/abs/path/to/config.yaml desc:=false
Parameters
Name | Description | Default |
---|---|---|
dev |
Device path of robot | /dev/ttyUSB0 |
base_frame |
The robot’s base frame ID | base_footprint |
odom_frame |
The robot’s odometry frame ID | odom |
latch_cmd_duration |
If this many seconds passes without receiving a velocity command the robot stops | 0.2 |
loop_hz |
Frequency of internal update loop | 10.0 |
publish_tf |
Publish the transform from odom_frame to base_frame
|
true |
robot_model |
The type of robot being controlled (supported values: ROOMBA_400 , CREATE_1 and CREATE_2 ) |
CREATE_2 |
baud |
Serial baud rate | Inferred based on robot model, but is overwritten upon providing a value |
oi_mode_workaround |
Some Roomba models incorrectly report the current OI mode in their sensor streams. Setting this to true will cause libcreate to decrement the OI mode received in the sensor stream by 1
|
false |
Publishers
Topic | Description | Type |
---|---|---|
battery/capacity |
The estimated charge capacity of the robot’s battery (Ah) | std_msgs/msg/Float32 |
battery/charge |
The current charge of the robot’s battery (Ah) | std_msgs/msg/Float32 |
battery/charge_ratio |
Charge / capacity | std_msgs/msg/Float32 |
battery/charging_state |
The chargins state of the battery | create_msgs/msg/ChargingState |
battery/current |
Current flowing through the robot’s battery (A). Positive current implies charging | std_msgs/msg/Float32 |
battery/temperature |
The temperature of the robot’s battery (degrees Celsius) | std_msgs/msg/Int16 |
battery/voltage |
Voltage of the robot’s battery (V) | std_msgs/msg/Float32 |
bumper |
Bumper state message (including light sensors on bumpers) | create_msgs/msg/Bumper |
cliff |
Cliff state message | create_msgs/msg/Cliff |
clean_button |
‘clean’ button is pressed (‘play’ button for Create 1) | std_msgs/msg/Empty |
day_button |
‘day’ button is pressed | std_msgs/msg/Empty |
hour_button |
‘hour’ button is pressed | std_msgs/msg/Empty |
minute_button |
‘minute’ button is pressed | std_msgs/msg/Empty |
dock_button |
‘dock’ button is pressed (‘advance’ button for Create 1) | std_msgs/msg/Empty |
spot_button |
‘spot’ button is pressed | std_msgs/msg/Empty |
ir_omni |
The IR character currently being read by the omnidirectional receiver. Value 0 means no character is being received | std_msgs/msg/UInt16 |
joint_states |
The states (position, velocity) of the drive wheel joints | sensor_msgs/msg/JointState |
mode |
The current mode of the robot (See OI Spec for details) | create_msgs/msg/Mode |
odom |
Robot odometry according to wheel encoders | nav_msgs/msg/Odometry |
wheeldrop |
At least one of the drive wheels has dropped | std_msgs/msg/Empty |
/tf |
The transform from the odom frame to base_footprint . Only if the parameter publish_tf is true
|
tf2_msgs/msg/TFMessage |
diagnostics |
Info about the battery charge, wheeldrop/cliff state, robot mode, and serial connection | diagnostic_msgs/msg/DiagnosticArray |
Subscribers
Topic | Description | Type |
---|---|---|
cmd_vel |
Drives the robot’s wheels according to a forward and angular velocity | geometry_msgs/msg/Twist |
debris_led |
Enable / disable the blue ‘debris’ LED | std_msgs/msg/Bool |
spot_led |
Enable / disable the ‘spot’ LED | std_msgs/msg/Bool |
dock_led |
Enable / disable the ‘dock’ LED | std_msgs/msg/Bool |
check_led |
Enable / disable the ‘check robot` LED | std_msgs/msg/Bool |
power_led |
Set the ‘power’ LED color and intensity. Accepts 1 or 2 bytes, the first represents the color between green (0) and red (255) and the second (optional) represents the intensity with brightest setting as default (255) | std_msgs/msg/UInt8MultiArray |
set_ascii |
Sets the 4 digit LEDs. Accepts 1 to 4 bytes, each representing an ASCII character to be displayed from left to right | std_msgs/msg/UInt8MultiArray |
dock |
Activates the demo docking behaviour. Robot enters Passive mode meaning the user loses control (See OI Spec) | std_msgs/msg/Empty |
undock |
Switches robot to Full mode giving control back to the user | std_msgs/msg/Empty |
define_song |
Define a song with up to 16 notes. Each note is described by a MIDI note number and a float32 duration in seconds. The longest duration is 255/64 seconds. You can define up to 4 songs (See OI Spec) | create_msgs/msg/DefineSong |
play_song |
Play a predefined song | create_msgs/msg/PlaySong |
Commanding your Create
You can move the robot around by sending geometry_msgs/msg/Twist messages to the topic cmd_vel
:
linear.x (+) Move forward (m/s)
(-) Move backward (m/s)
angular.z (+) Rotate counter-clockwise (rad/s)
(-) Rotate clockwise (rad/s)
Velocity limits
` -0.5 <= linear.x <= 0.5 and
-4.25 <= angular.z <= 4.25`
Teleoperation
create_bringup
comes with a launch file for teleoperating Create with a joystick.
$ ros2 launch create_bringup joy_teleop.launch joy_config:=xbox360
There exists configuration files for the Xbox 360 wired controller and the Logitech F710 controller. You can adapt these files for your preferred joystick configuration.
Contributions
Contributing to the development and maintenance of create_autonomy is encouraged. Feel free to open issues or create pull requests on GitHub.
Contributors
-
Michael Browne
- Confirms driver works with Roomba 700 and 800 series.
-
Clyde McQueen
- Added support for sound (#37).
- Ben Wolsieffer
-
Pedro Grojsgold
- Ported to ROS 2 (commit).
-
Josh Gadeken
- Added parameter for libcreate’s OI Mode reporting workaround (#95)
CONTRIBUTING
Repository Summary
Checkout URI | https://github.com/AutonomyLab/create_robot.git |
VCS Type | git |
VCS Version | melodic |
Last Updated | 2023-05-21 |
Dev Status | MAINTAINED |
CI status | No Continuous Integration |
Released | RELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (0)
Good First Issues (0) Pull Requests to Review (0) |
Packages
Name | Version |
---|---|
create_bringup | 2.0.0 |
create_description | 2.0.0 |
create_driver | 2.0.0 |
create_msgs | 2.0.0 |
create_robot | 2.0.0 |
README
create_robot
ROS driver for iRobot Create 1 and 2. This package wraps the C++ library libcreate, which uses iRobot’s Open Interface Specification.
- ROS wiki page: http://wiki.ros.org/create_robot
- Support: ROS Answers (tag: create_robot)
- Author: Jacob Perron (Autonomy Lab, Simon Fraser University)
Build Status
- ROS Rolling (branch:
rolling
) - ROS Iron (branch:
iron
) - ROS Humble (branch:
humble
) - ROS Foxy (branch:
foxy
) - ROS Noetic (branch:
noetic
) - ROS Melodic (branch:
melodic
)
Supported Robots
Model | Support |
---|---|
Create 1 | Yes |
Create 2 (firmware >= 3.2.6) | Yes |
Roomba Original Series | No |
Roomba 400 Series | Yes |
Roomba 500 Series | Yes * |
Roomba 600 Series | Yes * |
Roomba 700 Series | Yes + |
Roomba 800 Series | Yes + |
Roomba 900 Series | No * |
+ Verified by third-party. Please note Odometry Issue #28 * Not verified. Anyone who is able to verify that this driver works or not is encouraged to contact Jacob with their findings or open an issue.
Features
Feature | Status |
---|---|
Odometry | Available |
Safe mode | Planned #13 |
Clean demo | Planned #14 |
Dock demo | Available |
Drive wheels | N/A |
Drive (v,w) | Available |
Brush motors | Available |
LEDs | Available |
Digit LEDs | Available |
Sound | Available |
Wheeldrop | Available |
Bumpers | Available |
Cliff sensor | Planned #22 |
Dirt detect | N/A |
Omni IR sensor | Available |
Left IR sensor | N/A |
Right IR sensor | N/A |
Battery info | Available |
Light sensors | Available |
Diagnostics | |
Corrupt packets | Available |
Overcurrent info | N/A |
Install
Prerequisites
- Internet connection
- ROS
- Ubuntu packages:
python3-rosdep
,python3-catkin-tools
$ sudo apt-get install python3-rosdep python3-catkin-tools
Compiling
- Create a catkin workspace
$ cd ~
$ mkdir -p create_ws/src
$ cd create_ws
$ catkin init
- Clone this repo
$ cd ~/create_ws/src
$ git clone https://github.com/autonomylab/create_robot.git --branch noetic
- Install dependencies
$ cd ~/create_ws
$ rosdep update
$ rosdep install --from-paths src -i
- Install dependencies
$ cd ~/create_ws
$ rosdep update
$ rosdep install --from-paths src -i
- Build
$ cd ~/create_ws
$ catkin build
USB Permissions
- In order to connect to Create over USB, ensure your user is in the dialout group
$ sudo usermod -a -G dialout $USER
- Logout and login for permission to take effect
Running the driver
Setup
- After compiling from source, don’t forget to source your workspace:
$ source ~/create_ws/devel/setup.bash
- Connect computer to Create’s 7-pin serial port
- If using Create 1, ensure that nothing is connected to Create’s DB-25 port
- Launch one of the existing launch files or adapt them to create your own.
Launch files
For Create 2 (Roomba 600/700 series):
$ roslaunch create_bringup create_2.launch
For Create 1 (Roomba 500 series):
$ roslaunch create_bringup create_1.launch
For Roomba 400 series:
$ roslaunch create_bringup roomba_400.launch
Launch file arguments
-
config - Absolute path to a configuration file (YAML). Default:
create_bringup/config/default.yaml
-
desc - Enable robot description (URDF/mesh). Default:
true
For example, if you would like to disable the robot description and provide a custom configuration file:
$ roslaunch create_bringup create_2.launch config:=/abs/path/to/config.yaml desc:=false
Parameters
Name | Description | Default |
---|---|---|
dev |
Device path of robot | /dev/ttyUSB0 |
base_frame |
The robot’s base frame ID | base_footprint |
odom_frame |
The robot’s odometry frame ID | odom |
latch_cmd_duration |
If this many seconds passes without receiving a velocity command the robot stops | 0.2 |
loop_hz |
Frequency of internal update loop | 10.0 |
publish_tf |
Publish the transform from odom_frame to base_frame
|
true |
robot_model |
The type of robot being controlled (supported values: ROOMBA_400 , CREATE_1 and CREATE_2 ) |
CREATE_2 |
baud |
Serial baud rate | Inferred based on robot model, but is overwritten upon providing a value |
Publishers
Topic | Description | Type |
---|---|---|
battery/capacity |
The estimated charge capacity of the robot’s battery (Ah) | std_msgs/Float32 |
battery/charge |
The current charge of the robot’s battery (Ah) | std_msgs/Float32 |
battery/charge_ratio |
Charge / capacity | std_msgs/Float32 |
battery/charging_state |
The chargins state of the battery | create_msgs/ChargingState |
battery/current |
Current flowing through the robot’s battery (A). Positive current implies charging | std_msgs/Float32 |
battery/temperature |
The temperature of the robot’s battery (degrees Celsius) | std_msgs/Int16 |
battery/voltage |
Voltage of the robot’s battery (V) | std_msgs/Float32 |
bumper |
Bumper state message (including light sensors on bumpers) | create_msgs/Bumper |
clean_button |
‘clean’ button is pressed (‘play’ button for Create 1) | std_msgs/Empty |
day_button |
‘day’ button is pressed | std_msgs/Empty |
hour_button |
‘hour’ button is pressed | std_msgs/Empty |
minute_button |
‘minute’ button is pressed | std_msgs/Empty |
dock_button |
‘dock’ button is pressed (‘advance’ button for Create 1) | std_msgs/Empty |
spot_button |
‘spot’ button is pressed | std_msgs/Empty |
ir_omni |
The IR character currently being read by the omnidirectional receiver. Value 0 means no character is being received | std_msgs/UInt16 |
joint_states |
The states (position, velocity) of the drive wheel joints | sensor_msgs/JointState |
mode |
The current mode of the robot (See OI Spec for details) | create_msgs/Mode |
odom |
Robot odometry according to wheel encoders | nav_msgs/Odometry |
wheeldrop |
At least one of the drive wheels has dropped | std_msgs/Empty |
/tf |
The transform from the odom frame to base_footprint . Only if the parameter publish_tf is true
|
tf2_msgs/TFMessage |
diagnostics |
Info about the battery charge, wheeldrop/cliff state, robot mode, and serial connection | diagnostic_msgs/DiagnosticArray |
Subscribers
Topic | Description | Type |
---|---|---|
cmd_vel |
Drives the robot’s wheels according to a forward and angular velocity | geometry_msgs/Twist |
debris_led |
Enable / disable the blue ‘debris’ LED | std_msgs/Bool |
spot_led |
Enable / disable the ‘spot’ LED | std_msgs/Bool |
dock_led |
Enable / disable the ‘dock’ LED | std_msgs/Bool |
check_led |
Enable / disable the ‘check robot` LED | std_msgs/Bool |
power_led |
Set the ‘power’ LED color and intensity. Accepts 1 or 2 bytes, the first represents the color between green (0) and red (255) and the second (optional) represents the intensity with brightest setting as default (255) | std_msgs/UInt8MultiArray |
set_ascii |
Sets the 4 digit LEDs. Accepts 1 to 4 bytes, each representing an ASCII character to be displayed from left to right | std_msgs/UInt8MultiArray |
dock |
Activates the demo docking behaviour. Robot enters Passive mode meaning the user loses control (See OI Spec) | std_msgs/Empty |
undock |
Switches robot to Full mode giving control back to the user | std_msgs/Empty |
define_song |
Define a song with up to 16 notes. Each note is described by a MIDI note number and a float32 duration in seconds. The longest duration is 255/64 seconds. You can define up to 4 songs (See OI Spec) | create_msgs/DefineSong |
play_song |
Play a predefined song | create_msgs/PlaySong |
side_brush_motor |
Set duty cycle for the side brush. Accepts -1.0 to 1.0 range | create_msg/MotorSetpoint |
main_brush_motor |
Set duty cycle for the main brush. Accepts -1.0 to 1.0 range | create_msg/MotorSetpoint |
vacuum_motor |
Set duty cycle for the vacuum. Accepts 0.0 to 1.0 range | create_msg/MotorSetpoint |
Commanding your Create
You can move the robot around by sending geometry_msgs/Twist messages to the topic cmd_vel
:
linear.x (+) Move forward (m/s)
(-) Move backward (m/s)
angular.z (+) Rotate counter-clockwise (rad/s)
(-) Rotate clockwise (rad/s)
Velocity limits
` -0.5 <= linear.x <= 0.5 and
-4.25 <= angular.z <= 4.25`
Teleoperation
create_bringup
comes with a launch file for teleoperating Create with a joystick.
$ roslaunch create_bringup joy_teleop.launch [joy_config:=xbox360]
There exists configuration files for the Xbox 360 wired controller and the Logitech F710 controller. You can adapt these files for your preferred joystick configuration.
Contributions
Contributing to the development and maintenance of create_robot is encouraged. Feel free to open issues or create pull requests on GitHub.
Contributors
-
Michael Browne
- Confirms driver works with Roomba 700 and 800 series.
-
Clyde McQueen
- Added support for sound (#37).
- Ben Wolsieffer