3 ms·
Is there seriously still a commercial reason to use the ATmega328 (an 8-bit microcontroller with 2000 bytes of RAM) for new projects? I've been working on 3D pr
by Matumio 7y ago
Is there seriously still a commercial reason to use the ATmega328 (an 8-bit microcontroller with 2000 bytes of RAM) for new projects? I've been working on 3D printing firmware, and it's so easy and silly to reach the limit of this CPU. Been shaving bytes of RAM by reducing queue sizes, running into performance limits even with a few 32bit additions in the stepper loop. That was 6 years ago.
The only semi-valid reason to use this chip IMO is because people want to keep using existing firmware as-is.
- contingencies 7y agoIn fact many embedded requirements are not as complicated as a 3D printer and essentially consist of basic logic and state, sensors and effectors, potentially with some external communication. It may surprise you but 8 bit micros are absolutely fine for this and can serve HTTP at well over a hundred requests per second without breaking a sweat. If you read the Stepper code for Marlin @ https://github.com/MarlinFirmware/Marlin/blob/1.1.x/Marlin/stepper.cpp https://github.com/MarlinFirmware/Marlin/blob/1.1.x/Marlin/s... you will see it's nontrivial... bunch of PhDs implementing nontrivial maths in a highly constrained environment. That's cute but not demonstrative of real world concerns. In such cases, you would absolutely throw more hardware at the problem, eg. for motion systems maybe dedicating one 'dumb' MCU per axis and outsourcing planning to a more rational/powerful environment.
- howard941 7y agoCost and temperature. Albeit not the ATmega 328 MCUs in the even more resource constrained ATTINY series go for under $.30 in quantity and run in 125C environments https://octopart.com/search?q=avr%208%20bit&sort=median_price_1000&sort-dir=asc https://octopart.com/search?q=avr%208%20bit&sort=median_pric... . It's going in new products.
- contingencies 7y agoOnly $0.13 for 2000+ ATTINY25-20SU according to http://www.hqchip.com/search/ATTINY.html http://www.hqchip.com/search/ATTINY.html
- bsder 7y agoUm, look that up on findchips/octopart/etc. It's a buck and change on those--same as ARM Cortex M series.
- hajile 7y agoA rather small team of 10 people (with only 4-5 devs) will cost 10K per week at some generic corporation. Let's say your project takes 12 months to make on a beefy processor ($2 per unit) and 15 months on a cheap processor ($1 per unit). That extra dev time to deal with those issues directly costs 120K. That automatically means you have to be shipping at least 120K units just to break even with those costs. But you are also getting to market 3 months later which itself has huge business costs which means you probably need to be shipping 200K or more units. That's a pretty big number for a lot of embedded device designers. If you double your chip constraint from $0.13 to $0.26, then that same team must now ship a million devices to break even.
- burfog 7y agoIt sounds like something you might use for the power-on sequencing of a laptop computer. It could manage the battery and wake up the main CPU. Alone, it's the sort of thing you might use for a kid's toy that you hope to make into the next big must-have Christmas hit. You'd need to make millions upon millions of them, and maybe $49.95 is your target price.
- Raamakrishnan 7y agoThose microcontrollers for laptop power sequencing have already moved on to Cortex M4s
- bsder 7y ago> Is there seriously still a commercial reason to use the ATmega328 (an 8-bit microcontroller with 2000 bytes of RAM) for new projects? For anything commercial? Almost certainly not. For one-off makers/non-engineers? Maybe. The Arduino ecosystem is really hard to beat for non-programmers.
- ddingus 7y agoToys. The 6502 is still being used in them, as well as in many basic UX tasks. Same for many of these devices. Mature libraries, low cost, ease of use all play a part.