24 #define XSMESSAGE_INITIALIZER { XSBYTEARRAY_INITIALIZER, 1, 0 } 78 #define XS_PREAMBLE 0xFA 79 #define XS_EXTLENCODE 0xFF 81 #define XS_LEN_MSGHEADER 4 82 #define XS_LEN_MSGEXTHEADER 6 83 #define XS_LEN_MSGHEADERCS 5 84 #define XS_LEN_MSGEXTHEADERCS 7 85 #define XS_LEN_CHECKSUM 1 86 #define XS_LEN_UNSIGSHORT 2 87 #define XS_LEN_UNSIGINT 4 88 #define XS_LEN_FLOAT 4 91 #define XS_MAXDATALEN (8192-XS_LEN_MSGEXTHEADERCS) 92 #define XS_MAXSHORTDATALEN 254 93 #define XS_MAXMSGLEN (XS_MAXDATALEN+XS_LEN_MSGEXTHEADERCS) 94 #define XS_MAXSHORTMSGLEN (XS_MAXSHORTDATALEN+XS_LEN_MSGHEADERCS) 95 #define XS_MAXGARBAGE (XS_MAXMSGLEN+1) 100 #pragma pack(push, 1) 106 #define PACK_POST __attribute__((__packed__)) 196 bool empty(
void)
const 268 XsSize getDataSize(
void)
const 284 const uint8_t* getMessageStart(
void)
const 291 XsSize getTotalMessageSize(
void)
const 298 bool isChecksumOk(
void)
const 313 return isChecksumOk();
318 void recomputeChecksum(
void)
325 void resizeData(
XsSize newSize)
510 void updateChecksumPtr()
523 #define swapEndian16(src) (((src) >> 8) | ((src) << 8)) 524 #define swapEndian32(src) (((src) >> 24) | (((src) >> 8) & 0xFF00) | (((src) << 8) & 0xFF0000) | ((src) << 24)) 525 #define swapEndian64(src) (((src >> 56) & 0xFFULL) | ((src >> 40) & 0xFF00ULL) | ((src >> 24) & 0xFF0000ULL) | ((src >> 8) & 0xFF000000ULL) | ((src << 8) & 0xFF00000000ULL) | ((src << 24) & 0xFF0000000000ULL) | ((src << 40) & 0xFF000000000000ULL) | ((src << 56))) XSTYPES_DLL_API int XsMessage_empty(XsMessage const *thisPtr)
XSTYPES_DLL_API double XsMessage_getDataFP1632(XsMessage const *thisPtr, XsSize offset)
bool operator==(const TPoint2D &p1, const TPoint2D &p2)
Exact comparison between 2D points.
GLuint GLuint GLsizei count
XSTYPES_DLL_API const uint8_t * XsMessage_constData(XsMessage const *thisPtr, XsSize offset)
XSTYPES_DLL_API XsSize XsMessage_getTotalMessageSize(XsMessage const *thisPtr)
XSTYPES_DLL_API void XsMessage_setMessageId(XsMessage *thisPtr, XsXbusMessageId msgId)
XSTYPES_DLL_API double XsMessage_getDataDouble(XsMessage const *thisPtr, XsSize offset)
EIGEN_STRONG_INLINE bool empty() const
XSTYPES_DLL_API uint32_t XsMessage_getDataLong(XsMessage const *thisPtr, XsSize offset)
unsigned __int16 uint16_t
XSTYPES_DLL_API void XsMessage_setBusId(XsMessage *thisPtr, uint8_t busId)
XSTYPES_DLL_API void XsMessage_setDataFPValuesById(XsMessage *thisPtr, XsDataIdentifier dataIdentifier, double const *data, XsSize offset, XsSize numValues)
XSTYPES_DLL_API XsMessageHeader * XsMessage_getHeader(XsMessage *)
XSTYPES_DLL_API void XsMessage_setDataFP1632(XsMessage *thisPtr, double value, XsSize offset)
XSTYPES_DLL_API void XsMessage_setDataByte(XsMessage *thisPtr, uint8_t value, XsSize offset)
XSTYPES_DLL_API const uint8_t * XsMessage_getMessageStart(XsMessage const *thisPtr)
struct XsByteArray XsByteArray
XSTYPES_DLL_API void XsMessage_setDataShort(XsMessage *thisPtr, uint16_t value, XsSize offset)
size_t XsSize
XsSize must be unsigned number!
XsDataIdentifier
Defines the data identifiers.
XSTYPES_DLL_API uint8_t XsMessage_getDataByte(XsMessage const *thisPtr, XsSize offset)
XSTYPES_DLL_API void XsMessage_deleteData(XsMessage *thisPtr, XsSize count, XsSize offset)
void clear()
Clear the contents of this container.
XSTYPES_DLL_API void XsMessage_getDataFPValuesById(XsMessage const *thisPtr, XsDataIdentifier dataIdentifier, double *dest, XsSize offset, XsSize numValues)
XSTYPES_DLL_API void XsMessage_setDataBuffer(XsMessage *thisPtr, const uint8_t *buffer, XsSize size, XsSize offset)
XSTYPES_DLL_API void XsMessage_destruct(XsMessage *thisPtr)
XSTYPES_DLL_API void XsMessage_setDataF1220(XsMessage *thisPtr, double value, XsSize offset)
XSTYPES_DLL_API int XsMessage_compare(XsMessage const *a, XsMessage const *b)
Structure for storing a single message.
XSTYPES_DLL_API void XsMessage_load(XsMessage *thisPtr, XsSize msgSize, unsigned char const *src)
XSTYPES_DLL_API double XsMessage_getDataF1220(XsMessage const *thisPtr, XsSize offset)
XSTYPES_DLL_API void XsMessage_copy(XsMessage *copy, XsMessage const *src)
XSTYPES_DLL_API const uint8_t * XsMessage_getDataBuffer(XsMessage const *thisPtr, XsSize offset)
XSTYPES_DLL_API const XsMessageHeader * XsMessage_getConstHeader(XsMessage const *thisPtr)
XSTYPES_DLL_API void XsMessage_swap(XsMessage *a, XsMessage *b)
XsXbusMessageId
Xsens Xbus Message Identifiers.
XSTYPES_DLL_API uint8_t XsMessage_computeChecksum(XsMessage const *thisPtr)
unsigned __int64 uint64_t
XSTYPES_DLL_API void XsMessage_getDataFPValues(XsMessage const *thisPtr, uint64_t outputSettings, double *dest, XsSize offset, XsSize numValues)
XSTYPES_DLL_API XsSize XsMessage_dataSize(XsMessage const *thisPtr)
XSTYPES_DLL_API void XsMessage_constructSized(XsMessage *thisPtr, XsSize dataSize)
uint8_t *const m_checksum
XSTYPES_DLL_API void XsMessage_assign(XsMessage *thisPtr, XsSize dataSize)
XSTYPES_DLL_API void XsMessage_setDataFPValues(XsMessage *thisPtr, uint64_t outputSettings, double const *data, XsSize offset, XsSize numValues)
XSTYPES_DLL_API int XsMessage_isChecksumOk(XsMessage const *thisPtr)
XSTYPES_DLL_API float XsMessage_getDataFloat(XsMessage const *thisPtr, XsSize offset)
GLsizei GLsizei GLchar * source
XSTYPES_DLL_API void XsMessage_setDataFloat(XsMessage *thisPtr, float value, XsSize offset)
GLsizei const GLfloat * value
struct XsMessage XsMessage
XSTYPES_DLL_API void XsMessage_construct(XsMessage *thisPtr)
XSTYPES_DLL_API void XsMessage_resizeData(XsMessage *thisPtr, XsSize newSize)
unsigned __int32 uint32_t
GLsizei GLsizei GLenum GLenum const GLvoid * data
GLubyte GLubyte GLubyte a
XSTYPES_DLL_API void XsMessage_insertData(XsMessage *thisPtr, XsSize count, XsSize offset)
XSTYPES_DLL_API void XsMessage_setDataLong(XsMessage *thisPtr, uint32_t value, XsSize offset)
XSTYPES_DLL_API void XsMessage_setDataDouble(XsMessage *thisPtr, double value, XsSize offset)
XSTYPES_DLL_API void XsMessage_copyConstruct(XsMessage *thisPtr, XsMessage const *src)
XSTYPES_DLL_API uint16_t XsMessage_getDataShort(XsMessage const *thisPtr, XsSize offset)
XSTYPES_DLL_API void XsMessage_recomputeChecksum(XsMessage *thisPtr)