Instructables
It used to be that the number of different microcontroller chips available to the hobbyist was pretty limited. You got to use whatever you could manage to buy from the mail-order chip dealer, and that narrowed down the choice to a small number of chips.

But times have changed. Digikey lists over 16000 different line items under a 'microcontroller' search. Which one should a hobbyist with no particular prior experience choose?

Here are some hints. These are particularly aimed at someone trying to pick a microcontroller to use for the first time at least partially as a learning experience, rather than someone who wants to accomplish a particular task.

Update 2009-01-28: This Instructable was recently mentioned in some popular blogs, and is getting a bunch of new readers. Be sure to read the 'comments' made by other readers and the responses to them; there's a lot of value in those comments...
 
Remove these adsRemove these ads by Signing Up

Step 1: What IS a "Microcontroller" ?

If you ever took a very introductory computer course, you probably learned about the major components of ANY computer:

  • A Central Processing Unit or CPU. The part that actually performs logic and math
  • Memory. Where the computer stores data and instructions
  • Input and Output or I/O. How the computer moves data between its other components and the real world.

A microprocessor uses microelectronic fabrication techniques to shrink the CPU to a very small size; usually a single "chip."

A microcontroller uses the same techniques to shrink the entire computer to a single chip (or very small module.) CPU, Memory, and I/O all in a little package as small as a grain of rice. Just connect up power and it starts doing its thing; computing and talking to the world. Usually the I/O on a microcontroller is aimed at "low level" hardware like talking to individual switches and LEDs instead of keyboards, internets, and displays (like your desktop computer.) A microcontroller is just the thing you want, if you want to talk to individual switches and LEDs...

1-40 of 186Next »
monna1 year ago
nice article but i am still confused wat to choose microcontroller or microprocessor???
I am a final year student working on my FYP project, which contains 9 resistive type sensors, 5 contact sensors and 2 accelemeter or Gyro.also i have to use a display to show output and Speaker with text to speech converter. now wat should i use??? microcontroller or microprocessor???
westfw (author)  monna1 year ago
The original article is getting a bit old, but...
OK. It sounds like you need 9 A-D channels with relatively slow sample rates, 5 digital inputs, I2C or SPI for the Accel/gyro, some sort of display interface (which can range from one pin with an external intelligent display of some kind, to "many" pins dedicated to AMLCD displays), and your text-to-speech (are you using an external text-to-speech module, or do you want your project to generate audio directly?)
This is enough 'stuff' that you can immediately eliminate some candidates; an Arduino Uno, or the microcontroller it uses, is probably not enough, for example.
The "microprocessor" vs "microcontroller" issue is usually determined by memory use, and you don't say anything about what your software needs to do or how big you expect it to be. You can get microprocessor systems with megabytes to gigabytes of RAM, while it's a rare microcontroller than has more than 64k.
A big question is "chips or module" - A beaglebone will probably do everything you need, if you're "allowed" to use a pre-built system like that (with some added stuff for specific sensors, plus software.) OTOH, a Beaglebone is probably above the complexity of what you would be expected to build for this class of project.
IstvánS westfw17 days ago

Wow, answering that ... your self control must be amazing; hats off!

monna westfw1 year ago
can i get your email id so that i can give u full description ....plz
mohdsharukh5 months ago

i am working on a project in which i need to to produce an interface b/w 2 usp ports for data transfer.plz suggest which micro controller will meet me requirements

westfw (author)  mohdsharukh5 months ago

Insufficient information. Insufficient spelling. I assume you mean 2 USB "things", since USB is more of a network connection, and you don't actually transfer data "between two USB ports." It becomes highly dependent on what types of "things."

An FTDI VNC2 microcontroller will probably do it, but it may not be the easiest solution. And it's sorta weird in several ways.

ahmedebeed5556 months ago

Thank you for the information and code of ethics. Here are some extra information about getting free samples.

http://www.ladyada.net/library/procure/samples.htm...

My blog

http://embedded-egypt.blogspot.com/

boardsmm8 months ago
HAPPY BIRTHDAY article - you turn 7 years old today! ;-)
What a great write up this is - but/and may I humbly suggest a revision? I'm guessing quite a few things have happened in 7 years. For instance, the Arduino mention probably deserves some more prominence to name one thing.
Again, thank you!
<:-)
shivani36311 months ago
which microcontroller should i use if i want to store some images captured by a camera which is to be interfaced with the microcontroller itself!!
westfw (author)  shivani36311 months ago
This instructable offers a set of guidelines for choosing a microcontroller, it can't (and *I* can't) recommend a particular micro for every application that comes along... That said, any sort of image processing usually moves into the realm of needing multiple megabytes of memory, rather than the "several kbytes" that you see on most microcontrollers. That probably means that you'd be best off with one of the newer "single board computers" like Raspberry Pi or BeagleBone. (In fact, there is/was a BeagleBoard variant LeopardBoard specifically designed for experimenting with various camera modules.  It's a bit old and expensive by RPi standards, but not horribly so...)
(removed by author or community request)
No, the hex file contains the "raw machine code", which is very processor and even chip specific. For example, an AVR hex file for the the atmega8 will probably NOT work on an ATmega328, even though they are both 28-pin AVR chips.
melissasue1 year ago
We were discussing this very topic on the Digi-Key TechXchange forums the other day: http://www.digikey.com/techxchange/thread/4280. If you need help selecting a microcontroller for a specific project, the folks there are a big help!
r0b0t12 years ago
I'm not sure if anyone will read this instructable, or this comment, any time soon... But I must warn you. Stay away from Zilog. To put it nicely, actually *using* their chips is... not easy.

I've tried to diagnose the problem, but their help desk is no help and by this time (2012) they haven't updated most of their line. It is sad, because a lot of the chips actually have fairly nice features (high drive IO pins, to name one that is hard to find, and a good amount of timers, something I've only seen on SiLabs 8051s) but are impossible to use off of the development boards.

If anyone has solved these problems... I've got some ZNEO motor control µCs laying around I still want to use. Help!
ebidk5 years ago
Very nice instructable :)

You could also add http://maxim-ic.com to the free sample list, they have some nice things like DS80C390 and DS80C400 :)
seefriek ebidk2 years ago
These are 8051 core processors, and are very nice.
denilsonsa2 years ago
After doing a very small project using PIC16F870 and doing a big project using ATmega8, I've written a comparison between AVR and PIC on my blog:

http://my.opera.com/CrazyTerabyte/blog/2011/09/08/comparison-between-microchip-pic-and-atmel-avr-microcontrollers

I hope it's useful for other people as well.

TL;DR: In my opinion, AVR is better than PIC.
akusumakar3 years ago
go for p89v51rd2 make a simple development board interfacing max232, it is d best
I've use ST ARM module. STM32VL Discover kit very Succesfull. http://www.signal.com.tr/arananurun.php?urun=STM32VLDISCOVER&&id=129339
STM32VLDISCOVER.jpg
What about the STM32F103 series? Not so hobbist-friendly because they don't have DIP packages, but they seem to be very reasonably priced (cents more than 8-bit atmega48v) and a performance beast, having 32-bit ARM cores and reaching 72 MHz. I have no idea if are there free IDEs and cheap ways of "burning" the mcus, though. Anyone ever had any experience with them?
VIRON7 years ago
8031 and 8032 is cheap, can be pulled as a 8051/8052 and bootstrapped from 64K each of RAM and ROM, if you have an eprom programmer. Eproms are cheap nowadays and I once built my own eprom programmers and was able to erase them on a fluorescent "blacklight" tube overnight, when I was REALLY unable to afford new equipment. Every non-USB keyboard probably has an 8048 chip, which may be EPROM compatible, but with limited external memory and different instructions, and has been around since the days of ATARI 2600. MicroProcessor mode systems just require extra wiring for address and data buses and separate i/o and memory but are otherwise doing the same things as MicroControllers. The chips I just mentioned have both modes. Many others do too. The art of emulating unsupported i/o is called bit-banging, which is easy for serial (except USB, ethernet, and other monsters), challenging for video, and annoying are those monsters which have wasteful complex protocol overheads that drive me nuts and slow everything down.
C.D33 VIRON3 years ago
Entertaining, VIRON. I just happen to have an extra keyboard lying around. Could you direct me on how to build an EPROM programmer- the circuit side? This question almost 4 years later.
westfw (author)  C.D333 years ago
You understand that you need the microcontroller from the keyboard (that "maybe" is the correct type), PLUS an EPROM (and maybe RAM) chip that you have to buy, plus a couple of "glue" chips and a couple dozen wires or a PCB to connect it all. It's sort of an entertaining exercise if you've harvested the components from trash, and the alternative is $30 "new" chips (that still need those extra components), but that has long since ceased to be the case. Even if you were to want to experiment with the older architectures, the cost for a flash version of the 8052 (new) is about $2 (http://search.digikey.com/scripts/DkSearch/dksus.dll?Detail&name=AT89S52-24PU-ND )
panic mode3 years ago
very nice article and fair review,
i've been using PIC AVR Zilog and now Rabbit
tokomikon3 years ago
I use ARM microcontroller.


Regards,
Dave T.
ATmega8535 | ATmega16 | ATmega32 | AVR USB ISP Seller
shaggs313 years ago
Thanks for the info. I really like free stuff!
Goddard0073 years ago
Thanks for all the information. It really helped me out.
jastreich5 years ago
You mention Parallax;s Basic Stamp, but you missed their coolest and most useful two MCUs. The SX and Propeller. The SX is sort of in the Basic Stamp family, but it runs assembly and I think it is a RISC chip. They are cheap, easy to program and are less "hobby" than the Basic Stamps or Javalin chips. The Propeller can run Assembly natively or interpret Spin out of the box, it has 32 general purpose I/O lines which are accessible on all 8 Arithmetic Logic Units (cores they refer to as "cogs").
westfw (author)  jastreich5 years ago
There is a SX-based Stamp, IIRC. Otherwise, I'd describe the SX and Propeller as being sufficiently "far from mainstream" as to not be good choices for a beginner...
I'd agree, while I love the propeller IDE and programming language, it is totally importable across architectures, as nothing else uses their proprietary spin code. However, they now have a C compiler for the Propeller, so it may not be as bad a choice for a beginner as it used to be.
I would like to see a start to finish tutorial on recovering parts from old boards, reading the data sheets and learning what the individual chips are capable of doing. I have hundreds of chips from Motorola to Toshiba sitting around that i removed from electronic boards. It would be nice to know where to start to use this stuff.
WVvan4 years ago
This is instructable is just what the doctor ordered. I want to get into microcontrollers and spent several hours reading piecemeal accounts trying to gather enough information before I found this most excellent write up. I should have know that Instructables was the place to start.

FYI - this link is broken: "Trip report to an Early TI seminar"

Double Plus Good.
westfw (author)  WVvan4 years ago
Thanks!  Broken link fixed (geocities went away...)

RIP geocities
You will be missed T_T
WVvan duct tape4 years ago
Another bad link.
Step 10.
Device list at AVR Freaks
westfw (author)  WVvan4 years ago
honestly, this instructable was mostly about relatively SMALL microcontrollers, where most of the electronics of the entire project is in the single chip. Your project sounds more complex than that (and not at all an ideal introduction to microcontrollers or hardware in general for a person with your background.)

You could look at the modules that claim to run JAVA or JAVA-like programs, for example: http://www.systronix.com/store/tini.html
Or linux/android Single-board computers (Beagleboard ?)
Or even a conventional laptop or DC-powered PC-class machine, perhaps with things like Arduinos to use for real-world interfacing...

double post :)
westfw (author)  duct tape4 years ago
Huh. It WASN'T, it had different text. Honest...
Anyway: that link isn't bad, it's just (now) an empty page (with a referral to a relevant page at Atmel.) There are hints that it might come back, so I want to leave the link here alone...
Ok, I am so confused, I have been looking around for the better part of a day now trying to make sense of this all. You see, where I work we are converting a gas powered go-kart to run on hydrogen, and to manage the fuel system, which is quite complex actually, consisting of several different stages of fuel, we needed to code our own fuel system controller. To do this, one of the other people working on the project was going to use one of the Renesas M16C microcontrollers to do this, but he moved, and now, as the only one on the team with any programming experience, the job has fallen to me. Now granted, I am an amateur Android developer, but the way things are done with these microcontrollers is truly baffling to me. So basically, my boss has said that we can get whatever other controller we need for the project, but it needs to be done fairly quickly. What microcontroller or any other type of product can I use to accomplish this task in a timely manner, going from average Java knowledge, minimal C++ knowledge, and no microcontroller/computer hardware design knowledge? I know this topic is old, but I didn't know where else to ask. Thank you so much!
westfw (author)  thegoogleist4 years ago
honestly, this instructable was mostly about relatively SMALL microcontrollers, where most of the electronics of the entire project is in the single chip. Your project sounds more complex than that (and not at all an ideal introduction to microcontrollers or hardware in general for a person with your background.)

You could look at the modules that claim to run JAVA or JAVA-like programs, for example: http://www.systronix.com/store/tini.html
Or linux/android Single-board computers (Beagleboard ?)
Or even a conventional laptop or DC-powered PC-class machine, perhaps with things like Arduinos to use for real-world interfacing...

1-40 of 186Next »