English
Language : 

PXD10RM Datasheet, PDF (131/1332 Pages) Freescale Semiconductor, Inc – PXD10 Microcontroller
5.3.4 Programmable analog watchdog
5.3.4.1 Introduction
The analog watchdogs are used for determining whether the result of a channel conversion lies within a
given guarded area (as shown in Figure 5-4) specified by an upper and a lower threshold value named
THRH and THRL respectively.
Analog voltage
Upper threshold
Lower threshold
Guarded area
THRH
THRL
Figure 5-4. Guarded area
After the conversion of the selected channel, a comparison is performed between the converted value and
the threshold values. If the converted value lies outside that guarded area then corresponding threshold
violation interrupts are generated. The comparison result is stored as WDGxH and WDGxL bits in the
WTISR as explained in Table 5-4. Depending on the mask bits MSKWDGxL and MSKWDGxH in the
WTIMR, an interrupt is generated on threshold violation.
Table 5-4. Values of WDGxH and WDGxL fields
WDGxH
1
0
0
WDGxL
0
1
0
Converted data
converted data > THRH
converted data < THRL
THRL <= converted data <= THRH
The channel on which the analog watchdog is to be applied is selected by the THRCH field in the TRC
registers. The analog watchdog is enabled by setting the corresponding THREN bit in the same register.
The lower and higher threshold values for the analog watchdog are programmed using the registers
THRHLR.
For example, if channel number 3 is to be monitored with threshold values in THRHLR1, then the THRCH
field is programmed in the TRC1 register to select channel number 3.
A set of threshold registers (THRHLRx and TRCx) can be linked only to a single channel for a particular
THRCH value. If another channel is to be monitored with same threshold values, then the THRCH field
in the TRCx register has to be programmed again.
PXD10 Microcontroller Reference Manual, Rev. 1
Freescale Semiconductor
5-9
Preliminary—Subject to Change Without Notice