User guide
Chapter 5 - PASHA
54 Version 1.7.2.0 March 27, 2015
This uses the cSETVALUE command abbreviated to S. The end-of-message character is a
period (.).
And the response would be:
V2iG00.
C-like message definition
This section defines the message protocol using C-like declarations of constants and
structures. The convention here is that words beginning with c, such as cSETVALUE and
cGETVALUE, are character constants. Words beginning with f, such as fUid and fVal, are
message field structures. Words beginning with m, such as mSetValue and mGetValue, are
message structures.
//---- Message constants
const char cSETVALUE = 'S'; // an fType value
const char cGETVALUE = 'G'; // an fType value
const char cVALUE = 'V'; // an fType value
const char cNOTREADY = 'R'; // an fType value
const char cUNLISTEDUID = 'U'; // an fType value
const char cFAIL = 'X'; // an fType value
const char cNAK = '?'; // an fType value
const char cEOM = '.'; // an fEom value
//---- Message fields
/* fType: Message Type. 1 character, denotes the message type. */
struct fType {
char data;
};
/* fUid: User ID. 3 ASCII characters, specifies one of the User IDs entered
as a control alias in the project. */
struct fUid {
char data[3];
};
/* fVal: Control Value. 2 ASCII hexadecimal digits, specifies a control
value between 0 and 255. */
struct fVal {
char data[2];
};
/* fEom: End Of Message. 1 character, appears at the end of every message,
excepting mNak. */
struct fEom {