Class LynxRobotDriver
Defined in File lynx_robot_driver.hpp
Inheritance Relationships
Base Type
public husarion_ugv_hardware_interfaces::RoboteqRobotDriver(Class RoboteqRobotDriver)
Class Documentation
-
class LynxRobotDriver : public husarion_ugv_hardware_interfaces::RoboteqRobotDriver
This class implements RoboteqRobotDriver for Lynx robot. It defines one Roboteq controller with two motors controlling left and right wheels.
Public Functions
-
inline LynxRobotDriver(const CANopenSettings &canopen_settings, const DrivetrainSettings &drivetrain_settings, const std::chrono::milliseconds activate_wait_time = std::chrono::milliseconds(1000))
-
~LynxRobotDriver() = default
-
virtual void SendSpeedCommands(const std::vector<float> &speeds) override
Write speed commands to motors.
- Parameters:
speeds – vector of motor speeds in rad/s. The order is: left, right
- Throws:
std::runtime_error – if invalid vector size, send command fails or CAN error is detected
-
inline virtual void AttemptErrorFlagReset() override
Attempt to clear driver error flags by sending 0 velocity commands to motors. If Roboteq driver faults still exist, the error flag will remain active.
Protected Functions
-
virtual void DefineDrivers() override
This method defines driver objects and adds motor drivers for them. It is virtual to allow mocking drivers in tests.
-
inline LynxRobotDriver(const CANopenSettings &canopen_settings, const DrivetrainSettings &drivetrain_settings, const std::chrono::milliseconds activate_wait_time = std::chrono::milliseconds(1000))