AnsweredAssumed Answered

#pragma pack(1) supported?

Question asked by Markku Pulsa on Nov 9, 2011
Latest reply on Mar 19, 2012 by raghu kumar


How to tell CW compiler to pack structs?

#pragma pack(1) gives an "Illegal pragma" warning and does not pack variables.


The compiler generates dummy byte between variables:

typedef struct {
    uint_8 channel;
    uint_16 value;


When communicating with other systems the struct need to be packed.