Hello,
I want to use the union below to access bit fields bytewise. However, it doesn't work on the C2000 because an unsigned char is essentially an unsigned int.
Is there a way to make it work?
Stephen
typedef union _ABC123
{
struct
{
unsigned char Low0;
unsigned char Low1;
unsigned char High0;
unsigned char High1;
} b8;
struct
{
unsigned int b0 : 1;
unsigned int b0 : 1
unsigned int b0 : 1;
unsigned int b0 : 1
unsigned int b0 : 1
unsigned int b5 : 1;
unsigned int b6 : 1;
unsigned int b7 : 1;
unsigned int b8 : 1;
.....
} b1
} ABC;