35 #ifndef SICK_SAFETYSCANNERS_DATA_PROCESSING_TCPPACKETMERGER_H 36 #define SICK_SAFETYSCANNERS_DATA_PROCESSING_TCPPACKETMERGER_H 46 namespace data_processing {
122 #endif // SICK_SAFETYSCANNERS_DATA_PROCESSING_TCPPACKETMERGER_H sick::datastructure::PacketBuffer getDeployedPacketBuffer()
Gets the latest complete data packet.
A packetbuffer for the raw data from the sensor.
bool addTCPPacket(const sick::datastructure::PacketBuffer &buffer)
Adds a new tcp packet to the merger. Returns true if this tcp packet completes a data packet...
bool isEmpty() const
Checks if the buffer vector is empty.
uint32_t getTargetSize() const
Returns the expected target size of a complete data packet.
uint32_t getCurrentSize()
bool isComplete() const
Check if the packet is complete.
bool addToMap(const sick::datastructure::PacketBuffer &new_packet)
bool deployPacketIfComplete()
sick::datastructure::PacketBuffer m_deployed_packet_buffer
TCPPacketMerger()
Constructor of merger.
std::mutex m_buffer_mutex
void setTargetSize(const uint32_t &targetSize)
Sets the target size of a data packet.
std::vector< sick::datastructure::PacketBuffer > m_buffer_vector
Merges incoming tcp packets together to get a complete data packet.