Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

How does this compare to an AVR (other than being a Von Neumann computer)?


AVR's are 8-bit microcontrollers, Cortex-M's are 32-bit and are generally more powerful and have more features (even the Cortex-M0's) than both AVR's tiny and mega series.


I wonder if it's the beginning of the end 8-bit and 16-bit micro. Prices of 32-bit micros are so low now, they are so small, it just doesn't seem worth the hassle of dealing with an 8/16bit. I'm sure they'll exist in legacy designs for another 20+ years, but new designs? Less and less.


Power budget is still a big deal, and in a lot of applications is a bigger concern than the BOM parts cost.

Related: Atmel's got tiny 8-bit micros that can run off 0.7V, making it feasible to run off a single alkaline cell.


Actually 4-bit MCUs (mostly mask-programmed) are still quite popular at the extreme low end, because they're absolutely tiny (<1mm^2 bare die, in COB packaging) and cheap (<$0.01) and good enough for their application; ultracheap 4-function calculators, electric teethbrush, multifunction flashlights, toys, etc.


8 bit code takes much less space than 32bit code. You can almost pack in 2 to 4 times as much code in the same space as fixed instruction width 32bit code. Perhaps less when compared with ARM thumb but still significant.


You'd think, right? Luckily the ARM dudes came up with Thumb-2, so most (all but 6) of the Cortex-M0+ instructions are actually 16 bit, not 32. (Nice chart at http://en.wikipedia.org/wiki/ARM_Cortex-M .)

But what's even more interesting is to actually compile apps and compare code size. Miro Samek did this for a couple of RTOS-like framesworks and compared across a mix of 8, 16 and 32 bit micro architectures (PIC, 8051, M8C, 68HC08, AVR, MSP430, M16C, ARM7 Thumb, and ARM Cortex-M3 Thumb2). For his test, the MSP430 was the most dense, but Thumb2 wasn't far behind. (http://embeddedgurus.com/state-space/2009/03/insects-of-the-...)

Of course, there are 4 bit micros out there...


> ARM dudes came up with Thumb-2

I guess I'm nitpicking, but Cortex-M0+ and Cortex-M0 are basically Thumb only. The only Thumb-2 instructions implemented by these cores are the ones for barriers and transferring data between general purpose registers and special registers. These are:

1) Without an equivalent Thumb instruction

2) Required on the ARM architecture

3) A tiny, tiny percentage of instructions executed or just not used by typical application code.

Regarding the linked test, the toolchain and optimisation flags are going to make a significant difference. I wonder how GCC (which is free and probably the most popular) and armcc (which generally produces significantly better output) would fit in there.


Here's another interesting comparison of code density, in which x86 (not surprisingly?) came out ahead: http://www.researchgate.net/publication/224114307_Code_densi...


Flash memory used for program storage is much much cheaper than ram. One of the only wins that 8 bit code has over even thumb code is a faster instruction bus, but for a pipelined processor that doesn't matter anymore.

8 bit would be dead if the 32 bit parts included all of the peripherals engineers actually need to build stuff (SPI,analog,timers,etc).


There are lots of 32bit micros with all those peripherals, I think it's just that the embedded industry moves slowly and adopts new products with caution. I think it's only a matter of time before all microcontrollers are ARM and the various 8/16 bit architectures die off.


There are, but the AVR parts for example have an amazing balanced of needed peripherals that still makes those parts attractive. It Atmel replaced their AVR cores with a cortex-m0 but kept all the peripherals in place and the pinouts and the part numbering scheme the same, they would have a huge boost in market share.


AVR is so old school now and has been for years. AVR only lives on because of the hobbyist, like Arduino. Professionals have switched to Cortex M0, because of size, price, and power consumption.


Old school yes, but the hobbyist market it only a drop in the bucket. Around 1,000,000 Ardunios have been sold total. Atmel doesn't give numbers, but the 8-bit MCU market is around 6.7 billion units per year, AVR is a large share of that.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: