[SOLVED] Arduino Zero returns 10-bit integers when reading ADC. No 12 bit?

This has been bothering me for a bit. I was really looking forward to the improved resolution of the ATSAMD21 ADC. However, in the current version, I only get a 10-bit number back (maximum read is 1023).

Shouldn't this get fixed ASAP? Shouldn't be too hard for the developers, its quite a waste of resources on this amazing MCU!

Thanks in advance,

Nick

There is a note on the Due page:

Analog Inputs: pins from A0 to A11
The Due has 12 analog inputs, each of which can provide 12 bits of resolution (i.e. 4096 different values). By default, the resolution of the readings is set at 10 bits, for compatibility with other Arduino boards. It is possible to change the resolution of the ADC with analogReadResolution(). The Due’s analog inputs pins measure from ground to a maximum value of 3.3V. Applying more than 3.3V on the Due’s pins will damage the SAM3X chip. The analogReference() function is ignored on the Due.

The same might apply to the Zero. So, do you call analogReadResolution()?

RTFM ! :smiley:
--> https://www.arduino.cc/en/Guide/ArduinoZero#toc5

PaulS:
There is a note on the Due page:
The same might apply to the Zero. So, do you call analogReadResolution()?

Dirk67:
RTFM ! :smiley:
--> https://www.arduino.cc/en/Guide/ArduinoZero#toc5

Oh my god! How did I not know about this? That fixes all problems. Thanks!