Atmel SAM4S-EK2 Atmel ATSAM4S-EK2 ATSAM4S-EK2 Data Sheet

Product codes
ATSAM4S-EK2
Page of 1125
 480
SAM4S [DATASHEET]
11100E–ATARM–24-Jul-13
28.2.16.8PMC Clock Generator Main Clock Frequency Register 
Name:
CKGR_MCFR
Address:
0x400E0424
Access:
Read-Write 
This register can only be written if the WPEN bit is cleared in 
.
• MAINF: Main Clock Frequency
Gives the number of Main Clock cycles within 16 Slow Clock periods.
• MAINFRDY: Main Clock Ready
0 = MAINF value is not valid or the Main Oscillator is disabled or a measure has just been started by means of RCMEAS.
1 = The Main Oscillator has been enabled previously and MAINF value is available.
Note:
To ensure that a correct value is read on the MAINF bitfield, the MAINFRDY flag must be read at 1 then another read 
access must be performed on the register to get a stable value on the MAINF bitfield.
• RCMEAS: RC Oscillator Frequency Measure (write-only)
0 = No effect.
1 = Restarts measuring of the main RC frequency. MAINF will carry the new frequency as soon as a low to high transition occurs 
on the MAINFRDY flag.
The measure is performed on the main frequency (i.e. not limited to RC oscillator only), but if the main clock frequency source is 
the fast crystal oscillator, the restart of measuring is not needed because of the well known stability of crystal oscillators.
31
30
29
28
27
26
25
24
23
22
21
20
19
18
17
16
RCMEAS
MAINFRDY
15
14
13
12
11
10
9
8
MAINF
7
6
5
4
3
2
1
0
MAINF