Signed-off-by: Beniamino Pozzan <beniamino.pozzan@gmail.com> Co-authored-by: Hamish Willee <hamishwillee@gmail.com>
2.3 KiB
PX4 ROS 2 Interface Library
:::warning Experimental At the time of writing, parts of the PX4 ROS 2 Interface Library are experimental, and hence subject to change. :::
:::info
When using rmw_zenoh, the PX4 ROS 2 Interface Library requires ROS 2 Jazzy or later, and is not compatible with ROS 2 Humble or earlier.
:::
The PX4 ROS 2 Interface Library is a C++ library (with Python bindings) that simplifies controlling and interacting with PX4 from ROS 2.
The library provides three high-level interfaces for developers:
- The Control Interface allows developers to create and dynamically register modes written using ROS 2. It provides classes for sending different types of setpoints, ranging from high-level navigation tasks all the way down to direct actuator controls.
- The Navigation Interface enables sending vehicle position estimates to PX4 from ROS 2 applications, such as a VIO system.
- Waypoint Missions allows waypoint missions to run entirely in ROS 2.
Installation in a ROS 2 Workspace
To get started using the library within an existing ROS 2 workspace:
-
Make sure you have a working ROS 2 setup, with
px4_msgsin the ROS 2 workspace. -
Clone the repository into the workspace:
cd $ros_workspace/src git clone --recursive https://github.com/Auterion/px4-ros2-interface-lib::: info To ensure compatibility, use the latest main branches for PX4, px4_msgs and the library. See also here. :::
-
Build the workspace:
cd .. colcon build source install/setup.bash
CI: Integration Tests
When opening a pull request to PX4, CI runs the library integration tests. These test that mode registration, failsafes, and mode replacement, work as expected.
For more information see PX4 ROS 2 Interface Library Integration Testing.