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.

MSP430f5529lp ADC doesn't work

Other Parts Discussed in Thread: MSP430WARE

Hi,

I am using ccs example project "MSP430F55xx_adc_01.c" where a single sample is made on channel A0 .

The problem is that the register ADC12SC (start conversion) always set to zero, though the following command is set:

ADC12CTL0 |= ADC12SC

So, I read no sample from ADC12MEM0....

Also, when I gave 3.3V with 5 Ohm resistor to A0, the MSP430 rebooted.

Could you please help with the issue?

How can I sample an analog signal wich output range is: 0 -3.3V?

Thanks,

Ekaterina

 

 

  • Ekaterina Shyshchenko said:
    I am using ccs example project "MSP430F55xx_adc_01.c" where a single sample is made on channel A0 .

    From which version of MSP430Ware? What device are you using?

    This example is designed for a MSP430F552x device. It may require some tweaking to work with other 5xx devices.

    Ekaterina Shyshchenko said:

    The problem is that the register ADC12SC (start conversion) always set to zero, though the following command is set:

    ADC12CTL0 |= ADC12SC

    I'm sure you meant that the bit ADC12SC is always clear, since there is no register named ADC12SC. Regardless, Table 28-4 in the User's Guide states that this bit is reset automatically after being set. So you should not presume to be able to ever read back that bit being set.

    Ekaterina Shyshchenko said:
    Also, when I gave 3.3V with 5 Ohm resistor to A0, the MSP430 rebooted.

    Not sure about this, especially without know what the target device and board are. What is AVcc connected to? The example doesn't set any bits for reference voltage, so if you have a device with REF module, you may need to make some changes.

  • I am using MSP -EXP430F5529lp if to be more specific...

    And yes,I have meant a bit ADC12SC, ( at the ADC12CTL0 register).

    I have tried to play with the references at ADC10MCTL0 Register. I have set a Vref+ as Avcc

    But still, I can't read any sample from ADC12MEM0, it's always clear, even with the example at ccs.

  • Ekaterina Shyshchenko said:
    The problem is that the register ADC12SC (start conversion) always set to zero

    How do you know?

    When looking at it with a debugger (e.g. single-stepping), the ADC has done the conversion long before the debugger reads the register. And the bit has been cleared again. The debugger only stops the CPU but not the ADC.

    Ekaterina Shyshchenko said:
    Also, when I gave 3.3V with 5 Ohm resistor to A0, the MSP430 rebooted.

    Where do the 3.3V come from? Possibly an ESD problem or something like that.

**Attention** This is a public forum