各位大侠:
小弟用processor expert,定义的标志位(如:FG_LF_Moved)如何在两个文件中(如:main和event)共用?敬请大侠指教。
typedef union
{
unsigned char FlagByte;
struct {
unsigned char Flag0 :1;
unsigned char Flag1 :1;
unsigned char Flag2 :1;
unsigned char Flag3 :1;
unsigned char Flag4 :1;
unsigned char Flag5 :1;
unsigned char Flag6 :1;
unsigned char Flag7 :1;
} Bits;
} Flag;
Flag GsFlag1;
#define FG_LF_Moved GsFlag1.Bits.Flag0
欢迎光临 电子技术论坛_中国专业的电子工程师学习交流社区-中电网技术论坛 (http://bbs.eccn.com/) | Powered by Discuz! 7.0.0 |