Types of microcontrollers:
There are a dozen different vendors who manufacture microcontrollers. Few among them are Intel (8051), Atmel (AVR), Microchip Technology (PIC), Hitachi, Motorola etc. We will discuss about two such microcontrollers which have created waves recently; AVR and PIC.
AVR
Developed by Atmel, AVR is based on a modified Harvard architecture RISC single chip microcontroller. AVR is not an acronym and does not stand for anything and is just a name given to their RISC architecture based microcontrollers.
AVR family of microcontrollers is coherent and easy to understand and its architecture is especially suitable for C compiler. GCC, a variation of C is ported to support AVR target processor and is widely known as AVR-GCC. It does not mean that it there is no support for Assembly. Geeks here can very well take advantage of Assembly language and its low level control. BASIC is also supported for a few interested.
PIC
This is again a Harvard architecture based microcontroller popular in both industrial developers and hobbyists. PIC stands for “Peripheral Interface Controller”. This variation of microcontroller supports C, Assembly and also BASIC.
AVR vs. PIC
In the robotic world, this is always a heated discussion. Some like AVR while others like PIC. Although I personally prefer AVR, PIC has its own followers. Without getting into the fight, I will highlight the reasons why I prefer AVR. Once you are familiar with any one type of microcontroller, it is easier to understand and shift to other microcontrollers. (Of course if you are ready to go through the learning curve again)
Languages:
Assembly: Both PIC and AVR support assembly language and provide free assemblers; MPLab for PIC, and AVRTools for AVR, under Windows. You can also find assemblers for *nix versions. However due to its peculiar architecture, writing Assembly on a PIC is tricky.
C: This fast and lightweight language is supported by both microcontrollers. AVR supports C and Atmel provides a free high quality compiler and completely cross platform. On the other side, although PIC supports C, the compiler they provide is not free. There is a student version available which is free, but has its own limitations; No frequent updates; Limited code optimization etc. This is where AVR scores and has been the choice of many hobbyists (including me) for selecting AVR based compilers and microcontrollers.
BASIC: Who uses BASIC? Not me. If someone is still interested, there are compilers available for both PIC and BASIC.
IDE (Integrated development environment): IDE’s help a developer to speed the development, debugging and compiling with few other features like simulation. On the IDE side, both PIC and AVR provide wonderful IDE’s for easy software development, debugging and compiling.
Cost: Both µc’s are affordable and easily available, with almost all functionalities available on either of them.
Conclusion:
There are no major differences between PIC and AVR if you are planning to build your first robot. All it takes is what you start off with. Since all projects in this site will be developed on AVR, I would suggest you to go with AVR. However if you have opted PIC, then a few changes in design and some changes in the code can give you a kick-start. Once you have learnt to work with AVR (or any other for that matter), then you can easily jump to other microcontrollers based on your requirements.
Do you have anything to say?
Visit the Forum to discuss, learn and share anything related to robotics and electronics !!