ATMEGA32U4-AUR Atmel, ATMEGA32U4-AUR Datasheet - Page 36

MCU AVR 16K FLASH 16MHZ 44TQFP

ATMEGA32U4-AUR

Manufacturer Part Number
ATMEGA32U4-AUR
Description
MCU AVR 16K FLASH 16MHZ 44TQFP
Manufacturer
Atmel
Series
AVR® ATmegar
Datasheet

Specifications of ATMEGA32U4-AUR

Core Processor
AVR
Core Size
8-Bit
Speed
16MHz
Connectivity
I²C, SPI, UART/USART, USB
Peripherals
Brown-out Detect/Reset, POR, PWM, WDT
Number Of I /o
26
Program Memory Size
32KB (16K x 16)
Program Memory Type
FLASH
Eeprom Size
1K x 8
Ram Size
2.5K x 8
Voltage - Supply (vcc/vdd)
2.7 V ~ 5.5 V
Data Converters
A/D 12x10b
Oscillator Type
External
Operating Temperature
-40°C ~ 85°C
Package / Case
44-TQFP, 44-VQFP
Lead Free Status / RoHS Status
Lead free / RoHS Compliant

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
ATMEGA32U4-AUR
Manufacturer:
Atmel
Quantity:
10 000
6.8.2
6.8.3
6.8.4
7766F–AVR–11/10
Switch from RC clock to external clock
CLKSEL0 – Clock Selection Register 0
CLKSEL1 – Clock Selection Register 1
• Bit 7-6 – RCSUT[1:0]: SUT for RC oscillator
These 2 bits are the SUT value for the RC Oscillator. If the RC oscillator is selected by fuse bits,
the SUT fuse are copied into these bits. A firmware change will not have any effect because this
additional start-up time is only used after a reset and not after a clock switch.
• Bit 5-4 – EXSUT[1:0]: SUT for External Clock/ Low Power Crystal Oscillator
These 2 bits are the SUT value for the External Clock / Low Power Crystal Oscillator. If the
External Clock / Low Power Crystal Oscillator is selected by fuse bits, the SUT fuses are copied
into these bits. The firmware can modify these bits by writing a new value. This value will be
used at the next start of the External Clock / Low Power Crystal Oscillator.
• Bit 3 – RCE: Enable RC Oscillator
The RCE bit must be written to logic one to enable the RC Oscillator. The RCE bit must be writ-
ten to logic zero to disable the RC Oscillator.
• Bit 2 – EXTE: Enable External Clock / Low Power Crystal Oscillator
The OSCE bit must be written to logic one to enable External Clock / Low Power Crystal Oscilla-
tor. The OSCE bit must be written to logic zero to disable the External Clock / Low Power Crystal
Oscillator.
• Bit 0 – CLKS: Clock Selector
The CLKS bit must be written to logic one to select the External Clock / Low Power Crystal Oscil-
lator as CPU clock. The CLKS bit must be written to logic zero to select the RC Oscillator as
CPU clock. After a reset, the CLKS bit is set by hardware if the External Clock / Low Power Crys-
tal Oscillator is selected by the fuse bits configuration.
The firmware has to check if the clock is correctly started before selected it.
Bit
Read/Write
Initial Value
Bit
Read/Write
Initial Value
if (Usb_wake_up_detected())
{
}
Usb_ack_wake_up();
Enable_external_clock();
while (!External_clock_ready()); // while (CLKSTA.EXTON != 1);
Select_external_clock();
Enable_pll();
Disable_RC_clock();
while (!Pll_ready());
Usb_unfreeze_clock();
7
RCSUT1
R/W
0
7
RCCKS
EL3
R/W
0
6
RCCKS
EL2
R/W
0
6
RCSUT0
R/W
0
5
RCCKS
EL1
R/W
1
5
EXSUT1
R/W
0
4
RCCKS
EL0
0
R/W
4
EXSUT0
R/W
0
3
EXCKS
EL3
R/W
0
// if (UDINT.WAKEUPI == 1)
// UDINT.WAKEUPI = 0;
// CKSEL0.EXTE = 1;
// CLKSEL0.CLKS = 1;
// PLLCSR.PLLE = 1;
// CLKSEL0.RCE = 0;
// while (PLLCSR.PLOCK != 1);
// USBCON.FRZCLK = 0;
3
RCE
R/W
See Bit Description
2
EXCKS
EL2
R/W
0
2
EXTE
R/W
0
1
EXCKS
EL1
R/W
ATmega16/32U4
-
1
R
0
EXCKS
EL0
R/W
0
0
CLKS
R/W
CLKSEL1
CLKSEL0
36

Related parts for ATMEGA32U4-AUR