Rainbow Electronics AT89C5122 User Manual
Page 46
46
AT8xC5122/23
4202E–SCR–06/06
Figure 21. X1 mode
When the X1 mode is selected, the CPU and Peripherals work at 8Mhz / X1
Figure 22. X2 mode
When the X2 mode is selected, the CPU works at 8 MHz / X2. The Peripherals can work
at 8 MHz / X2 or 8 MHz / X1.
When the PR1 prescaler is different from 1/2, the usual X1 mode can not be defined. In
this case, it is necessary to define a X1 or X2 equivalent mode from equivalent clock
circuits.
Example : PR1=1/8, X2=0.
In this configuration, the CPU works at 1 MHz. This frequency could also be obtained by
an equivalent clock circuit where the on-chip oscillator would run at 2 MHz in X1 mode
or at 1 MHz in X2 mode. So we can say that the CPU works at 2 MHz / X1 or 1MHz / X2.
As the X2 bit is cleared in CKCON0 register, we have F
CK_IDLE
= F
CK_PERIPH
.
8 MHz
1/2
PR1 prescaler
CPU frequency
4 MHz
4 MHz
Peripheral frequency
Crystal
8 MHz
CPU frequency (X2 Mode)
8 MHz
8 MHz
Peripheral frequency (X2 mode)
4 MHz
1/2
Peripheral frequency (X1 mode)
Internal Prescaler
Crystal