Saturday, May 5, 2007

Getting re-introduced to uC

Getting re-introduced I say because I was very familiar with 8085, 8086, Z80, 8031, 8047 and 8051 line of microprocessors and microcontrollers a long time ago. A recent week of painful dental surgery rendered me incapable of travelling for work and I ended up staying at home. Downtime finally after a long time ;) . I started exploring what was available in the microcontroller space and was surprised on how the field has evolved.

Microchip is by far THE leader in the space of embedded controllers thanks to an amazing community that has developed around the offering. I was used to coding in assembly language with the Intel and Zilog and had seen some of the cross assemblers but PIC Basic, HiTech and CCS compilers are a world apart.

The first microcontroller I have started exploring is PIC 16F877A. Why this specific PIC did I select? Well this was the one I was able to buy online and get in 2 days :)

One of the biggest issues for someone like myself to getting reintroduced to Microcontrollers is that the lack of tools. My prior interaction with microprocessors was when I was in school and we had a lab full of equipment with all the breadboards, power supplies, logic analyzers, digital oscilloscopes and ofcourse a well stocked bin of basic components like the resistors, capacitors, LED's, push buttons etc.

I managed to spend some time looking around Radio Shack and Fry's to find the basic components and mostly hit pay dirt at Frys. Radio Shack, I was told has got out of the components business. Kinda sad because this was the place every hobbyist used to frequent and buy from.

Another source for components is Online from places like Jameco and Digikey. The downside, you have to wait for some time to get them shipped to you. So you cannot just walk down the street and get a 10K resistor or a 100K potentiometer if you forgot you needed it when you started working on your project. This kinda leads to unfinished projects because you start, then you halt for components for a few days and then start again and then may have to stop again..

After a initial few fustrations like such, I started looking online at other options. Ebay is a good option too. Lots of electronics components at surprising prices. My advice put aside $100 and start buying all the basic components you will need. Resistors, Capacitors (electrolytic and ceramic), Diodes, LED, PCB relays, Breadboard, 5V, 12V regulators, driver transistors, multimeter (LCD), LCR meter, jumper cable set, headers (male and female), and a good soldering set.

You can get a good bit of the stuff I mentioned above to get started. Also look at Microchip site for microcontrollers. You will find everything from 4 bit to 32 bit micros there.These micros are called PIC. I was amazed at what they have been able to achieve and how easy it is now to embed a micro in to your project. There is also a ton of documentation as well as community support around the PIC.

Get a 16F628 or a 16F877a to get started. You will also need a PIC programmer that you can build yourself or you can buy from various places.

We will talk more about how to get started and what you need to get started in the next blog.