JAJU857 December 2022
The MSP430F5132 internal ADC polls a filtered signal.
When a voltage greater than DC trip threshold is detected, the MSP430 enters a monitor mode. The highest and lowest readings determine whether a DC fault or AC fault has occurred. While in monitor mode, the highest and lowest values are saved over a detection window greater than 10 ms. The detection window needs to be more than 10 ms to make sure 0 V is detected if an AC fault occurs.
The code sequence is as follows:
If the lowest ADC reading is greater than the DC trip threshold, a DC fault occurred and the system trips the relay.
If the lowest ADC reading is zero, and the highest reading is greater than the AC trip threshold, an AC fault occurred and the system trips the relay.
This is how the software differentiates between the two fault types. The software must differentiate AC versus DC because the trip thresholds are different for each.