Go Down

Topic: nano v3.0 digital pin 20 and 21 (Read 2421 times) previous topic - next topic

Jstuff

I recently purchased the Arduino Nano v3.0 and I see it has an additional two analog pins A6 and A7.  I'd like to use these as digital outputs (D20 and D21) just like I do with A0-A5 (D14 - D19).

I tried
Code: [Select]
digitalwrite(20, HIGH) but it didn't work like it does for 14 - 19.

I see this is a limitation of the Arduino IDE. Does anyone know of a way to overcome this maybe using registry values or something.

BDub

#1
Feb 15, 2010, 10:18 pm Last Edit: Feb 15, 2010, 10:25 pm by SufiBrett Reason: 1
From the ATmega328 datasheet:

Quote
ADC7:6 (TQFP and QFN/MLF Package Only)
In the TQFP and QFN/MLF package, ADC7:6 serve as analog inputs to the A/D converter.
These pins are powered from the analog supply and serve as 10-bit ADC channels.


Quote
Note that ADC pins ADC7 and ADC6 do not have digital input buffers, and therefore do not
require Digital Input Disable bits.


Unfortunately, ADC6 and ADC7 are analog input only, and do not interface with the digital input or output buffers.

Need more I/O, A/D, and another PWM?  Check out the Teensyduino:
http://www.pjrc.com/teensy/teensyduino.html

Go Up