Sleep and Watchdog
CY8C24xxx Preliminary Data Sheet
78
Document No. 38-12011 Rev. *E
December 22, 2003
oscillator. The operating voltage requirements are not
relaxed until the CPU speed is at 12.0 MHz or less.
For additional information, reference the
OSC_CR0 register
on page 176
.
12.3.4
CPU_SCR1 Register
This register contains bits (3 and 2) that ensure high Watch-
dog Reset integrity. Since the 32 kHz oscillator source may
be programmatically switched between the ECO and ILO,
the switch-over must only be allowed to occur if the external
crystal system actually exists. These bits are not reset by a
Watchdog Reset event.
Bits 7 to 1: Reserved.
Bit 0: IRAMDIS.
The Initialize RAM Disable bit is a control
bit that is readable and writeable. The default value for this
bit is 0, which indicates that the maximum amount of SRAM
should be initialized on reset to a value of 00h. When the bit
is set, the minimum amount of SRAM is initialized after a
watchdog reset. For more information on this bit, see the
“SROM Function Descriptions” on page 48
.
For additional information, reference the
CPU_SCR1 regis-
ter on page 153
.
12.3.5
ILO_TR Register
This register sets the adjustment for the ILO. The device
specific value, placed in the trim bits of this register at boot
time, is based on factory testing.
It is strongly recommended that the user not alter the
register value.
Bits 7 and 6: Reserved.
Bits 5 and 4: Bias Trim.
Bits 3 to 0: Freq Trim.
Four bits are used to trim the fre-
quency. The value is set in the factory and should not be
changed.
For additional information, reference the
ILO_TR register on
page 182
.
12.3.6
ECO_TR Register
The External Crystal Oscillator Trim register (ECO_TR) sets
the adjustment for the External Crystal Oscillator. The value
placed in this register is based on factory testing. This regis-
ter does not adjust the frequency of the External Crystal
Oscillator. It is recommended that the user does not alter the
bits in this register.
Bits 7 and 6: PSSDC[1:0].
These bits are used to set the
sleep duty cycle.
Bits 5 to 0: Reserved.
For additional information, reference the
ECO_TR register
on page 184
.
12.3.7
CPU_SCR0 Register
The bits of the CPU_SCR0 register are used to convey sta-
tus and control of events for various functions of a PSoC
device.
Bit 7: GIES.
The Global Interrupt Enable Status bit is a
read only status bit and its use is discouraged. The GIES bit
is a legacy bit which was used to provide the ability to read
the GIE bit of the CPU_F register. However, the CPU_F reg-
ister is now readable. When this bit is set, it indicates that
the GIE bit in the CPU_F register is also set which, in turn,
indicates that the microprocessor will service interrupts.
Bit 6: Reserved.
Bit 5: WDRS.
The WatchDog Reset Status bit is normally
zero, but set whenever a watchdog reset occurs. The bit is
readable and clearable by writing a zero to its bit position in
the CPU_SCR0 register. This bit may not be set.
Bit 4: PORS.
The Power-On Reset Status (PORS) bit and
watchdog enable bit will be set automatically by a POR or
external reset. If the bit is cleared by user code, the watch-
dog timer will be enabled. Once cleared, the only way to
reset the PORS bit is to go through a POR or external reset.
Thus, there is no way to disable the watchdog timer, other
than to go through a POR or external reset.
Bit 3: Sleep.
The Sleep bit is used to enter low power
Sleep mode when set, as described in this chapter.
Bits 2 and 1: Reserved.
Bit 0: STOP.
The STOP bit is readable and writeable.
When set, the PSoC M8C will stop executing code until a
reset event occurs. This can be either a POR, watchdog
reset, or external reset. If an application wants to stop code
execution until a reset, the preferred method would be to
use the HALT instruction rather than a register write to this
bit.
For additional information, reference the
CPU_SCR0 regis-
ter on page 154
.
Table 12-3. OSC_CR0[2:0] Bits: CPU Speed
Bits
000b
001b
010b
011b
100b
101b
110b
111b
Internal Main Oscillator
3 MHz
6 MHz
12 MHz
24 MHz
1.5 MHz
750 kHz
187.5 kHz
93.7 kHz
External Clock
EXTCLK/ 8
EXTCLK/ 4
EXTCLK/ 2
EXTCLK/ 1
EXTCLK/ 16
EXTCLK/ 32
EXTCLK/ 128
EXTCLK/ 256