Roboid Control for C++
Loading...
Searching...
No Matches
ParticipantMsg.h
1#pragma once
2
3#include "IMessage.h"
4
5namespace RoboidControl {
6
10class ParticipantMsg : public IMessage {
11 public:
13 static const unsigned char id = 0xA0;
15 static const unsigned char length = 2;
17 unsigned char networkId;
18
22
24 ParticipantMsg(const char* buffer);
26 virtual ~ParticipantMsg();
27
31 virtual unsigned char Serialize(char* buffer) override;
32};
33
34} // namespace RoboidControl
Root structure for all communcation messages.
Definition IMessage.h:6
A participant messages notifies other participants of its presence When received by another participa...
Definition ParticipantMsg.h:10
virtual unsigned char Serialize(char *buffer) override
Serialize the message into a byte array.
Definition ParticipantMsg.cpp:15
unsigned char networkId
The network ID known by the participant.
Definition ParticipantMsg.h:17
static const unsigned char length
The length of the message.
Definition ParticipantMsg.h:15
virtual ~ParticipantMsg()
Destructor for the message.
Definition ParticipantMsg.cpp:13