Currently, there is a design using the comparator input in order to detect if the voltage supplied is low or not. We do not know what the real limits of our applications are, in order to detect or not low voltage condition. I would like to ask your help in order to understand how to calculate such limits.
Electrical diagram
The simplified diagram of such application is the following:
As it can be noticed, the only circuitry is a voltage divider to try to match to the ~0.55V that triggers the comparator. Tolerance of both resistors is +/- 1%. Under nominal conditions the comparator should trigger approximately at Vcc = 2.55V. The factor generated by the variation of the resistors in the voltage divider is 0.215792Vcc to 0.222638Vcc.
Current configuration of comparator
CACTL2 = 0x0A; // P2CA1 = 1: CA1 pin selected (P1.7)
// P2CA0 = 0: CA0 pin not selected (P1.6)
// CAF = 1: Comparator output is filtered
CACTL1 = 0x38; // CAON = 1: Comparator A is on
// CAREFx = 11: Diode reference selected (~0.55V)
// CAEX = 0: Comparator exchange is off
// CARSEL = 0: Vcaref is applied to + terminal
// CAIES = 0: Comparator interrupt edge select
// CAIE = 0: Comparator interrupt enable
// CAIFG = 0: Comparator interrupt flag
P1DIR.P1DIR_7 = 0; // P1.7 set as input
Reference voltages
For an initial analysis, it was considered that the microcontroller would be in a free-air temperature between 15 °C to 55 °C, so according to SLAS340J (MSP430x41x specification), the following curves were considered. This would give us a reference voltage between 0.51V and 0.57V, but some units were found out of that range (approximately 0.59V), and do not seem to follow any particular batch. The temperature is not lower than 15°C when testing the units, but we do not know the curves for minimum and maximum. The curves below only show typical scenarios. Is there a way to calculate real minimum and maximums?
Tests done
In order to discard the possibility of having an issue with the board, we have switched the microcontroller between two units, one unit which comparator threshold is within the expected range (0.51V and 0.57V) and other unit which comparator threshold is out of expected range. The behavior follows the microcontroller.