Picking the Right Arduino
My introduction to the Arduino happened when there were two options: the Duemilanove and the Mega. The only decision involved the number of…
My introduction to the Arduino happened when there were two options: the Duemilanove and the Mega. The only decision involved the number of I/O pins. Almost ten years later, there is an Arduino board type for (practically) every application or project. The choice can be overwhelming when selecting. Here are some considerations for the major types.
What Is Arduino?
Arduino is an open source hardware platform. There are two elements to the name: the boards and the software. Only boards from Arduino.cc can officially be called an “Arduino.” (The name is trademarked.) From an open source perspective, as Arduino grew in popularity the Software, or Integrated Development Environment (IDE), has been expanded to support many other boards. These devices are more correctly called “Arduino compatibles.”
int digitalRead(uint8_t pin) { uint8_t timer = digitalPinToTimer(pin); uint8_t bit = digitalPinToBitMask(pin); uint8_t port = digitalPinToPort(pin);
if (port == NOT_A_PIN) return LOW; if (timer != NOT_ON_TIMER) turnOffPWM(timer); if (*portInputRegister(port) & bit) return HIGH;
return LOW; }
On the software side, there is the “core” and the “IDE.” The core is a C++ library called the “Arduino core,” which is unique for each processor type. This (extensive) library allows common functions like digitalRead()
or digitalWrite()
to work on so many different architectures. The IDE is a cross-platform application that provides a clear starting point for all things Arduino.
On the hardware side, it is difficult to summarize ALL possible variations succinctly. So the focus here is on these popular styles: Uno, Mega, ESP8266, Zero, and MKR. Even within these, there are variants, some of which I mention below. First, let’s look at a specification based decision.
8-Bit vs. 32-Bit War Continues
Unlike early video game consoles, picking a processor is not as simple as the bit number. In general, 8-bit processors offer basic capabilities while consuming lower power. The simpler architectures mean directly programming registers tend to be relatively easy. 32-bit processors offer higher clock speeds along with more RAM, ROM, and serial peripherals. Their architectures could make programming more complicated. Fortunately, frameworks like the Arduino library and CircuitPython hide much of that complexity.
Choosing a microprocessor just because it is 8-bit or 32-bit can be short-sighted. So it is essential to think about how you plan to use it.
8-Bit: Uno, Nano, and Mega
The Uno is the favored starting point for Arduino projects. It has a distinctive shape with a pseudo-standard header pinout. Its CPU is Microchip’s ATmega328P. This processor’s most overlooked specification is the 2,048 bytes of RAM. The Uno is a lousy choice if you are thinking about sending, receiving, or processing strings. Outside of strings, you would be surprised what you can do with so little, especially given the number of GPIO available.
NanoIf the Uno is too large, consider the Nano. It’s the most copied, or cloned, Arduino variant. It is the same processor as the Uno, but the board is a slimmed down form factor. The direct software capability means you can prototype with an Uno and install a Nano in your final project.
MegaIf the Uno (or Nano) do not offer enough I/O or RAM, boards based on the ATmega2560 are an option. The Mega-boards are exceptionally popular in motor control applications, like 3D printers. While their cores are common, compared to the ATmega328p, the ATmega2560 has more timers, a second ADC, additional hardware UARTs, and a ton more I/O pins. However, it is still an 8-bit processor like the Uno.
USB with 32U4Another variation of the Uno is the Leonardo or Micro. These boards use the ATmega32U4 chip. Unlike the other 8-bit boards mentioned here, the processor has a built-in USB interface. This feature makes it very simple to create USB keyboards, mice, and joysticks. A popular compatible board is the Teensy LC from PRJC. It is the same 32U4 but in a teensy-sized form factor.
32-Bit
Side note: I am referring to 32-bit microcontrollers which are not running an operating system. So I am not comparing Arduino to Raspberry Pi or BeagleBone-like boards.
Arduino ZeroThe Arduino Zero contains a 32-bit Microchip SAM D21, which is built around an Arm Cortex-M0+. The board shares the same pinout and form factor as the Uno, yet the processor is entirely different.
In general, the 8-bit boards are based on a 5 volt rail while the 32-bit boards are based on a 3.3 volt rail. It is important to know that most 3.3 volt processors cannot tolerate 5 volt signals. So you may need to use level-shifters when interfacing between the two voltage levels.
The most striking feature of the M0+ boards is the incredibly flexible serial interfaces. While the boards define I²C and SPI pins, the chip itself is highly configurable. It supports multiple types of serial interfaces on multiple I/O pins.
Like its 8-bit cousin, the Zero comes in smaller form factors.
MKR SeriesThe Arduino MKR series includes boards such as the MKR ZERO, MKR GSM 1400, MKR FOX 1200, and the MKR WiFi 1010. The form factor of the boards in the MKR series is similar. Their I/O pins run down the sides, the form factor is slimmed down, and they all contain a LiPo battery connector with charger circuit.
The MKR Zero includes the same processor as the Zero. In addition to the slimmer form factor and LiPo charger, the MKR Zero adds a MicroSD card slot.
One other board to mention is the MKR WiFi 1010. This board is relatively new and contains a chip dedicated to crypto communication. The other exciting feature of the MKR1010 is its processor(s) choice. Onboard there is the same SAMD21 found on the Zero. However, the WiFi module from u-blox includes an ESP32. It is two processors in one.
Lastly, there are shields designed for the MKR form factor. They add serial busses like RS-485 and CAN, among other features.
ESP8266 and ESP32When the ESP8266 hit the market, it changed how projects incorporate WiFi. This system on a chip is a 32-bit microcontroller running at 80 MHz with a chip dedicated to WiFi operation. Which means, it runs the full TCP/IP stack separate from the microcontroller running your code.
ESP modules contain a full microcontroller in their SoC package. The core Arduino library has been ported to the ESP12 and ESP32, meaning in some cases code for an Uno compiles for the ESP12 without any changes!
The picture above shows 4 different ESP options. A barebones ESP8266, Adafruit’s Huzzah ESP8266, an Adafruit Feather ESP32, and a ESP8266 NodeMCU. The barebones board was popular because of cost, but it requires extra components to be useful. The Huzzah ESP8266 adds some of those parts and breaks out more of the I/O pins. However, it still requires a serial-to-USB adapter.
Adafruit’s Feather form factor adds serial-to-USB and a LiPo charger to the ESP8266 or ESP32. It makes working with the ESP very easy. You might notice the Feather looks like the MKR. Sadly, while they are visually similar, they are different sizes and do not have a common pinout.
Lastly is the NodeMCU form factor which is not a form factor! NodeMCU is a firmware that runs a Lua script interpreter on the ESP8266. It can be replaced with an Arduino bootloader. Once replaced, you can program the board with the Arduino IDE.
When you need to add WiFi to a project, ESP-based boards are an excellent starting point.
Which Arduino Is the Best?
You might still be wondering: which one of these boards is the best Arduino?
As you can see, each of these different boards has some advantages for different situations. The question “which Arduino board is best” is not a complete question. You need to fill in the question with “… for my application or project.”
While it is not possible to cover every board type and variant, this information should give you enough context to consider a board for your project. If not, leave a response and let’s find the best Arduino (or Arduino-compatible) for you.