Section 11 8-Bit Timers (TMR)
11.4.2
Reset Input
Figure 11.4 shows an example of the 8-bit timer being used to generate a pulse which is output
after a desired delay time from a TMRI input. The control bits are set as follows:
1. Set both bits CCLR1 and CCLR0 in TCR to 1 and set the TMRIS bit in TCCR to 1 so that
TCNT is cleared at the high level input of the TMRI signal.
2. In TCSR, set bits OS3 to OS0 to B'0110, causing the output to change to 1 at a TCORA
compare match and to 0 at a TCORB compare match.
With these settings, the 8-bit timer provides pulses output at a desired delay time from a TMRI
input determined by TCORA and with a pulse width determined by TCORB and TCORA.
TCORB
TCORA
H'00
TMRI
TMO
Rev.2.00 Jun. 28, 2007 Page 426 of 666
REJ09B0311-0200
TCNT
Figure 11.4 Example of Reset Input