
Chapter 8
8-bit Timer
Cascade Connection
VIII - 43
..
In reading out value of binary counter during timer operation with 8-bit timer in cascade con-
nection, the value of binary counter may not be correctly read out.
There are multiple binary counters of 8-bit timer, but all binary counters connectable in cas-
cade are not allocated to continuous addresses. Binary counter can be read out with 8, 16
and 32-bit access instruction. But binary counter in cascade connection may not be read out
at a time according to the combination of the number of binary counters connected in cas-
cade.
Therefore, if raised from the lower 8 bits to the upper 8bits during several-time readout, cor-
rect value cannot be read out.
(1) In case of 16-bit cascade connection 1 (In case the lower 8 bit timer addresses are even)
In 8-bit access instruction, the value of 16 bit binary counter cannot be read out at a time.
Therefore, if the digit is raised from the lower 8 bits to the upper 8 bits, correct value cannot
be read out.
In 16-bit access instruction, correct value can be read out.
(2) In case of 16-bit cascade connection 2 (In case the lower 8 bit timer addresses are odd)
As each timer address is discontinuous, the value of binary counter cannot be read out at a
time in either 16 or 32-bit access instruction.
Stop the timer in order to read out the correct value.
(3) In case of 24-bit cascade connection, 32-bit cascade connection
As each timer address is discontinuous, the value of binary counter cannot be read out at a
time even if 32-bit access instruction is used.
Stop the timer in order to read out the correct value.
..
x'0000A18X
Adderss
not continuous.
The address of the binary counter is continuous.
TM3BR
x = E
x = F
x = C
x = D
x = A
x = B
x = 8
x = 9
x = 6
x = 7
x = 4
x = 5
x = 2
x = 3
x = 0
x = 1
TM2BR
TM1BR TM0BR
TM3MD TM2MD
TM1MD TM0MD
x'0000A19X
TM03PSC
TM3BC TM2BC
TM1BC TM0BC
x'0000A1AX
TM7BR TM6BR
TM5BR TM4BR
TM7MD TM6MD
TM5MD TM4MD
x'0000A1BX
TM47PSC
TM7BC TM6BC
TM5BC TM4BC
Example of 8-bit Timer Address Map (TMnBC:binary counter)
Image chart when value of binary counter is read
by two 8-bit accesses with 16-bit timer that connects 8-bit timer in cascade.
Read Address
Binary counter
Resister read signal
CPU read data
Count clock
Lower 8-bit address
Upper 8-bit address
02fd is stored in CPU register though I want to read 01fd.
Carry
01fb
01fc
01fd
01fe
fd
02
01ff
0200
0201
0202