The interface for retrieving diagnostic information from an Avular robot. More...
#include <creos/diagnostics_interface.hpp>
Public Member Functions | |
virtual SubscriptionId | subscribeToState (const std::function< void(const creos_messages::State &)> &callback)=0 |
Subscribe to state information of the robot. | |
virtual creos_messages::State | getState (int timeout_ms=1500)=0 |
Get the state of the robot. | |
virtual SubscriptionId | subscribeToUserEvents (const std::function< void(const creos_messages::UserEvent &)> &callback)=0 |
Subscribe to user events generated by the robot. | |
Static Public Attributes | |
static constexpr char | name [] = "diagnostics" |
static constexpr unsigned | version = 1 |
The interface for retrieving diagnostic information from an Avular robot.
|
pure virtualOriginVertex |
Get the state of the robot.
Get the latest information about the state of different components of the robot.
timeout_ms | The timeout in milliseconds for the request. |
creos::TimeoutError | If the system info is not received within the timeout. |
creos::UnsupportedError | If the robot does not provide this data, or the client and agent are incompatible. |
creos::Exception | if any other error occurred while getting the data. |
|
pure virtualOriginVertex |
Subscribe to state information of the robot.
Subscribe to updates about the state of different components of the robot.
callback | The callback function that will be called when new data is available. |
creos::UnsupportedError | If the robot does not provide this data, or the client and agent are incompatible. |
creos::SubscriptionError | if the subscription failed. |
|
pure virtualOriginVertex |
Subscribe to user events generated by the robot.
Subscribe to messages meant for a user, generated by the robot's internal systems.
callback | The callback function that will be called when new data is available. |
creos::UnsupportedError | If the robot does not provide this data, or the client and agent are incompatible. |
creos::SubscriptionError | if the subscription failed. |