Other AVR Microcontrollers On Arduino Boards

Far Inside The Arduino is aimed at users of ATmega328P and ATmega2560 microcontrollers. These include the Arduino Uno, Nano, and Mega boards. Some Arduino boards feature other AVR microcontrollers, particularly the ATmega32U4 and the ATmega4809.

The ATmega32U4 is found in the Leonardo, Micro, Yun and some other boards. This chip has a build-in USB controller which eliminates the need for a separate microcontroller, usually a 16U2, to provide the USB interface. This also allows the interface to be fairly easy to be used to emulate a keyboard or mouse to the connected computer. Functionally the part is similar to the ATmega328P. The information in Far Inside The Arduino is applicable to this part with just a small amount of changes, mostly the pinout.

The ATmega4809 is found in the Uno WiFi and the new Nano Every. This is a faster part (20MHz) with more RAM and ROM than the Uno, but a smaller EEPROM. It does not have a built-in USB controller. This part uses a single address space for RAM and ROM, eliminating the need for “hacks” to access data stored in the program ROM memory. However the peripherals have different designs such that the low level code be completely different. A special emulation layer is added so at least the GPIO (digital pins) can be compatible, but to get the full benefit from the part requires understanding the interfaces. Unfortunately the current edition of Far Inside The Arduino will be no help here. At some time in the future I intend to write an addendum covering this part.

Sadly, the ATmega4809 is far more capable than the small Uno or Nano footprint allows it to be. Roughly a dozen digital pins are not connected. Because the function of some of the pins are configurable (new feature!) things may not be quite as bad as they first appear. I need to study the part and buy a couple of Nano Every boards to work with. Because the actual ATmega4809 is only a $1 component, the Nano Every board has become the least expensive (genuine) Arduino board available, at about $10. This is bound to become a popular hobbyist board based on price alone.