Using ARM and RTX on MCB2300, I have the following struct defined from an extern file storage array:
typedef struct choreoEvent { U8 flags; U16 leftover; U8 disable; U16 cueid; U32 time; char name[6]; U32 circuit; char display[12]; } choreoEvent_t;
This is 32 bytes in storage, but sizeof is reporting it as 36 bytes, and trying to access name starts 2 bytes off.
Is it doing alignment on the U8's or something? I can't restructure it because it's being read form an external file stream. Anyone see what's happening?
That was my guess as well, but it doesn't help, knowing it's off I still can't use the event.name construct because it's pointing to the wrong place. I've been looking through docs, seeing if this padding is mentioned anywhere, and if there's a way to turn it off. Haven't found it yet...