0

Working previously exclusively with Arduino devices based on ATmega328, I started looking for the alternatives with higher RAM, as 2 KB appears to be too limited as soon as the device needs to, say, grab data from a sensor, show it to a 128×64 monochrome display, and save it to an SD card.

Naturally, I found mentions of ESP32 here and there, and tried to understand the differences between ESP32 and ATmega328.

My first impression is that ESP32, while being cheaper, is also much better in every aspect except the operating temperature: –40°C to +125°C for ATmega328 versus –40°C to +85°C for ESP32 (although other sources claim its operating temperature is identical to ATmega328). Different comparisons also claim that ATmega328 is easier for beginners, but I haven't found any clear explanation of what do they mean by “beginners” and what exactly is easier.

What am I missing? What are the benefits of ATmega328 over ESP32? In other words, what would be the reason, for anyone, to choose ATmega328 instead of ESP32?

6
  • Is it actually much cheaper? I'm mean, yeah, the original Arduino boards are all not very cheap. Though the typical clones are way cheaper. And what I've seen of ESP32 boards from reputable sellers they weren't that cheap either. When buying both directly from china the boards seem to have similar costs (about 1€ per unit). Depending on if you use a dev board or only the chip the physical size might be relevant. And I previously had problems with all the pins on the ESP32, that are already in use, during boot or continuously, making them more complex to use. Thats just what comes to my head
    – chrisl
    Commented Dec 8 at 20:53
  • 1
    ATmega328 is available in a DIP that plugs into a breadboard, ESP32 does not
    – jsotola
    Commented Dec 8 at 21:05
  • ESP32 is less reliable and crashes more often
    – Bra1n
    Commented Dec 9 at 7:15
  • 1
    Sleep mode power consumption is better on the ATmega328P therefore it is better for battery powered projects which don't need WiFi and also the ADC is probably better.
    – 6v6gt
    Commented Dec 9 at 12:38
  • 1
    About m328 being easier for beginners: it has just few relatively easy to configure peripherals, but you'll notice it only when you are not using Arduino libraries or programming in assembly language. Doing the same on 2 core ARM/RiscV will be much more challenging (HW manuals for ARM chips are huge, for AVR it's all in the datasheet)
    – KIIV
    Commented 2 days ago

0

Browse other questions tagged or ask your own question.