Download and Install WinAVR Software:
WinAVR is a suite of executable, open source software development tools for the Atmel AVR series of RISC microprocessors hosted on the Windows platform. Includes the GNU GCC compiler for C and C++. Arduino is the platform of choice for programming AVR microcontrollers and for good reasons. But there are times when you want to have full control over what is added to your code.
Arduino is enabling by default Timer0 for use in millis function and other functions and includes some interrupt routines that perhaps your project is not using and so adding to the code size or perhaps those interrupts can interfere with your code.Two main alternatives are WinAVR and Atmel Studio. This tutorial covers WinAVR because it’s simpler to use for a beginner.
What you will need:
1. ATmega328P.
2. USBTinyISP programmer.
3. WinAVR software.
What you can learn:
1. How to program an AVR microcontroller using an In-System Programmer such as USBTinyISP and WinAVR
2. Some bitwise operations for handling the registers
There are two main ways to program a microcontroller:
A. ISP (In System Programming) using SPI protocol and a ISP programmer
B. With a bootloader using UART protocol and a USB to Serial programmer.
Programming software
There are many tools for programming an AVR microcontroller such as Atmel Studio, PlatformIO, Eclipse with an AVR plugin, etc but the simplest and light weight solution that I found is using WinAVR.
Programming hardware
Apart from development software there is also the need of a hardware programmer that the software uses to communicate with the microcontroller and upload the code to it. Searching online for ‘avr programmer’ reveals lots of options.
Software Download Links:
Download and Install WinAVR Software: Click Here.
Download and Install WinAVR Software Link: Click Here.