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.

switching the ADC10 on/off to save max power

Other Parts Discussed in Thread: MSP430G2452

Hi all,

I need to save power in an MSP430 application as much as possible. I'm using the MSP430G2452 in low power mode 4, wake it up with an external interrupt and then measure one analoge channel and switch the ADC off again. After the ISR has finished it goes back to LP4.

Problem is: before I call this function the current draw is about 1uA which is what I expect. After I've called this function below the power consumption goes up to 60uA and stays at this level, even that I explicitely switch off the ADC and the reference after the conversion. This is all served via an ISR and should go back to LP4.

If I comment out the "return 0xffff" then the power consumption stays at 1uA so it has def something to do with switching the ADC module on and off. My suspicion is that it just stays switched on and draws these 60uA.

Any ideas?

I keep debugging...

/Bernd

static inline unsigned int readADC(unsigned int channelBitmask)
{
    unsigned int result;
        // ADC10ON = ADC on
        // ADC10SHT_0 = 4 clock cycles for S/H, as fast as possible
    // REFBURST switches the REF only on during conversion
    // REF at 2.5V
// return 0xffff;
        ADC10CTL0 = ADC10SHT_0 + ADC10ON + REFON + SREF_1 + REFBURST + REF2_5V;
        // INCH_0 = input A0
        // ADC10SSEL_3 = SMCLK as ADC clock
        ADC10CTL1 = channelBitmask + ADC10SSEL_3;
        // PA.0 ADC option select
        ADC10AE0 |= 0x01;
        // Sampling and conversion start
        ADC10CTL0 |= ENC + ADC10SC;
    // wait until conversion is ready
        while (ADC10CTL1 & ADC10BUSY);
        result = ADC10MEM;
    // disable the ADC to save power
    ADC10CTL0 = 0x0000;
    return result;
}

**Attention** This is a public forum