Ece3003 Microcontroller and Its Applications Quick References
Ece3003 Microcontroller and Its Applications Quick References
Ece3003 Microcontroller and Its Applications Quick References
QUICK REFERENCES
Memory Organization
PSW REGISTER
MACHINE CYCLES
A cycle is, in reality, 12 pulses of the crystal
Since we know the crystal is pulsing 11,059,000 times per second and
that one machine cycle is 12 pulses, we can calculate how many
instruction cycles the 8051 can execute per second:
TMOD REGISTER
To calculate the values to be loaded into the TL and TH registers, look at the following
example
Assume XTAL = 11.0592 MHz, we can use the following steps for finding the TH, TL
registers’ values
3. Convert the result of Step2 to hex, where yyxx is the initial hex value to be loaded into
the timer’s register
Solution:
3. 10 ms / 1.085 s = 9216
6. CLR P2.3
MOV TH1,#0DCH
CPL P2.3
ORG 0000H
RET
RET
RET
END