1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/node/ synced 2025-03-09 00:00:00 +01:00

use same msg_format.h everywhere

This commit is contained in:
Steffen Vogel 2017-06-29 20:43:03 +02:00
parent 95167ffb8e
commit f6b439e740

View file

@ -62,14 +62,16 @@
**/
struct msg
{
#if BYTE_ORDER == LITTLE_ENDIAN
unsigned rsvd1 : 2; /**< Reserved bits */
unsigned type : 2; /**< Data or control message (see MSG_TYPE_*) */
unsigned version: 4; /**< Specifies the format of the remaining message (see MGS_VERSION) */
#elif BYTE_ORDER == BIG_ENDIAN
#if BYTE_ORDER == BIG_ENDIAN
unsigned version: 4; /**< Specifies the format of the remaining message (see MGS_VERSION) */
unsigned type : 2; /**< Data or control message (see MSG_TYPE_*) */
unsigned rsvd1 : 2; /**< Reserved bits */
#elif BYTE_ORDER == LITTLE_ENDIAN
unsigned rsvd1 : 2; /**< Reserved bits */
unsigned type : 2; /**< Data or control message (see MSG_TYPE_*) */
unsigned version: 4; /**< Specifies the format of the remaining message (see MGS_VERSION) */
#else
#error Invalid byte-order
#endif
uint8_t rsvd2; /**< Reserved bits */