|
sas
Modularised monitoring, logging, and control of robots.
|
ROS integration helper for a RobotDriver implementation. More...
#include <sas_robot_driver_ros.hpp>
Public Member Functions | |
| RobotDriverROS (const RobotDriverROS &)=delete | |
| RobotDriverROS (std::shared_ptr< Node > &node, const std::shared_ptr< RobotDriver > &robot_driver, const RobotDriverROSConfiguration &configuration, const std::shared_ptr< ShutdownSignaler > &shutdown_signaler_) | |
| Construct a new RobotDriverROS object. | |
| RobotDriverROS (std::shared_ptr< Node > &node, const std::shared_ptr< RobotDriver > &robot_driver, const RobotDriverROSConfiguration &configuration, std::atomic_bool *kill_this_node) | |
| ~RobotDriverROS () | |
| Destructor; stops the control loop and performs cleanup. | |
| int | control_loop () |
| Run the control loop. | |
ROS integration helper for a RobotDriver implementation.
RobotDriverROS manages the ROS node, integrates a RobotDriver instance with ROS topics/services and runs the control loop. It also manages watchdog handling and shutdown signaling between ROS and the RobotDriver.
| sas::RobotDriverROS::RobotDriverROS | ( | std::shared_ptr< Node > & | node, |
| const std::shared_ptr< RobotDriver > & | robot_driver, | ||
| const RobotDriverROSConfiguration & | configuration, | ||
| const std::shared_ptr< ShutdownSignaler > & | shutdown_signaler_ | ||
| ) |
Construct a new RobotDriverROS object.
| node | Shared pointer to the rclcpp::Node used for ROS communication. |
| robot_driver | Shared pointer to the RobotDriver implementation to be wrapped. |
| configuration | Configuration parameters for ROS integration and control loop. |
| shutdown_signaler | Shared pointer used to signal shutdown between components. |
| int sas::RobotDriverROS::control_loop | ( | ) |
Run the control loop.
This method contains the main control loop and will typically run until a shutdown condition is met. Returns an integer status code on exit.