LED Blink with AVR Codevision

I recall the days at fearburster @NIT Bhopal july 2007 where i burned a micrcontroller for 1st time. Before this i had tried a no. of microcontrollers but unsucccesfull in programming any of these due several reasons

  • High cost programmer
  • Unavailabilty of chip
  • And at last a good compiler with which i can code in C

The AVR chips support ISP programming with SPI Protocol. The programmer costs below Rs100/-. You can assemble it yourself

open the Code vision AVR IDE go to settings–>Programmer
choose the STK200 (Kanda systems Programmer) and Port LPT1
Connect the burner as described here
check the programmer followed by powering on the chip and connecting correctly. Now open the programmer from the menu. Select the chip now click ” Read all “.  If everything is OK you will see a progress bar and Read complete window. otherwise it will show you some error with the weird sound “Dhoom” and a message ” The chip may be damged or the chip is not powerd on or the programmer not connected properly. “
#include<mega16.h.
#include<delay.h>
main()
{
DDRA=0xFF;
PORTA=0x00;
while()
{
PORTA=~PORTA;
ms_delay(30);
}
}

Leave a Reply