I seem to be have a problem reading the ADC input on PB12.
I am initialising the ADC as follows:
External_ADC.pin_num = 2;
External_ADC.dir = RUI_GPIO_PIN_DIR_INPUT;
External_ADC.pull = RUI_GPIO_PIN_NOPULL;
Readings are taken by :
RUI_LOG_PRINTF(“ADC Sample: %d\r\n”,wTempReading);
However, I seem to get readings in the 2200 +/- a few counts range regardless of the voltage applied to pin 26 on J22 (PB12).
Has anyone had any success on reading the ADC from PB12?