![Freescale Semiconductor MC9S12ZVM series Reference Manual Download Page 382](http://html1.mh-extra.com/html/freescale-semiconductor/mc9s12zvm-series/mc9s12zvm-series_reference-manual_2330602382.webp)
Chapter 10 Supply Voltage Sensor - (BATSV3)
MC9S12ZVM Family Reference Manual Rev. 1.3
382
Freescale Semiconductor
The comparator outputs BVLC and BVHC are forced to zero if the comparator is disabled (configuration
bit BSUSE is cleared). If the software disables the comparator during a high or low Voltage condition
(BVHC or BVLC active), then an additional interrupt is generated. To avoid this behavior the software
must disable the interrupt generation before disabling the comparator.
The BATS interrupt vector is named in
. Vector addresses and interrupt priorities are defined at
MCU level.
The module internal interrupt sources are combined into one module interrupt signal.
10.4.2.1
BATS Voltage Low Condition Interrupt (BVLI)
To use the Voltage Low Interrupt the Level Sensing must be enabled (BSUSE =1).
If measured when
a) V
LBI1
selected with BVLS[1:0] = 0x0
V
measure
<
V
LBI1_A
(falling edge) or V
measure
<
V
LBI1_D
(rising edge)
or when
b) V
LBI2
selected with BVLS[1:0] = 0x1 at pin VSUP
V
measure
<
V
LBI2_A
(falling edge) or V
measure
<
V
LBI2_D
(rising edge)
or when
c) V
LBI3
selected with BVLS[1:0] = 0x2
V
measure
<
V
LBI3_A
(falling edge) or V
measure
<
V
LBI3_D
(rising edge)
or when
d) V
LBI4
selected with BVLS[1:0] = 0x3
V
measure
<
V
LBI4_A
(falling edge) or V
measure
<
V
LBI4_D
(rising edge)
then BVLC is set. BVLC status bit indicates that a low voltage at pin VSUP is present. The Low Voltage
Interrupt flag (BVLIF) is set to 1 when the Voltage Low Condition (BVLC) changes state . The Interrupt
flag BVLIF can only be cleared by writing a 1. If the interrupt is enabled by bit BVLIE the module requests
an interrupt to MCU (BATI).
10.4.2.2
BATS Voltage High Condition Interrupt (BVHI)
To use the Voltage High Interrupt the Level Sensing must be enabled (BSUSE=1).
Table 10-6. BATS Interrupt Sources
Module Interrupt Source
Module Internal Interrupt Source
Local Enable
BATS Interrupt (BATI)
BATS Voltage Low Condition Interrupt (BVLI)
BVLIE = 1
BATS Voltage High Condition Interrupt (BVHI)
BVHIE = 1