A
A
Ainur Shakirov2015-12-06 17:54:55
Microcontrollers
Ainur Shakirov, 2015-12-06 17:54:55

How to calculate the timer for micro ADuC842?

Explain how TH0 and TL0 are calculated. I understood the essence, but I didn’t understand how 20 ms comes out here.
void setBeginParam() {
P0 = 0xF0;
tmod=0x01;
}
void timer() //20msec
{
TH0 = 0x57;
TL0 = 0x0A;
TF0=0;
TR0 = 0x01;
while (!TF0) {
;
}
TF0 = 0;
TR0 = 0;
}
Nothing is clear from the doc... www.labfor.ru/guidance/mpu-leso1/4

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question