21 January 2020

Arduino Nano has no INPUT_PULLUP on A6 and A7

I discovered it the hard way: Arduino Nano has no INPUT_PULLUP on A6 and A7. That's because the ATmega328 in tiny SMD package has two extra pins (vs. the DIP processor), which are tied directly to the A/D converter MUX without the digital I/O logic.

I discovered it once I received and assembled PCBs for a TIL311-based clock, where I used most - if not all - I/O and analog functions were left to "pure analog input" pins A6 and A7.

Well, wiring an LDR between A6 and ground lead no readings. Few measurements later, and a quick Internet search, revealed this hard truth.

Fortunately I have an easily accessible 5V point near A6, so I could throw an external pull-up resistor.