RTC Toolkit  1.0.0
Telemetry Subscriber

Telemetry Subscriber must be instantiated using a user defined topic type that will be used as element type in the IPCQ shared memory queue and thus used by both the telSub writer and all readers.

To simplify component realization telSub provides a templated entrypoint rtctk::telSub::Main that is meant to be delegated from RtcComponentMain.

Below is an example component instantiation using the IPCQ type UserTopicType=rtctk::exampleTopic::ScaoLoopTopic with an empty placeholder blender (see also Application). Although a lambda is used for the blender implementation it can also be implemented as e.g. a free function.

using UserTopicType = rtctk::exampleTopic::ScaoLoopTopic;
auto blender = [](const rtctk::telSub::DataSamplesView& dds_samples,
UserTopicType& shm_sample) noexcept -> std::error_code {
// shm_sample should be populated from dds_samples
// ...
return {}; // Success
};
rtctk::telSub::Main<UserTopicType>(args, std::move(blender));
}
RtcComponentMain
void RtcComponentMain(rtctk::componentFramework::Args const &args)
Main entry point for user code, method must be implemented by component developers.
Definition: main.cpp:22
rtctk::componentFramework::detail::Args
Definition: rtcComponent.hpp:38
main.hpp
Entry-point for Telemetry Subscriber.
rtctk::exampleTopic::ScaoLoopTopic
Definition: topics.hpp:27
rtctk::telSub::DataSamplesView
A set of correlated agnostic non-owning data samples references.
Definition: dataSampleView.hpp:46