$darkmode
vtd::RdbCodec Class Referenceabstract

#include <rdb_codec.hpp>

Inheritance diagram for vtd::RdbCodec:

Public Member Functions

 RdbCodec (std::unique_ptr< RdbTransceiver > &&rdb_transceiver)
 
 RdbCodec (RdbTransceiver *rdb_transceiver)
 
virtual const std::string & get_name () const =0
 
virtual uint64_t frame_number () const
 
virtual void step (uint64_t frame_number, bool &restart, cloe::Duration &sim_time)
 
virtual void process (RDB_MSG_t *msg, bool &restart, cloe::Duration &sim_time)
 
virtual void process (RDB_MSG_ENTRY_HDR_t *entry)
 
virtual void process (RDB_START_OF_FRAME_t *)
 
virtual void process (RDB_END_OF_FRAME_t *)
 
virtual void process (RDB_COORD_SYSTEM_t *)
 
virtual void process (RDB_COORD_t *)
 
virtual void process (RDB_ROAD_POS_t *)
 
virtual void process (RDB_LANE_INFO_t *)
 
virtual void process (RDB_ROADMARK_t *)
 
virtual void process (RDB_OBJECT_CFG_t *)
 
virtual void process (RDB_OBJECT_STATE_t *, bool)
 
virtual void process (RDB_VEHICLE_SYSTEMS_t *)
 
virtual void process (RDB_VEHICLE_SETUP_t *)
 
virtual void process (RDB_ENGINE_t *, bool)
 
virtual void process (RDB_DRIVETRAIN_t *, bool)
 
virtual void process (RDB_WHEEL_t *, bool)
 
virtual void process (RDB_PED_ANIMATION_t *)
 
virtual void process (RDB_SENSOR_STATE_t *)
 
virtual void process (RDB_SENSOR_OBJECT_t *)
 
virtual void process (RDB_CAMERA_t *)
 
virtual void process (RDB_CONTACT_POINT_t *)
 
virtual void process (RDB_TRAFFIC_SIGN_t *)
 
virtual void process (RDB_ROAD_STATE_t *)
 
virtual void process (RDB_IMAGE_t *)
 
virtual void process (RDB_LIGHT_SOURCE_t *, bool)
 
virtual void process (RDB_ENVIRONMENT_t *)
 
virtual void process (RDB_TRIGGER_t *)
 
virtual void process (RDB_DRIVER_CTRL_t *)
 
virtual void process (RDB_TRAFFIC_LIGHT_t *, bool)
 
virtual void process (RDB_SYNC_t *)
 
virtual void process (RDB_DRIVER_PERCEPTION_t *)
 
virtual void process (RDB_FUNCTION_t *)
 
virtual void process (RDB_ROAD_QUERY_t *)
 
virtual void process (RDB_TRAJECTORY_t *)
 
virtual void process (RDB_DYN_2_STEER_t *)
 
virtual void process (RDB_STEER_2_DYN_t *)
 
virtual void process (RDB_PROXY_t *)
 
virtual void process (RDB_MOTION_SYSTEM_t *)
 
virtual void process (RDB_FREESPACE_t *)
 
virtual void process (RDB_DYN_EL_SWITCH_t *)
 
virtual void process (RDB_DYN_EL_DOF_t *)
 
virtual void process (RDB_IG_FRAME_t *)
 
virtual void process (RDB_RT_PERFORMANCE_t *)
 
virtual void process (RDB_CUSTOM_SCORING_t *)
 
virtual void process (RDB_CUSTOM_OBJECT_CTRL_TRACK_t *)
 

Protected Attributes

std::unique_ptr< RdbTransceiverrdb_
 
uint64_t frame_number_ = 0
 Frame number from last processed RDB message.
 
bool processing_frame_ = false
 Indicates whether in between a start of frame and an end of frame message.
 

Friends

void to_json (cloe::Json &j, const RdbCodec &c)
 

Detailed Description

Base class for a VTD sensor which is connected via RDB.

Constructor & Destructor Documentation

◆ RdbCodec() [1/2]

vtd::RdbCodec::RdbCodec ( std::unique_ptr< RdbTransceiver > &&  rdb_transceiver)
inlineexplicit

Create a new instance of RdbCodec with the given RdbTransceiver.

◆ RdbCodec() [2/2]

vtd::RdbCodec::RdbCodec ( RdbTransceiver rdb_transceiver)
inlineexplicit

Create a new instance of RdbCodec with the given new RdbTransceiver.

WARNING: If you use this constructor, please realize that RdbCodec takes ownership of the pointer you pass in.

Member Function Documentation

◆ frame_number()

virtual uint64_t vtd::RdbCodec::frame_number ( ) const
inlinevirtual

Return the last processed frame number, 0 if no frames have been processed.

Here is the caller graph for this function:

◆ get_name()

virtual const std::string& vtd::RdbCodec::get_name ( ) const
pure virtual

Return the Codec's or Sensors' name. Will be overwritten by the name set in VtdSensorData.

Implemented in vtd::VtdOmniSensor.

◆ process() [1/3]

void vtd::RdbCodec::process ( RDB_MSG_ENTRY_HDR_t *  entry)
virtual

Process each RDB message entry. This method is called in process(RDB_MSG_t) for each entry in a message.

Parameters
entryRDB message entry to be processed
Here is the call graph for this function:

◆ process() [2/3]

void vtd::RdbCodec::process ( RDB_MSG_t *  msg,
bool &  restart,
cloe::Duration sim_time 
)
virtual

Process a RDB message. This method is called in process() for each RDB message.

Parameters
msgmessage to be processed
Here is the caller graph for this function:

◆ process() [3/3]

virtual void vtd::RdbCodec::process ( RDB_START_OF_FRAME_t *  )
inlinevirtual

Process a start of frame.

Parameters
start_of_frameonly used for dynamic binding; do not access.

Reimplemented in vtd::VtdOmniSensor.

◆ step()

void vtd::RdbCodec::step ( uint64_t  frame_number,
bool &  restart,
cloe::Duration sim_time 
)
virtual

Receive and process the incoming messages.

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ rdb_

std::unique_ptr<RdbTransceiver> vtd::RdbCodec::rdb_
protected

Connection via RDB bus, e.g., TCP, SHM, to VTD. Should always be valid.


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