Beginning Microcontrollers Part 4: Installing the Programming Environment (WinAVR)

Introduction: Beginning Microcontrollers Part 4: Installing the Programming Environment (WinAVR)

About: I like robots!

Welcome to the next step in our series. We'll be introducing some basic programming elements now. This tutorial is simply about installing your programming environment. The programming environment we will be using is called WinAVR.

To be able to make the microcontroller do something useful, we must write instructions for it to follow. While we can write these instructions with a simple text editor, many people find it much easier to use a dedicated "programming environment" to write their programs.

The video in this tutorial takes you through each step needed to install one such programming environment (WinAVR) on the computer. I call it a programming environment because the program you will install has many features. This particular programming environment allows you to create and edit programs in various languages (we will focus on C), and then compile the program into an executable format that the microcontroller will understand. Finally, WinAVR will help us transfer this file into the microcontroller. WinAVR will also help us to do many other things, like debugging our programs and giving warnings when there are compilation and syntax errors. We will get into the particulars of these in later tutorials.

The installation process for WinAVR is very quick and concise. Here are the detailed steps:

  • Download the latest files from the WinAVR sourceforge files location.
  • Click on the latest release.
  • You will need to answer the security question asking whether you want to save the download or not, since you will be downloading an executable file.
  • Once it is downloaded, execute the file by clicking on it.
  • The installation process will start.The installation process will have the usual Windows install wizard information, and some questions offered to help you tailor the process. Most of these can simply be left as their default value, but select as you see appropriate.

Well, that's pretty much it for the installation. Not much different than the installation for most Windows programs. But you will probably notice the many options in the start menu folder for the WinAVR programming environment. Don't fear, you will typically use only one of these programs called the "Programmers Notepad." Clicking on this icon will start the user interface for the application that allows us to write our programs (creation and editing). The program also contains menu commands that will help us compile the code and then transfer it into the microcontroller.

Ok, so you may still be rusty on the compiling process. Recall that it's just the process where the computer converts the human-readable program you wrote into a set of instructions that the microcontroller can understand. The programmers notepad will take care of all of this for us behind the scenes, so we don't have to concern ourselves with all the details. You can, however, learn more about the process if you wish.

In the next video, we will test our configuration and installed components. The programmer will be tested so we can confirm that it is recognized by Windows, and it is fully able to communicate with the microcontroller device. We will then write a short "Do nothing" program to make sure there are no errors when we transfer the program onto the microcontroller.

Be the First to Share


    • Trash to Treasure Contest

      Trash to Treasure Contest
    • Home and Garden Contest

      Home and Garden Contest
    • Woodworking Contest

      Woodworking Contest