C8051F120/1/2/3/4/5/6/7
Rev. 1.2
95
7.3.2. Window Detector In Differential Mode
Figure 7.11 shows two example window comparisons for differential mode, with ADC2LT = 0x10 (+16d) and
ADC2GT = 0xFF (-1d). Notice that in Differential mode, the codes vary from -VREF to VREF*(127/128) and are
represented as 8-bit 2’s complement signed integers. In the left example, an AD2WINT interrupt will be generated if
the ADC2 conversion word (ADC2L) is within the range defined by ADC2GT and ADC2LT (if 0xFF (-1d) < ADC2
< 0x0F (16d)). In the right example, an AD2WINT interrupt will be generated if ADC2 is outside of the range
defined by ADC2GT and ADC2LT (if ADC2 < 0xFF (-1d) or ADC2 > 0x10 (+16d)).
Figure 7.11. ADC2 Window Compare Examples, Differential Mode
0x7F (127d)
0x11 (17d)
0x10 (16d)
0x0F (15d)
0x00 (0d)
0xFF (-1d)
0xFE (-2d)
0x80 (-128d)
-REF
Input Voltage
(AIN2.x - AIN2.y)
REF x (127/128)
REF x (16/128)
REF x (-1/256)
0x7F (127d)
0x11 (17d)
0x10 (16d)
0x0F (15d)
0x00 (0d)
0xFF (-1d)
0xFE (-2d)
0x80 (-128d)
-REF
Input Voltage
(AIN2.x - AIN2.y)
REF x (127/128)
REF x (16/128)
REF x (-1/256)
AD2WINT=1
AD2WINT
not affected
AD2WINT
not affected
ADC2LT
ADC2GT
AD2WINT
not affected
ADC2GT
ADC2LT
AD2WINT=1
AD2WINT=1
ADC2
ADC2
Summary of Contents for C8051F120
Page 2: ...C8051F120 1 2 3 4 5 6 7 2 Rev 1 2 Notes ...
Page 8: ...C8051F120 1 2 3 4 5 6 7 8 Rev 1 2 26 2 Flash Programming Commands 318 26 3 Debug Support 321 ...
Page 16: ...C8051F120 1 2 3 4 5 6 7 16 Rev 1 2 Notes ...
Page 48: ...C8051F120 1 2 3 4 5 6 7 48 Rev 1 2 ...
Page 98: ...C8051F120 1 2 3 4 5 6 7 98 Rev 1 2 ...
Page 106: ...C8051F120 1 2 3 4 5 6 7 106 Rev 1 2 Notes ...
Page 183: ...C8051F120 1 2 3 4 5 6 7 Rev 1 2 183 Notes ...
Page 184: ...C8051F120 1 2 3 4 5 6 7 184 Rev 1 2 ...
Page 214: ...C8051F120 1 2 3 4 5 6 7 214 Rev 1 2 Notes ...