PX4 ROS 2 Interface Library
Library to interface with PX4 from a companion computer using ROS 2
|
Setpoint type for rover throttle and steering control. More...
#include <px4_ros2/control/setpoint_types/experimental/rover/throttle_steering.hpp>
Public Member Functions | |
RoverThrottleSteeringSetpointType (Context &context) | |
Configuration | getConfiguration () override |
float | desiredUpdateRateHz () override |
void | update (float throttle_body_x, float normalized_steering_setpoint, std::optional< float > throttle_body_y={}) |
Send a rover throttle setpoint and a rover steering setpoint to the flight controller. More... | |
![]() | |
SetpointBase (Context &context) | |
std::shared_ptr< SetpointBase > | getSharedPtr () |
void | setShouldActivateCallback (const ShouldActivateCB &should_activate_cb) |
void | setActive (bool active) |
Additional Inherited Members | |
![]() | |
using | ShouldActivateCB = std::function< void()> |
![]() | |
void | onUpdate () |
Setpoint type for rover throttle and steering control.
void px4_ros2::RoverThrottleSteeringSetpointType::update | ( | float | throttle_body_x, |
float | normalized_steering_setpoint, | ||
std::optional< float > | throttle_body_y = {} |
||
) |
Send a rover throttle setpoint and a rover steering setpoint to the flight controller.
throttle_body_x | [-] Throttle setpoint along body X axis. Takes values in [-1 (Backwards), 1 (Forwards)]. |
normalized_steering_setpoint | [-] Ackermann: Normalized steering angle, Differential/Mecanum: Normalized speed difference between the left and right wheels. Takes values in [-1 (Left), 1 (Right)]. |
throttle_body_y | [-] Mecanum only: Throttle setpoint along body Y axis (Only relevant for mecanum rovers). Takes values in [-1 (Left), 1 (Right)]. |