meowww

Electronics blog

AVR microcontrollers

Posted by meowww on May 29, 2009

On this blog, I will be posting some easy DIY circuits, both analog electronics and microcontroller projects. The microcontrollers I will be using are the AVR series of microcontrollers. The advantage with these microcontrollers is that they are very easy to program. If you have a parallel port in your computer, you can program a basic AVR with just 4 resistors and some wires. Also AVRs come with lots of features on-chip (UART, ADC, SPI, I2c..etc). So one chip like an ATMega16/32 can be used to learn each an every aforementioned features. In this post I will be talking about the various ways in which one can program an AVR.
HARDWARE:
The most basic way is to use a BSD programmer. One can find how to construct the programmer HERE . Its a basic programmer and needs 5 wires. You can add 4 resistors (4.7KΩ) in between the parallel port and the microcontroller pins thus ensuring no damage to the parallel port due to shorting of the data pins.
If one doesn’t have a parallel port a USB based programmer can be made. The one I prefer is the USBasp. One can get the schematic and the PCB layout on the USBasp site HERE . In this case however ATmega8 is needed in the programmer circuit. The ATmega8 should be programmed with the firmware provided. If you dont have a parallel port, get it programmed from a friend. On the USBasp website, I prefer the one schematic by J.A. de Groot.
The layout is provided, just etch it and solder the components and its ready to use.
SOFTWARE:
To program the microcontrollers a software is needed, I basically use AVRdude. It is a command line utility and simple to use. AVRdude-GUI is also available, but needs AVRdude to be installed first. To install AVRdude download WinAVR and install it, recent version of AVRdude will be included in it. AVRdude-GUI can be downloaded from HERE . Using the program is pretty simple. More on it in next posts.

Posted in AVR | Tagged: , , | 8 Comments »

 
Follow

Get every new post delivered to your Inbox.