I have trouble with analog Inputs - I can´t measure rihgt value on any analog input.
I use the same sketch as for other Arduino boards like DUE, NANO, etc., but only with DUE CORE it doesn’t work.
Test code:
void setup() {
Serial.begin(9600);
analogReadResolution(12);
}
void loop() {
Serial.print (analogRead(A1));
}
Measured values:
• Input level 0V – approximately 2600 bit
• Input level ca. 0.3V-3.3V – the same value 4095 bit
• Input non connection – approximately 1300 bit
Answer to all guestions si yes.
All other functionality is OK, like blink, PWM, I2C, only function of analog Inputs is wrong.
When you say doesn't work what do you mean? If I connect voltage (0-3.3V) to analog input, output value not respond to input. For input level ca. 0.3 - 3.3V is output invariable (4095 bit).
Trouble is with all analog inputs. It seems to be anything with ground, there are two ground pins, one of them is Agnd. Both ground pins are connected and results are the same.
Command digitalRead(A1) with pin shorted to GND or to 3.3V returns "0"
Assuming it never worked, and hoping your board has not been damaged I would suggest you look at the processor ADC chapter and see if you can set the registers and read the registers without using the Arduino Macro "analogread"
I'm not positive it was this board but I read one of the newer Arduino's had an issue with a capacitor in the ADC input/circuit. At the time I didn't think it could cause your issue but you might google some more.