Roboid Control for C++
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
RoboidControl::NameMsg Class Reference

Detailed Description

Message for communicating the name of a thing.

#include <NameMsg.h>

Inherits RoboidControl::IMessage.

Public Member Functions

 NameMsg (unsigned char networkId, Thing *thing)
 Create a new message for sending.
 
 NameMsg (const char *buffer)
 
virtual ~NameMsg ()
 Destructor for the message.
 
virtual unsigned char Serialize (char *buffer) override
 

Static Public Member Functions

static unsigned char * ReceiveMsg (unsigned char packetSize)
 

Public Attributes

unsigned char networkId
 The network ID of the thing.
 
unsigned char thingId
 The ID of the thing.
 
unsigned char nameLength
 The length of the name, excluding the null terminator.
 
const char * name
 The name of the thing, not terminated with a null character.
 

Static Public Attributes

static const unsigned char id = 0x91
 The message ID.
 
static const unsigned char length = 4
 The length of the message.
 

Constructor & Destructor Documentation

◆ NameMsg() [1/2]

RoboidControl::NameMsg::NameMsg ( unsigned char  networkId,
Thing thing 
)

Create a new message for sending.

Parameters
networkIdThe network ID of the thing
thingThe ID of the thing

◆ NameMsg() [2/2]

RoboidControl::NameMsg::NameMsg ( const char *  buffer)

Member Function Documentation

◆ Serialize()

unsigned char RoboidControl::NameMsg::Serialize ( char *  buffer)
overridevirtual