Техническая Спецификация для Atmel Xplained Pro Evaluation Kit ATSAMD20-XPRO ATSAMD20-XPRO
![Atmel](https://files.manualsbrain.com/attachments/0369829915bda09f9c2e00fb805a7753579683b5/common/fit/150/50/8d2bf08978ec3e5bc63f4343ac5e91ce8d0e40045619fa520d910d64af8f/brand_logo.png)
Модели
ATSAMD20-XPRO
132
Atmel | SMART SAM D20 [DATASHEET]
Atmel-42129K–SAM-D20_datasheet–06/2014
16.6.2 External Multipurpose Crystal Oscillator (XOSC) Operation
The XOSC can operate in two different modes:
z
External clock, with an external clock signal connected to the XIN pin
z
Crystal oscillator, with an external 0.4-32MHz crystal
The XOSC can be used as a clock source for generic clock generators, as described in the
At reset, the XOSC is disabled, and the XIN/XOUT pins can be used as General Purpose I/O (GPIO) pins or by other
peripherals in the system. When XOSC is enabled, the operating mode determines the GPIO usage. When in crystal
oscillator mode, the XIN and XOUT pins are controlled by the SYSCTRL, and GPIO functions are overridden on both
pins. When in external clock mode, only the XIN pin will be overridden and controlled by the SYSCTRL, while the XOUT
pin can still be used as a GPIO pin.
peripherals in the system. When XOSC is enabled, the operating mode determines the GPIO usage. When in crystal
oscillator mode, the XIN and XOUT pins are controlled by the SYSCTRL, and GPIO functions are overridden on both
pins. When in external clock mode, only the XIN pin will be overridden and controlled by the SYSCTRL, while the XOUT
pin can still be used as a GPIO pin.
The XOSC is enabled by writing a one to the Enable bit in the External Multipurpose Crystal Oscillator Control register
(XOSC.ENABLE). To enable the XOSC as a crystal oscillator, a one must be written to the XTAL Enable bit
(XOSC.XTALEN). If XOSC.XTALEN is zero, external clock input will be enabled.
(XOSC.ENABLE). To enable the XOSC as a crystal oscillator, a one must be written to the XTAL Enable bit
(XOSC.XTALEN). If XOSC.XTALEN is zero, external clock input will be enabled.
When in crystal oscillator mode (XOSC.XTALEN is one), the External Multipurpose Crystal Oscillator Gain (XOSC.GAIN)
must be set to match the external crystal oscillator frequency. If the External Multipurpose Crystal Oscillator Automatic
Amplitude Gain Control (XOSC.AMPGC) is one, the oscillator amplitude will be automatically adjusted, and in most
cases result in a lower power consumption.
must be set to match the external crystal oscillator frequency. If the External Multipurpose Crystal Oscillator Automatic
Amplitude Gain Control (XOSC.AMPGC) is one, the oscillator amplitude will be automatically adjusted, and in most
cases result in a lower power consumption.
The XOSC will behave differently in different sleep modes based on the settings of XOSC.RUNSTDBY,
XOSC.ONDEMAND and XOSC.ENABLE:
XOSC.ONDEMAND and XOSC.ENABLE:
After a hard reset, or when waking up from a sleep mode where the XOSC was disabled, the XOSC will need a certain
amount of time to stabilize on the correct frequency. This start-up time can be configured by changing the Oscillator
Start-Up Time bit group (XOSC.STARTUP) in the External Multipurpose Crystal Oscillator Control register. During the
start-up time, the oscillator output is masked to ensure that no unstable clock propagates to the digital logic. The External
Multipurpose Crystal Oscillator Ready bit in the Power and Clock Status register (PCLKSR.XOSCRDY) is set when the
user-selected startup time is over. An interrupt is generated on a zero-to-one transition on PCLKSR.XOSCRDY if the
External Multipurpose Crystal Oscillator Ready bit in the Interrupt Enable Set register (INTENSET.XOSCRDY) is set.
amount of time to stabilize on the correct frequency. This start-up time can be configured by changing the Oscillator
Start-Up Time bit group (XOSC.STARTUP) in the External Multipurpose Crystal Oscillator Control register. During the
start-up time, the oscillator output is masked to ensure that no unstable clock propagates to the digital logic. The External
Multipurpose Crystal Oscillator Ready bit in the Power and Clock Status register (PCLKSR.XOSCRDY) is set when the
user-selected startup time is over. An interrupt is generated on a zero-to-one transition on PCLKSR.XOSCRDY if the
External Multipurpose Crystal Oscillator Ready bit in the Interrupt Enable Set register (INTENSET.XOSCRDY) is set.
Note:
Do not enter standby mode when an oscillator is in startup:
Wait for the OSCxRDY bit in SYSCTRL.PCLKSR register to be set before going into standby mode.
Wait for the OSCxRDY bit in SYSCTRL.PCLKSR register to be set before going into standby mode.
16.6.3 32kHz External Crystal Oscillator (XOSC32K) Operation
The XOSC32K can operate in two different modes:
z
External clock, with an external clock signal connected to XIN32
z
Crystal oscillator, with an external 32.768kHz crystal connected between XIN32 and XOUT32
XOSC.RUNSTDBY
XOSC.ONDEMAND
XOSC.ENABLE
Sleep Behavior
-
-
0
Disabled
0
0
1
Always run in IDLE sleep modes.
Disabled in STANDBY sleep mode.
0
1
1
Only run in IDLE sleep modes if
requested by a peripheral. Disabled in
STANDBY sleep mode.
1
0
1
Always run in IDLE and STANDBY sleep
modes.
1
1
1
Only run in IDLE or STANDBY sleep
modes if requested by a peripheral.