How To Use the EPMC With ROS2
Learn how to test and integrate the Easy IMU (EIMU) in your ROS2 project
Last updated
Learn how to test and integrate the Easy IMU (EIMU) in your ROS2 project
Last updated
Firstly, ensure you have your Geared DC motors connected to the EPMC Module and the motor PID gains already set up. If not, follow the instructions here []
Also, before you start, it is worth knowing that you can use it with a PC, Raspberry Pi, or any microcomputer running Ubuntu OS and ROS2. You can also use docker (if you can).
You should also have some experience with ROS2 as a beginner or intermediate user. (e.g. Installing ROS2, setting up ros workspace, building packages with colcon, rosdep, ros topics, rviz, ros transforms, e.t.c)
Basically, after cloning, installing necessary dependencies, compiling, and installing both packages using colcon build --symlink-install
, you can quickly follow the steps below to test the EPMC.
You need to first connect the EPMC Module to your PC (or microcomputer)
Check the USB port the EPMC Module is connected to and give the port necessary permissions.
Go to the epmc_diff_drive_ros2_control.xacro
file found in the easy_demo_bot/easy_demo_bot_description/urdf/controller/ folder
change the port
param file to the USB port found in the second step above
<param name="port"> {discovered port value} </param>
Then ensure the motorA_wheel_name
and the motorB_wheel_name
params properly indicates which port you connected your left and right motor wheel.
Change the command interface velocity min and max parameter, to that of you Motor (i.e *W_MAX value during setup)
open a new terminal (and source your workspace) and launch the easy_demo_bot_base
ros2 launch easy_demo_bot_base robot.launch.py
open another terminal (and source your workspace) and launch the easy_demo_bot_rviz view file
ros2 launch easy_demo_bot_rviz robot.launch.py
You’ll need to get and build two packages in your ros workspace to use [or test] the EPMC. The first package to build and install is the EPMC hardware plugin package – – and the other is a test robot package for testing/implementing the installed EPMC hardware plugin – .
You can drive using the ros teleop package or the packge
Finally, please chekout and go through the package to see proper sample of how combine the EIMU with the EPMC and ekf sensor-fusion in a mobile robot.