Pascal Serrarens 61740913fe Refactoring
2025-01-31 11:45:22 +01:00

31 lines
600 B
C++

#pragma once
#include "Messages.h"
namespace Passer {
namespace Control {
class CustomMsg : public IMessage {
public:
static const unsigned char id = 0xB1;
static const unsigned length = 3;
unsigned char networkId;
unsigned char thingId;
Thing *thing;
unsigned char bytesSize;
char *bytes = nullptr;
CustomMsg(char *buffer);
CustomMsg(unsigned char networkId, Thing *thing);
virtual ~CustomMsg();
virtual unsigned char Serialize(char *buffer) override;
static CustomMsg Receive(char *buffer, unsigned char bufferSize);
};
} // namespace Control
} // namespace Passer