Atmel Evaluation Kit AT91SAM9G25-EK AT91SAM9G25-EK Data Sheet

Product codes
AT91SAM9G25-EK
Page of 1102
174
SAM9G25 [DATASHEET]
11032C–ATARM–25-Jan-13
21.4.3 Switch from the 32768 Hz Crystal to Internal 32 kHz RC Oscillator
The same procedure must be followed to switch from a 32768 Hz crystal to the internal 32 kHz RC oscillator. 
z
Switch the master clock to a source different from slow clock (PLL or Main Oscillator). 
z
Enable the internal 32 kHz RC oscillator for low power by setting the bit RCEN to 1
z
Wait internal 32 kHz RC Startup Time for clock stabilization (software loop).
z
Switch from 32768 Hz oscillator to internal RC by setting the bit OSCSEL to 0.
z
Wait 5 slow clock cycles for internal resynchronization.
z
Disable the 32768 Hz oscillator by setting the bit OSC32EN to 0.
z
Switch the master clock back to the slow clock domain