Datasheet
2010-2013 Microchip Technology Inc. DS20002266E-page 21
MCP79410/MCP79411/MCP79412
8.0 SPECIAL FEATURES
8.1 Oscillator Failure Status
The MCP7941X family of devices support an on-board
oscillator failure flag. In register 0x03 (Day Register –
shown below), the OSCON (bit 5) provides a way to
observe the current status of the oscillator.
The state of the bit indicates the oscillator status.
1 = The oscillator is running
0 = The oscillator is not running
The status does not indicate that the oscillator is run-
ning accurately. The OSCON bit is set after 32 stable
oscillator cycles. If the oscillator is stopped by either
clearing the ST bit or the oscillator support components
fail, the OSCON bit is cleared by the hardware after
T
OSF
. This is timed internally using an on-chip time-out
circuit.
Figure 8-1 shows the operation.
It should be noted that this bit is both set and cleared
by the RTCC hardware, and it will not show that the
oscillator failed in the past. The user can poll this bit at
any time to determine if the oscillator is running.
FIGURE 8-1: OSCON DIAGRAM
OSCON Bit
(Register 0x03 Bit 5)
32 Oscillator Cycles
T
OSF
Crystal Oscillator
<T
OSF
REGISTER 8-1: DAY 0X03
U-0 U-0 R-0 R/W-0 R/W-0 R/W-1
— — OSCON VBAT VBATEN Day
bit 7 bit 6 bit 5 bit 4 bit 3 bit 2 bit 0
Legend:
R = Readable bit W = Writable bit U = Unimplemented bit, read as ‘0’
-n = Value at POR ‘1’ = Bit is set “0” = Bit is clear “X” = Bit is unknown
bit 7-6 Unimplemented: Read as ‘0’
bit 5
OSCON: Oscillator Status bit
This bit is set and cleared by hardware.
1 = The external oscillator is enabled and running
0 = The external oscillator has stopped or has been disabled
bit 4
VBAT: External Battery Switched Flag bit.
Not used in this section.
bit 3
VBATEN: External Battery Enable bit
Not used in this section.
bit 2-0 DAY<2:0>: Not used in this section.