Datasheet

123
8024A–AVR–04/08
ATmega8HVA/16HVA
22.3 Voltage Regulator Monitor
This module monitors the operating state of the Voltage Regulator. If the voltage at VFET drops
below the Regulator Short-circuit Level (RSCL), see ”Electrical Characteristics” on page 165, the
Voltage Regulator enters the Battery Pack Short mode. In this mode, VFET is disconnected from
VREG to avoid a quick drop in the voltage regulator output. When the voltage regulator enters
this mode, the chip will be completely powered by the external reservoir capacitor (CREG). This
allows the chip to operate a certain time without entering BOD reset, even if the VFET voltage is
too low for the voltage regulator to operate.
An interrupt is issued when the regulator enters Battery Pack Short mode, if the ROCWIE bit in
ROCR Register is set. This allows actions to be taken to reduce power consumption and hence
prolonging the time that CREG can be used to power the chip. In a typical short-circuit situation,
VFET will drop as a consequence of high current consumption, and recover as soon as the Bat-
tery Protection module has disabled the FETs. Hence CREG should be dimensioned so that the
chip can sustain operation without entering BOD reset, until the FETs are disabled either by HW
or SW. To minimize power consumption when the Voltage Regulator enters the Battery Pack
Short mode, the chip should enter Power-save sleep mode as soon as possible after the ROC-
WIF interrupt is detected. The Watchdog Timer should be configured to wake up the CPU after a
time that is considered safe, see appnote AVR132 for use of enhanced Watchdog Timer. Soft-
ware should then check the status of the ROC flag. If the ROCS flag is cleared, normal operation
may be resumed.
22.4 Register Description
22.4.1 ROCR – Regulator Operating Condition Register
Bit 7 – ROCS: ROC Status
This bit is set when the Voltage Regulator operates in the Battery Pack Short mode, and cleared
otherwise.
Bit 6:2 – Res: Reserved Bits
These bits are reserved bits and will always read as zero.
Bit 1 – ROCWIF: ROC Warning Interrupt Flag
The ROCWIF Flag is set within the ROCW reaction time when the Voltage Regulator enters the
Battery Pack Short mode. The flag is cleared by writing a logic one to it or by hardware, by exe-
cuting the corresponding interrupt handling vector.
Bit 0 – ROCWIE: ROC Warning Interrupt Enable
The ROCWIE bit enables interrupt caused by the Regulator Operating Condition Warning inter-
rupt flag.
Bit 7 6 5 4 3 2 1 0
(0xC8) ROCS - - - - - ROCWIF ROCWIE ROCR
Read/Write R R R R R R R/W R/W
Initial Value 0 0 0 0 0 0 0 0