Other Parts Discussed in Thread: SYSCONFIG
Hi Team!
I'm trying to use an external reference of 2 V with the VREF module and ADC. I'm using example code adc12_single_conversion_vref_external as the starting point.
Software setup:
1) Sysconfig has not be modified:
Vref pin: PA23
ADC0 pin: PA25
Hardware setup:
1) Removed JP4 jumper
2) Removed JP1 jumper
3) Connected 2V into PA23 on Boostpack header J2
4) Connected 1V into PA25 on Boostpack header J1.
I've scoped both inputs to double check there are 2 V coming into the Vref line and 1 V coming into the ADC0 line shown below.
However, both adcresult, and the ADC0_SVT_FIFODATA registers are not reading 1 V.
With 12-bits: the reading should be (1/2)*2^12 = 2048.
I'm not sure if there is a setting in sysconfig or the hardware that is causing the ADC result to be skewed?