注意红色代码部分,一个立即数,在后面的汇编语句中,居然给弄成了 P0, 虽然P0的地址是 0x80 ,但也不能这么弄啊! 刚开始看得我一头雾水,这个语句跟P0有啥关系呀!晕了好几分钟!
385: tcc[tcwp]=TH2<<7&TL2>>1; C:0x078D E5CD MOV A,TH2(0xCD) C:0x078F C4 SWAP A C:0x0790 33 RLC A C:0x0791 33 RLC A C:0x0792 33 RLC A C:0x0793 5480 ANL A,#P0(0x80) C:0x0795 FF MOV R7,A C:0x0796 E5CC MOV A,TL2(0xCC) C:0x0798 C3 CLR C C:0x0799 13 RRC A C:0x079A 5F ANL A,R7 C:0x079B FF MOV R7,A C:0x079C 745D MOV A,#tcc(0x5D) C:0x079E 254B ADD A,tcwp(0x4B) C:0x07A0 F8 MOV R0,A C:0x07A1 A61F MOV @R0,0x1F |