8051 microcontroller

Arm_n_Legs

Joined Mar 7, 2007
186
[01[ Read the content of Port 0 to the Accumulator.
[02] Read the content of Port 2 to a register (say R1) and add 1 to it.
[03] Perform a RLC A based on the number in R1. (Use DJNZ)
[04] The required bit to be output is now in the Carry Flag.
[05] Use the MOV bit,C and move bit to P1.5.
 
Top