Part Number:MSP430F5342
Hi.
I'd like to measure voltage on P5.1 (ADC A9) on MSP430F5342 with internal 2.5V reference. Power supply for uP is > 2,8V.
Measurement is always wrong and never stable. When I measure on other channels (A0, A1, ...), measurement is OK.
Is it possible that channel A9 can't be use to measure voltage with internal 2.5V reference?
In MSP430F5342 data sheet there are two option for A9 pin: A9/VeREF- and A9/VREF-. Maybe is there a problem...
Thanks for any suggestions and comments.
Here are my register setup:
P5SEL |= BIT1; REFCTL0 &= ~REFMSTR; ADC12CTL0 = ADC12SHT02 + ADC12ON + ADC12REFON + ADC12REF2_5V; ADC12CTL1 = ADC12SHP; ADC12MCTL0 = ADC12SREF_1 + ADC12INCH_9; ADC12IE = 0x01; __delay_cycles(5000); // Vref settle ADC12CTL0 |= ADC12ENC; __bis_SR_register(LPM3_bits + GIE); // LPM3, ADC12_ISR will force exit __no_operation(); // Interrupt rutine #pragma vector = ADC12_VECTOR
__interrupt void ADC12_ISR(void)
{ ADC12IFG &= ~0x01; }