This abstract template needs to be specialized in a ROS2 subscription, for a specific ROS2 message/sensor type. More...
Public Member Functions | |
GenericSensor_nwc_ros2 () | |
virtual | ~GenericSensor_nwc_ros2 () |
bool | open (yarp::os::Searchable ¶ms) override |
Open the DeviceDriver. | |
bool | close () override |
Close the DeviceDriver. | |
![]() | |
DeviceDriver () | |
DeviceDriver (const DeviceDriver &other)=delete | |
DeviceDriver (DeviceDriver &&other) noexcept=delete | |
DeviceDriver & | operator= (const DeviceDriver &other)=delete |
DeviceDriver & | operator= (DeviceDriver &&other) noexcept=delete |
virtual | ~DeviceDriver () |
virtual std::string | id () const |
Return the id assigned to the PolyDriver. | |
virtual void | setId (const std::string &id) |
Set the id for this device. | |
template<class T > | |
bool | view (T *&x) |
Get an interface to the device driver. | |
virtual DeviceDriver * | getImplementation () |
Some drivers are bureaucrats, pointing at others. | |
Protected Member Functions | |
virtual void | subscription_callback (const std::shared_ptr< ROS_MSG > msg)=0 |
![]() | |
GenericSensor_nwc_ros2_ParamsParser () | |
~GenericSensor_nwc_ros2_ParamsParser () override=default | |
bool | parseParams (const yarp::os::Searchable &config) override |
Parse the DeviceDriver parameters. | |
std::string | getDeviceClassName () const override |
Get the name of the DeviceDriver class. | |
std::string | getDeviceName () const override |
Get the name of the device (i.e. | |
std::string | getDocumentationOfDeviceParams () const override |
Get the documentation of the DeviceDriver's parameters. | |
std::vector< std::string > | getListOfParams () const override |
Return a list of all params used by the device. | |
![]() | |
virtual | ~IDeviceDriverParams () |
Protected Attributes | |
double | m_periodInS {0.01} |
double | m_timestamp |
std::string | m_framename |
Ros2Spinner * | m_spinner {nullptr} |
const size_t | m_sens_index = 0 |
std::mutex | m_dataMutex |
yarp::dev::MAS_status | m_internalStatus |
rclcpp::Node::SharedPtr | m_node |
rclcpp::Subscription< ROS_MSG >::SharedPtr | m_subscription |
![]() | |
const std::string | m_device_classname = {"GenericSensor_nwc_ros2"} |
const std::string | m_device_name = {"genericSensor_nwc_ros2"} |
bool | m_parser_is_strict = false |
const parser_version_type | m_parser_version = {} |
const std::string | m_node_name_defaultValue = {""} |
const std::string | m_topic_name_defaultValue = {""} |
const std::string | m_sensor_name_defaultValue = {""} |
std::string | m_node_name = {} |
std::string | m_topic_name = {} |
std::string | m_sensor_name = {} |
This abstract template needs to be specialized in a ROS2 subscription, for a specific ROS2 message/sensor type.
YARP device name |
---|
genericSensor_nwc_ros2 |
The parameters accepted by this device are shown in class: GenericSensor_nwc_ros2_ParamsParser
Definition at line 42 of file GenericSensor_nwc_ros2.h.
GenericSensor_nwc_ros2< ROS_MSG >::GenericSensor_nwc_ros2 | ( | ) |
Definition at line 70 of file GenericSensor_nwc_ros2.h.
|
virtualdefault |
|
overridevirtual |
Close the DeviceDriver.
Reimplemented from yarp::dev::DeviceDriver.
Definition at line 121 of file GenericSensor_nwc_ros2.h.
|
overridevirtual |
Open the DeviceDriver.
config | is a list of parameters for the device. Which parameters are effective for your device can vary. See device invocation examples. If there is no example for your device, you can run the "yarpdev" program with the verbose flag set to probe what parameters the device is checking. If that fails too, you'll need to read the source code (please nag one of the yarp developers to add documentation for your device). |
Reimplemented from yarp::dev::DeviceDriver.
Definition at line 81 of file GenericSensor_nwc_ros2.h.
|
protectedpure virtual |
Implemented in Imu_nwc_ros2.
|
mutableprotected |
Definition at line 52 of file GenericSensor_nwc_ros2.h.
|
protected |
Definition at line 49 of file GenericSensor_nwc_ros2.h.
|
protected |
Definition at line 53 of file GenericSensor_nwc_ros2.h.
|
protected |
Definition at line 54 of file GenericSensor_nwc_ros2.h.
|
protected |
Definition at line 47 of file GenericSensor_nwc_ros2.h.
|
protected |
Definition at line 51 of file GenericSensor_nwc_ros2.h.
|
protected |
Definition at line 50 of file GenericSensor_nwc_ros2.h.
|
protected |
Definition at line 55 of file GenericSensor_nwc_ros2.h.
|
protected |
Definition at line 48 of file GenericSensor_nwc_ros2.h.