MOV A,P2 ; Move P2 (SFR @ 0xA0) to ACC (SFR @ 0xE0)
ANL A,#(1<<3) ; Mask off all bits except bit 3
JNZ ITS_A_ONE
ITS_A_ZERO:
...
...
ITS_A_ONE:
JB P2.3,ITS_A_ONE
ITS_A_ZERO:
...
...
ITS_A_ONE:
JNB P2.3,ITS_A_ZERO
ITS_A_ONE:
...
...
ITS_A_ZERO:
MOV C,P2.3
JC ITS_A_ONE
ITS_A_ZERO:
...
...
ITS_A_ONE:
by Jake Hertz
by Aaron Carman
by Aaron Carman
by Duane Benson