解释一下这个c语言的数据结构
typedef union{
unsigned char Byte;
struct
{
unsigned char _RD: 1;
unsigned char _WR: 1;
unsigned char _A0: 1;
unsigned char _MM: 2;
unsigned char _LCD_E: 1;
unsigned char _MMM: 2;
}Bit;
}UNION_PORT;
typedef union //类型定义共用体
{
unsigned char Byte;// 定义一个字节
struct
{
unsigned char _RD: 1; 0
unsigned char _WR: 1; 1
unsigned char _A0: 1; 2
unsigned char _MM: 2; 3,4
unsigned char _LCD_E: 1;5
unsigned char _MMM: 2; 6,7
}Bit;file://定义8位结构体BIT
}UNION_PORT; file://PORT共用体UNION_PORT
页:
[1]