Showing posts with label AVR. Show all posts
Showing posts with label AVR. Show all posts

Wednesday, April 11, 2012

Linux on AVR

Every once in a while something comes along that changes the way you look at things. A project posted last week by Dmitry Grinberg was such a thing for me. The project in itself is already pretty strange: porting a 32-bit operating system (OS) to an 8-bit microcontroller lacking most of the features needed to actually run the OS. Why would you want to run Linux on an AVR? “Because you can”, would answer George Obama (or was it Barack Mallory?) and now also Dmitry. Yes, apparently you can (I didn’t try it myself), it only takes two hours to boot Linux on the AVR, with an effective clock speed of a dazzling 6.5 kHz. It is fun as in academic demonstration.

Yet for me this demonstration, working or not, useful or not, shows more. Emulating one platform on another more powerful platform is common practice these days, but I had never thought about doing the opposite. I think emulating a 32-bit ARM processor on an 8-bit microcontroller is actually quite a cool idea. Maybe Dmitry is not the first to have done this, I don’t know, but it is an excellent example of thinking the other way around, outside the box. The result may be useless for now, but who knows what one day may come from this?

Honestly, did you ever think of hooking up a SIMM memory module to an 8-bit MCU? I didn't, but maybe I will do so in the future.

Way to go Dmitry!

What do you think? Did you try something similar yourself? Please let me know, I would love to hear about other outside-the-box MCU projects.

Thursday, December 10, 2009

And the winner is…

Last week I did a small survey of microcontroller preferences. Although I had an idea what to expect, there were some surprises in the responses. First of all I received much more reactions than I had hoped for. I would like to say thank you very much to all of you who took the time and effort to reply to this survey! The people that posted a reply (in English!) directly to the blog will find it added to my original post. Those that sent me an email, well, I am very sorry, I am not going to add them all to this blog as there were way, way too many. However, I did spend a few hours reading all the messages and a summary follows here.
What we all want to know now is of course: who won?

But before I will tell you, you will have to read through the following advertisement.

Just joking: the winner is… AVR! Yes, the AVRs received 43% of the votes, while the PIC family lagged behind with 35%. The rest of the votes went to other families of which the MSP430 and the Propeller were mentioned quite often. 8051/2 clones are also reasonably popular.

The main reason for the AVR domination was the available tools. Although free tools exist for many microcontrollers, BASCOM for AVR was mentioned several times and also Arduino. Now this survey originated at Elektor and was read mostly by Elektor readers, so it is biased as Elektor has published quite some projects using BASCOM-AVR, but in general it was felt that the free tools (BASCOM is free only for small executables) for AVR are better than those for PIC. Also the AVR seems to be more easily available and cheaper than a PIC (even more so since Microchip restricted their sampling program), especially important outside the US and Western Europe.

In favour of the PIC was the abundant documentation, examples and free libraries. It is true that Microchip puts a lot of effort in that. On a pure technical level, some people felt that the PIC is less sensitive to noise than the AVR.

Other processors were of course mentioned, but as the survey mainly spoke about PIC and AVR, most people restricted themselves to these two families. However, as stated by several people, if the MSP430 would exist in more DIP packages (only the smallest ones are available in DIP packages), they would definitely prefer it over both PIC and AVR. Surprisingly to me the Propeller from Parallax was mentioned a few times too. Personally I think of this processor more as a sort of freak processor and I would not easily invest time and money in it. Maybe the future proves me wrong, what do I know?

Several people liked the Stellaris, now from TI, others love Freescale.

What is very clear from all the responses and which didn’t surprise me much: architectural reasons clearly do not dominate the choice of a controller family. Once people have learned to use a certain microcontroller family and have invested in tools, they are not very likely to switch to another family from another manufacturer just for the fun of it.

So, my next question is: what does it take to make you switch to a competing microcontroller?

Wednesday, November 25, 2009

Are you a PIC fanatic or an AVR lover?

Twenty years ago life was easy. Nobody really used the term embedded yet and there were only a few microprocessors to choose from. The choice was roughly limited to Intel’s 8051, the 6809 from Motorola, MOS Technology’s 6502, the Z80 by Zilog and maybe the H8 from Hitachi. These were all 8 bit processors. Personally I was a fan of the 6502 and I did not like the 8051. As a hobbyist building a computer system was rather a challenge because of the complicated board design due to the external memory and peripherals, but soldering was easy.
The integration of memory and peripherals into the chip turned the microprocessor into a microcontroller and made board design much simpler. The PIC that was introduced by Microchip somewhere in the early nineties was simple, some had EPROM on-board, and was cheap and easy to come by, which made it a good choice for hobbyists. The AVR introduced by Atmel a bit later was one of the first to include flash program memory which made it a good choice for hobbyists too.
Nowadays embedded has become a buzz word thanks to the thousands of different microcontrollers on the market. 8 bit, 16 bit, 24 bit, 32 bit, you name it, and it can be had. Some of the oldies are still around, like the 8051 in many incarnations, or the Z80 (by Rabbit Semiconductor). They are now faster of course and come with more options, but they are essentially the same as 20 years ago. Today building a microcontroller system is easy and within reach of most hobbyists, although the soldering has become somewhat more difficult.
Choosing a microcontroller on the other hand has become complicated. If we stick to the hobbyists we see two large user groups: PIC users and AVR users. Of course lots of hobbyists use other controllers, but these two families are probably the most popular. Now which family do you use? Are you a PIC fanatic or an AVR lover? Both families have flash memory and free development tools, both are cheap and easy to get. So how did you get into AVR or PIC? I have not been able to choose between the two, maybe you can help me? You can post your comments on this blog.