Project Chrono: chrono::ros::ChROSViperDCMotorControlHandler Class Reference

Public Member Functions | Protected Member Functions | List of all members
chrono::ros::ChROSViperDCMotorControlHandler Class Reference
ROS module » ROS Handlers » ROS Robot Handlers

## Description

This handler is responsible for interfacing a ViperDCMotorControl driver to ROS.

Will instantiate a subscriber to chrono_ros_interfaces::msg::ViperDCMotorControl.

`#include <ChROSViperDCMotorControlHandler.h>`

Inheritance diagram for chrono::ros::ChROSViperDCMotorControlHandler:
[legend]
Collaboration diagram for chrono::ros::ChROSViperDCMotorControlHandler:
[legend]

## Public Member Functions
| ChROSViperDCMotorControlHandler (double update_rate, std::shared_ptr< chrono::viper::ViperDCMotorControl > driver, const std::string &topic_name)
| Constructor. Takes a ViperDCMotorControl driver.
virtual bool | Initialize (std::shared_ptr< ChROSInterface > interface) override
| Initializes the handler.
Public Member Functions inherited from chrono::ros::ChROSHandler
virtual | ~ChROSHandler ()=default
| Destructor for the ChROSHandler.
virtual void | Update (double time, double step) final
| Updates the internal clock and checks if a tick should occur.
const double | GetUpdateRate () const
| Get the period which this handler operates at.
const uint64_t | GetTickCount () const
| Get the number of times Tick() has been called.

## Protected Member Functions
virtual void | Tick (double time) override
| Updates the driver with stored inputs data from Callback.
Protected Member Functions inherited from chrono::ros::ChROSHandler
| ChROSHandler (double update_rate)
| Constructor for the ChROSHandler.

## Member Function Documentation

## ◆ Initialize()

bool chrono::ros::ChROSViperDCMotorControlHandler::Initialize | ( | std::shared_ptr< ChROSInterface > | interface | ) |
| overridevirtual

Initializes the handler.

Implements chrono::ros::ChROSHandler.

## ◆ Tick()

void chrono::ros::ChROSViperDCMotorControlHandler::Tick | ( | double | time | ) |
| overrideprotectedvirtual

Updates the driver with stored inputs data from Callback.

Implements chrono::ros::ChROSHandler.

The documentation for this class was generated from the following files:

- D:/W/B/src/chrono-9.0.1/src/chrono_ros/handlers/robot/viper/ChROSViperDCMotorControlHandler.h
- D:/W/B/src/chrono-9.0.1/src/chrono_ros/handlers/robot/viper/ChROSViperDCMotorControlHandler.cpp