STMicroelectronics FlexSPIN: SPI configurable stepper and DC multi motor driver evaluation board EVAL6460 EVAL6460 Data Sheet

Product codes
EVAL6460
Page of 139
L6460 
Digital comparator
Doc ID 17713 Rev 1
93/139
   
   
   
21 Digital 
comparator
L6460 includes one digital comparator that can be used to signal, through serial interface, 
that a channel converted by the ADC is greater, greater-equal, lesser, lesser equal, or equal 
than a fixed value set by serial interface or than the value converted by the other ADC 
channel.
This circuit can be used to monitor the temperature of the IC advising the firmware when it 
reaches a certain value decided by the firmware by setting one ADC channel to do 
continuous conversions of the temperature sensor. 
The circuit operation can be enabled or disabled changing the EnDigCmp bit in the 
configuration register DigCmpCfg. By setting the DigCmpUpdate[1:0] bits in the 
configuration register, the comparator can be programmed to update its output in one of the 
following ways:
DigCmpUpdate[1:0]=00
Continuously (each clock). 
DigCmpUpdate[1:0]=01
Each time a conversion is performed on ADC channel 0.
DigCmpUpdate[1:0]=10
Each time a conversion is performed on ADC channel 1.
DigCmpUpdate[1:0]=11
ADC state machine driven.
When the last option is selected, the digital comparator will update its output in two different 
ways depending on the configuration of the ADC converter. If ADC converter is configured to 
do continuous conversions on both channels, the output of the comparator will be updated 
when the double conversion is completed. If ADC converter is not configured to do 
continuous conversions on both channels, the output of the comparator will be updated each 
time a conversion is completed.
The comparator output can be digitally filtered so that the programmed condition has to be 
found for three consecutive checks before to be signaled.
Th
 shows the block diagram of digital comparator.