This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSP430FR5970: MSP430 ADC Pin Configuration

Part Number: MSP430FR5970

Tool/software:

Hi,

I'm planning to monitor 12V, 3.3V, and 1.8V, which I'm connecting to ADC pins using a resistor divider and considering VREF = 1.5V.
So for 12V, R1 = 69.8Kohm, R2 = 10Kohm (A0).
For 3.3V, R1 = 5Kohm and R2 = 10Kohm (A1).
This both will voltage divide it into 1.5V reference to ADC pins. How the voltage monitoring actually happened based on this reference voltage? Both the A0 and A1 are fed with 1.5 reference; how is the MCU differentiating the 12V and 3.3V? Also, if the source input voltage reduces, for example, if 12V comes to 11.8V, how will the MCU read it?

Regards,
Anoop

  • Hi Anoop,

    Sorry, I'm a little confused about your questions. If you want to know how to distinguish between different input channels' voltages, you can refer to the User's Guide chapter 34, ADC12_B, as shown in the figure below. You can see that it can select different input channels through multiplexing and then select the corresponding voltage to enter the 12-bit ADC Core for comparison, and then set the result to be saved in different ADC12MEMx registers, which can be freely configured by your program. For related registers configuration, you can refer to the provided example code and  MSP430FR5970_UserGuide.

    And if you want to understand the underlying principle of ADC, such as how it compares voltages through a reference voltage, there are actually many technical documents available online about like SAR ADC. I recommend that you can learn from these by the online resources.

    Best Regards,
    Peter

  • Simply, the ADC has a number of counts, for example lets say 255. The reference voltage represents the count of 255.

    If your voltage divider supplies a voltage of half the reference voltage, you will get a count of 127 or so. If that voltage changes to 3/4's of vref you should get a count of 191 counts, and so on.

    So it all comes down to the voltage dividers and the voltage supplied to them which will get you a fraction of the reference voltage.

**Attention** This is a public forum