s908qy2ad1vdwer Freescale Semiconductor, Inc, s908qy2ad1vdwer Datasheet - Page 134

no-image

s908qy2ad1vdwer

Manufacturer Part Number
s908qy2ad1vdwer
Description
Mc68hc908qt4a Microcontroller
Manufacturer
Freescale Semiconductor, Inc
Datasheet
Timer Interface Module (TIM)
14.8.2 TIM Counter Registers
The two read-only TIM counter registers contain the high and low bytes of the value in the counter.
Reading the high byte (TCNTH) latches the contents of the low byte (TCNTL) into a buffer. Subsequent
reads of TCNTH do not affect the latched TCNTL value until TCNTL is read. Reset clears the TIM counter
registers. Setting the TIM reset bit (TRST) also clears the TIM counter registers.
14.8.3 TIM Counter Modulo Registers
The read/write TIM modulo registers contain the modulo value for the counter. When the counter reaches
the modulo value, the overflow flag (TOF) becomes set, and the counter resumes counting from $0000
at the next timer clock. Writing to the high byte (TMODH) inhibits the TOF bit and overflow interrupts until
the low byte (TMODL) is written. Reset sets the TIM counter modulo registers.
134
Reset:
Reset:
Reset:
Reset:
Read:
Write:
Read:
Write:
Read:
Read:
If you read TCNTH during a break interrupt, be sure to unlatch TCNTL by
reading TCNTL before exiting the break interrupt. Otherwise, TCNTL
retains the value latched during the break.
Write:
Write:
Reset the counter before writing to the TIM counter modulo registers.
Figure 14-7. TIM Counter Modulo High Register (TMODH)
Figure 14-8. TIM Counter Modulo Low Register (TMODL)
Bit 15
Bit15
Bit 7
Bit 7
Bit 7
Bit 7
Bit 7
Bit7
1
1
0
0
Figure 14-5. TIM Counter High Register (TCNTH)
Figure 14-6. TIM Counter Low Register (TCNTL)
= Unimplemented
= Unimplemented
Bit 14
Bit14
Bit 6
Bit6
MC68HC908QYA/QTA Family Data Sheet, Rev. 2
6
1
6
1
6
0
6
0
Bit 13
Bit13
Bit 5
Bit5
5
1
5
1
5
0
5
0
Bit 12
Bit12
NOTE
NOTE
Bit 4
Bit4
1
4
1
4
4
0
4
0
Bit 11
Bit11
Bit 3
Bit3
3
1
3
1
3
0
3
0
Bit10
Bit 10
Bit 2
Bit2
2
1
2
1
2
0
2
0
Bit 9
Bit 1
Bit9
Bit1
1
1
1
1
1
0
1
0
Freescale Semiconductor
Bit 0
Bit 0
Bit 0
Bit 8
Bit 0
Bit 0
Bit8
Bit0
1
1
0
0

Related parts for s908qy2ad1vdwer