dwwzl 发表于 2013-5-30 17:27:51

IAR怎么使用union和struct的结构

union
{
 struct
 {
  unsigned  b0:  1;
  unsigned  :  7; // 最高位保留
 }oneBit;
 uint8_t allBits;
} key_byte;
 
当b0改变的时候,key_byte.allBits并不变,一直是0xbe,是怎么回事?:o
页: [1]
查看完整版本: IAR怎么使用union和struct的结构