Arduino vs Arduino Mega – Which To Use?

You may not often have a project that pushes the limits, but sometime the regular Arduino Uno seems a bit, well, cramped. Maybe you’re having trouble finding a spare pin to connect to, or memory just seems to be short all the time. What to do? Let’s look at the pros and cons of the two devices.


Obviously, pins are the first thing you’d see. The Ardunio Uno has 20 I/O pins, while the Mega has 70. Whether you need a lot of analog pins (UNO=6 Mega=16), or digital (all pins can be digital of course on both pins). There’s ways around it of course; for example, if you need a lot of switches you can use the 4021 ICs to multiplex, using only 3 pins of either Arduino for 8/16/24/etc switches (here’s a good article on wiring that up), but if you don’t want to fuss with extra addon circuitry, the Mega is better.

Memory is different, but that’s no surprise: 32 KB flash memory (program storage), 2 KB SRAM (scratchpad/working memory), and 1 KB EEPROM (permanent variable storage), versus 256 KB flash, 8 KB SRAM, and 4 KB EEPROM.

Hardware vs Software is another area of difference. The Mega has four hardware serial ports, which means maximum speed if you need a second or third (or fourth) port. On the Uno, you can do similarly using the NewSoftSerial library; however, software is slower, and if your program is pushing the limits, you may find a hardware serial port more useful. For example, the Braille Device I’m working on benefits from a hardware serial for communication to the computer; using it, I can still use the original serial port for debugging, and another new port for communications. Being hardware, it interferes with my software loops much less.

Another difference is PWM (Pulse Width Modulation). It’s not ideal to run a motor with a varying voltage, so most controllers use PWM to fake a varied voltage. By turning the power on and off very rapidly, the average power to the motor goes up or down, changing its speed without varying the voltage (that is, except for either full on or completely off). PWM can be faked in software, but it’s extra code you don’t need to if you have the Mega, with 14 PWM pins versus the Uno’s 6 pins.

So is the Mega the be-all and end-all? Well, it’s more expensive (about double if you buy original parts; 50% higher if you shop on eBay). The chip is also soldered in place, versus a socketed chip for most Unos. This may not seem a big issue, but the memory can only handle 10,000 writes. And while 10,000 compiles/uploads may seem like a lot, once you reach it, the chip AND board is toast. With a socket, you just replace the chip.

Finally, the Mega is less common. Software on it is non-standard since most everyone works with the Uno. While the compiler takes care of many of the differences, you’re obviously working with a different device and coding for it.

Ultimately, if you’re trying to decide, I’d recommend this: Start with the Uno. There is more code, more help online, more details on how to work it. If you reach your limits (hardware, memory space, etc), move on up to the Mega. By then, however, you’ll be comfortable with the code you’re writing, and more aware of the areas that need fixing or adjusting.

SOME ITEMS YOU MIGHT ENJOY
UNO R3 MEGA328P ATMEGA16U2 Development board + USB Cable for Arduino Sweet
$6.23
End Date: Friday Jul-28-2017 20:51:29 PDT
Buy It Now for only: $6.23
Buy It Now | Add to watch list
UNO R3 Rev3 Development Board ATmega328P ATMEGA16U2 AVR USB for Arduino-27
$15.94
End Date: Thursday Jul-27-2017 17:30:12 PDT
Buy It Now for only: $15.94
Buy It Now | Add to watch list
Arduino Compatible Uno R3 ATMEGA328P ATMEGA328 ATMEGA 16U2-27
$14.99
End Date: Thursday Jul-27-2017 17:30:09 PDT
Buy It Now for only: $14.99
Buy It Now | Add to watch list


4 thoughts on “Arduino vs Arduino Mega – Which To Use?

  1. The mega has superior pin strong which make it better if have to grip assemble in darken place. Mega does not have web cam option, same problem with Uno product so not possible to have camera on it.

    Mega can run more powerful softs and run for longer time before overheat the cooler.

Leave a Reply

Your email address will not be published. Required fields are marked *