atmega32u4-16mu ATMEL Corporation, atmega32u4-16mu Datasheet - Page 107

no-image

atmega32u4-16mu

Manufacturer Part Number
atmega32u4-16mu
Description
Atmega32u4 8-bit Avr Microcontroller With 32k Bytes Of Isp Flash And Usb Controller
Manufacturer
ATMEL Corporation
Datasheet
14.1.1
7766A–AVR–03/08
Registers
Figure 14-1. 16-bit Timer/Counter Block Diagram
Note:
The Timer/Counter (TCNTn), Output Compare Registers (OCRnA/B/C), and Input Capture Reg-
ister (ICRn) are all 16-bit registers. Special procedures must be followed when accessing the 16-
bit registers. These procedures are described in the section
page
CPU access restrictions. Interrupt requests (shorten as Int.Req.) signals are all visible in the
Timer Interrupt Flag Register (TIFRn). All interrupts are individually masked with the Timer Inter-
rupt Mask Register (TIMSKn). TIFRn and TIMSKn are not shown in the figure since these
registers are shared by other timer units.
The Timer/Counter can be clocked internally, via the prescaler, or by an external clock source on
the Tn pin. The Clock Select logic block controls which clock source and edge the Timer/Counter
uses to increment (or decrement) its value. The Timer/Counter is inactive when no clock source
is selected. The output from the clock select logic is referred to as the timer clock (clk
The double buffered Output Compare Registers (OCRnA/B/C) are compared with the
Timer/Counter value at all time. The result of the compare can be used by the Waveform Gener-
108. The Timer/Counter Control Registers (TCCRnA/B/C) are 8-bit registers and have no
1. Refer to
2. Tn only refers to T1 since T3 input is not available on the ATmega32U4 product
for Timer/Counter1 and 3 and 3 pin placement and description.
“Pinout ATmega32U4” on page
Timer/Counter
OCRnB
TCCRnA
OCRnA
OCRnC
TCNTn
ICRn
=
=
=
Direction
Count
Clear
Control Logic
TOP
=
TCCRnB
3,
Values
BOTTOM
Fixed
TOP
Table 10-3 on page
(1)
ICFn (Int.Req.)
TCLK
Detector
Edge
=
0
“Accessing 16-bit Registers” on
OCFnA
(Int.Req.)
OCFnB
(Int.Req.)
OCFnC
(Int.Req.)
TOVn
(Int.Req.)
Clock Select
Generation
Generation
Generation
( From Prescaler )
Waveform
Waveform
Waveform
Canceler
TCCRnC
Detector
Noise
Edge
70, and
ATmega32U4
Comparator Ouput )
Table 10-6 on page 73
( From Analog
OCnA
OCnB
OCnC
ICPn
.
Tn
(2)
T
n
).
107

Related parts for atmega32u4-16mu