Bit endianness is an issue in bitfields?
Dear ST hello,
I have a question about the bit field,
I am using the stm32F429 discovery board, and I am working on the gyroscope Mems.
if I declare a union like this:
typedef volatile union
{
uint8_t All;
struct
{
uint8_t Yen:1; /*X axis enable*/
uint8_t Xen:1; /*Y axis enable*/
uint8_t Zen:1; /*Z axis enable*/
uint8_t PD:1; /*Power-down mode enable*/
uint8_t BW0:1;
uint8_t BW1:1; /*Bandwidth selection*/
uint8_t DR0:1;
uint8_t DR1:1; /*Output data rate selection*/
} RegBits;
} Tst_CTRL_REG1;How does the compile organize the bits in memory?
Does the MSB is Yen or DR1?
Thank you in advance,
