PX4 Firmware
PX4 Autopilot Software http://px4.io
uORBCommunicator::IChannel Class Referenceabstract

Interface to enable remote subscriptions. More...

#include <uORBCommunicator.hpp>

Inheritance diagram for uORBCommunicator::IChannel:
Collaboration diagram for uORBCommunicator::IChannel:

Public Member Functions

virtual int16_t topic_advertised (const char *messageName)=0
 Interface to notify the remote entity of a topic being advertised. More...
 
virtual int16_t add_subscription (const char *messageName, int32_t msgRateInHz)=0
 Interface to notify the remote entity of a topic being unadvertised and is no longer publishing messages. More...
 
virtual int16_t remove_subscription (const char *messageName)=0
 Interface to notify the remote entity of removal of a subscription. More...
 
virtual int16_t register_handler (uORBCommunicator::IChannelRxHandler *handler)=0
 Register Message Handler. More...
 
virtual int16_t send_message (const char *messageName, int32_t length, uint8_t *data)=0
 Sends the data message over the communication link. More...
 

Detailed Description

Interface to enable remote subscriptions.

The implementor of this interface shall manage the communication channel. It can be fastRPC or tcp or ip.

Definition at line 51 of file uORBCommunicator.hpp.

Member Function Documentation

◆ add_subscription()

virtual int16_t uORBCommunicator::IChannel::add_subscription ( const char *  messageName,
int32_t  msgRateInHz 
)
pure virtual

Interface to notify the remote entity of a topic being unadvertised and is no longer publishing messages.

Parameters
messageNameThis represents the uORB message name(aka topic); This message name should be globally unique.
Returns
0 = success; This means the messages is successfully sent to the receiver Note: This does not mean that the receiver as received it. otherwise = failure. Interface to notify the remote entity of interest of a subscription for a message.
Parameters
messageNameThis represents the uORB message name; This message name should be globally unique.
msgRateThe max rate at which the subscriber can accept the messages.
Returns
0 = success; This means the messages is successfully sent to the receiver Note: This does not mean that the receiver as received it. otherwise = failure.

Implemented in uORB::KraitFastRpcChannel, and uORB::FastRpcChannel.

Referenced by uORB::DeviceNode::add_internal_subscriber().

Here is the caller graph for this function:

◆ register_handler()

virtual int16_t uORBCommunicator::IChannel::register_handler ( uORBCommunicator::IChannelRxHandler handler)
pure virtual

Register Message Handler.

This is internal for the IChannel implementer*

Implemented in uORB::KraitFastRpcChannel, and uORB::FastRpcChannel.

Referenced by uORB::Manager::node_open().

Here is the caller graph for this function:

◆ remove_subscription()

virtual int16_t uORBCommunicator::IChannel::remove_subscription ( const char *  messageName)
pure virtual

Interface to notify the remote entity of removal of a subscription.

Parameters
messageNameThis represents the uORB message name; This message name should be globally unique.
Returns
0 = success; This means the messages is successfully sent to the receiver Note: This does not necessarily mean that the receiver as received it. otherwise = failure.

Implemented in uORB::KraitFastRpcChannel, and uORB::FastRpcChannel.

Referenced by uORB::DeviceNode::remove_internal_subscriber().

Here is the caller graph for this function:

◆ send_message()

virtual int16_t uORBCommunicator::IChannel::send_message ( const char *  messageName,
int32_t  length,
uint8_t *  data 
)
pure virtual

Sends the data message over the communication link.

Parameters
messageNameThis represents the uORB message name; This message name should be globally unique.
lengthThe length of the data buffer to be sent.
dataThe actual data to be sent.
Returns
0 = success; This means the messages is successfully sent to the receiver Note: This does not mean that the receiver as received it. otherwise = failure.

Implemented in uORB::KraitFastRpcChannel, and uORB::FastRpcChannel.

Referenced by uORB::DeviceNode::publish(), and uORB::DeviceNode::remove_internal_subscriber().

Here is the caller graph for this function:

◆ topic_advertised()

virtual int16_t uORBCommunicator::IChannel::topic_advertised ( const char *  messageName)
pure virtual

Interface to notify the remote entity of a topic being advertised.

Parameters
messageNameThis represents the uORB message name(aka topic); This message name should be globally unique.
Returns
0 = success; This means the messages is successfully sent to the receiver Note: This does not mean that the receiver as received it. otherwise = failure.

Implemented in uORB::KraitFastRpcChannel, and uORB::FastRpcChannel.

Referenced by uORB::DeviceNode::unadvertise().

Here is the caller graph for this function:

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