Microcontroller Tutorial Made for the Beginner
If you are a beginner, looking to gain knowledge of microcontrollers, you may find
that this tutorial series is a perfect match. This tutorial investigates various
uses and features of the popular AVR Atmega32 microcontroller. The tutorial shows
real programs being written and explained with circuit development. Basic and intermediate
programming concepts and uses are also provided along the way. Through the many
examples, you can be an expert in embedded systems in no-time.
Learn the basic features of the AVR Atmega32 microcontroller and some information on the uses of each pin. The programming of the chip (getting a program on the chip) is briefly explained as well.
We get our hands dirty and create a convenient little interface for the programmer dongle to the appropriate pins of the microcontroller.
The driver for the programmer that is used to transfer code to the microcontroller is installed. The installation process is compatible with the Windows 7 operating system as well as previous Windows versions.
The driver and interface is ready, but a programming environment is needed to actually write the programs and transfer them into the microcontroller. In this tutorial, we set up an AVR-GCC programming environment called winavr.
Find out more than you probably every wanted to know about an LED (Light Emitting Diode) and how to hook it up to the microcontroller.
Write the first program to do something with the LED and tranafer it to the microcontroller. This is the true test to see if all of the pre-setup works.
We delve into programming the microcontroller a bit more and make the LED blink. The microcontroller
In this tutorial, we add the ability for the human to interact with the microcontroller. A button is added to change the blink speed on the LED.
A very critical subject that must be addressed with buttons and how they interact with the microcontroller.
We carry on with the button debouncing, but this time, we have the microcontroller doing the debouncing in software.
Now we take the LEDs and push button to a whole new level and create a game with the microcontroller.
tick, tock, tick tock. Find out how the microcontroller counts and times.
This is where interruptions are good manners and even desirable. We interrupt routines from events in the microcontroller.
A great way to see what is going on, LCDs (Liquid Crystal Display) provide an informative way to output data from the microcontroller.
We know all there is to know about how the LCD functions internally and how we need to communicate to it from the microcontroller. In this tutorial, we jump in and write the first program to display some characters to the LCD.
In the previous tutorial on the first program for the LCD, we could only display single characters. Sure, it was a good start and a relatively simple implementation, but we can do better. This time, we command the microcontroller to display strings (one or more characters) at one time.
Displaying numbers on the LCD is probably the most useful way to use the LCD and see what is going on in the microcontroller. This tutorial will show how to convert an integer variable, or any other number to a string so we can display it on the LCD.
It's time to unclutter the main.c code and get all of the LCD routines to their own library so the main.c is more readable. This will make programming for the microcontroller much more fun.
Are you wondering how to power up the microcontroller without the help of the computer's usb port? This tutorial will show the use of batteries, wall adapter, or the USB port for powering the microcontroller.
Check out this handy way to connect peripherals to the microcontroller using headers.
Do you really know how a potentiometer works? Do you know how to make it a super cool voltage divider? Learn how to use a potentiometer to get a variable voltage so it can be used in the ADC (Analog to Digital converter) on the microcontroller.
Learn how the ADC (Analog to Digital Converter) works, and a few tip on keeping your analog signal and your microcontroller happy.
Let write our first ADC program and have the microcontroller read the voltage coming from the potentiometer.
Increase the resolution of the microcontroller ADC by capturing the 10-bit result (a result that will range between 0-1023).
Get to know accelerometers and how a particular variety is connected to the microcontroller.
Are you constantly getting ADC noise and is it driving you crazy? This tutorial will show you how to measure this noise and see the measurements drop when noise reduction techniques are applied to the signal and the microcontroller.
So, one sensor, or device being connected to the microcontroller ADC isn't enough? Well, see how to use the other channels of the ADC.
Make things move with servos and get ready to learn how to interface these devices to microcontrollers.
Using the microcontroller to communicate with the UART and USART features.
Using the UART to communicate from a transmitting microcontroller to a receiving microcontroller.
Abstracting the button code and software debouncing into a library so the main microcontroller programming is more compact.