如题,我用idata 定义了一个变量后 用sbit定义了几个位变量,但是编译的时候老出现错误,提示变量地址有误
global_EXT bdata uint8 Flag_Reg1; //global system status registor1
global_EXT sbit Com_Flag = Flag_Reg1^0; //flag is ON when VDD_CAN_Sensor is detected,it is set in ISR function
global_EXT sbit Current_Sampling_Flag = Flag_Reg1^1; //flag is ON when 12 cells voltage sampling is finished
global_EXT sbit Volatge_Sampling_Flag = Flag_Reg1^2; //flag is ON when 12 cells voltage sampling is finished
global_EXT sbit VDD_CAN_Flag = Flag_Reg1^4; //flag is ON when Extenal power is ON
这是编译器提示:'Flag_Reg1': invalid base address
到底问题在哪里呢?
|