The Interbotix X-Series Driver provides low-level interfaces to easily control the DYNAMIXEL servos on any Interbotix X-Series Robot.
This package can be used as a standalone C++ library, or as a ROS 2 Ament-style package.
As long as your OS has access to nix, building from source is as simple as
nix develop
mkdir build
cd build
cmake ..
makeThis package is known to build on Ubuntu 22.04 and 24.04.
No other configuration or environments has been tested. Use at your own risk.
It should work on other Ubuntu versions as well, so long as cmake is >= 3.23 (look at build.sh for details).
If building for the first time, simply run the following
git clone --recursive [email protected]:HorizonRoboticsInternal/interbotix_xs_driver.git -b main
cd interbotix_xs_driver
sudo ./build.sh --freshThis should install all dependencies and build wx_armor.
If simply trying to rebuild wx_armor, users can run sudo ./build.sh without --fresh.
Note that current build requires cmake >= 3.23, which will automatically be handled for Ubuntu 22.04 users. For Ubuntu 24.04, cmake should already satisfy this requirement.
Users can find instructions for installing on Jetson devices here.
Building the packages requires the following dependencies:
mkdir -p colcon_ws/src
cd colcon_ws/src
git clone https://github.com/Interbotix/interbotix_xs_driver.git
git clone https://github.com/Interbotix/dynamixel-workbench.git -b ros2
cd ..
rosdep install --from-paths src --ignore-src -r -y
colcon buildThe X-Series Driver is compiled as a library and can be used in any C++ project by simply including its headers and linking against it.
#include "interbotix_xs_driver/xs_logging.hpp" // Logging macros and utils
#include "interbotix_xs_driver/xs_common.hpp" // Common variables and types
#include "interbotix_xs_driver/xs_driver.hpp" // The InterbotixDriverXS class...
find_package(interbotix_xs_driver REQUIRED)
...
add_executable(your_executable)
ament_target_dependencies(your_executable interbotix_xs_driver ...)
...Then create an InterbotixDriverXS object, providing the following in the order stated:
- Absolute filepath to the motor configs file
- Absolute filepath to the mode configs file
- A boolean indicating whether the Driver should write to the EEPROM on startup
- A string indicating the driver's logging level containing one of the following: "DEBUG", "INFO", "WARN", "ERROR", "FATAL"
This initialization would look something like below:
std::unique_ptr<InterbotixDriverXS> xs_driver = std::make_unique<InterbotixDriverXS>(
filepath_motor_configs,
filepath_mode_configs,
write_eeprom_on_startup,
logging_level);See the package's source code for more details.