• sizeof of struct with bit Field
    please explain me why the sizeof (C51) returns 6 bytes for this struct instead of 5: typedef struct DEKO_COMM_HEADER { UINT16 m_uiMsgOpcode; UCHAR8 m_sblMsgPriority :2; UINT16 m_sblDataLength...
  • bit field
    Hi All, I have a struct: union U { unsigned char c; struct { unsigned char bit0 : 1; unsigned char bit1 : 1; unsigned char bit2 : 1; . . . }S; }; } If I test multiple bits together...
  • Structure with bit field
    Is it possible to assign a structure (in C) with defined bit-fields to a SFR that is not bit addressable to gain bit addressability ?
  • signed bit fields
    Does anybody knows, Keil C compiler V7.xx supports bit fields with signed types or not? The code always generated same as for unsigned types. This is compiler bug or feature? My code compiled with Keil...
  • Large bit fields
    Hi, I'm using c51 on 8051. Is It possible to do a struct with large bit fields like: struct bit_st { int x :25; int y :22; int reserved :1; } (I know that int mean 16bit) Tnx, ...