In tutorial 2 we created ledtest.c file using the IDE of Programmers Notepad & also we created a Make file (go to tutorial 2 here ).
We’ve saved these 2 files inside C:\LED_TEST folder.
In this post we shall see the ways of generating the .Hex file and burning it on to the target AVR chip ATMega16.
From under WINAVR fire up Programmers Notepad.
Go to File –> Open & browse to C:\LED_TEST to select the ledblink.c program we created in previous post.
Click Tools –> Make All
to start the compilation.Programmers notepad will compile,link and generates the .Hex file of your .c file.
After successful compilation you can see “>Process Exit Code : 0 “ at the bottom of the Output window.
You can see a list of compiled files generated within your project folder C:\LED_TEST.
A file with extension .hex (blin_led.hex) is the one we are going to burn on the target IC.
Now click “ Program “ under Tools
You can see in the Output window the AvrDude in action writing the .hex file on to your chip.While the .hex file is being written , the Red LED glows on the usbasp hardware.
Watch this video :