Preview

Atmel Language

Powerful Essays
Open Document
Open Document
1839 Words
Grammar
Grammar
Plagiarism
Plagiarism
Writing
Writing
Score
Score
Atmel Language
Getting started with C Programming for the ATMEL AVR Microcontroller

By Lam Phung Version 1.0 Created on May 14, 2008. Last updated January 15, 2010. Latest version of this document is available at: http://www.elec.uow.edu.au/avr

© University Of Wollongong, 2008.

Table of Contents
1. 2. 3. Introduction Installing tools for C programming Using AVR Studio for C programming Creating an AVR Studio project Compiling C code to HEX file Debugging C program using the simulator Downloading and running HEX file on AVR board 2 2 3 3 5 6 8

3.1 3.2 3.3 3.4

1. Introduction
This tutorial provides information on the tools and the basic steps that are involved in using the C programming language for the Atmel AVR microcontrollers. It is aimed at people who are new to this family of microcontrollers. The Atmel STK500 development board and the ATMEGA16 chip are used in this tutorial; however, it is easy to adopt the information given here for other AVR chips. This tutorial requires the following: • the AVR Studio produced by Atmel, • the WinAVR package by Sourgeforge WinAVR project, and • an STK500 development board produced by Atmel.

2. Installing tools for C programming
To work with the Atmel AVR microcontroller using the C programming language, you will need two tools: AVR Studio and WinAVR. Both tools are free at the links given below. • AVR Studio is an integrated development environment that includes an editor, the assembler, HEX file downloader and a microcontroller emulator. AVR Studio setup file and service packs are available at http://www.atmel.com/dyn/products/tools_card.asp?tool_id=2725 • WinAVR is for a GCC-based compiler for AVR. It appears in AVR Studio as a plug-in. WinAVR also includes a program called Programmer’s Notepad that can be used to edit and compile C programs, independently of AVR Studio. WinAVR setup file is available at http://winavr.sourceforge.net/ Installing these tools is easy: just download and run the setup files, and accept

You May Also Find These Documents Helpful

  • Satisfactory Essays

    Quiz Comp Archi

    • 438 Words
    • 3 Pages

    12) Please list registers and their functions in ARM. How many general purpose registers and how to use them in the program?…

    • 438 Words
    • 3 Pages
    Satisfactory Essays
  • Good Essays

    C Is difficult, because the control flow is out of the hands of the application programmer…

    • 1508 Words
    • 7 Pages
    Good Essays
  • Satisfactory Essays

    Today’s lecture will be spent entirely in the computer lab. At the end of lab, submit this worksheet.…

    • 581 Words
    • 3 Pages
    Satisfactory Essays
  • Good Essays

    1 Explain what is meant by the term ‘dementia’ The word dementia describes a set of symptoms that may include memory loss and difficulties with thinking, problem-solving or language. ... Dementia is caused when the brain is damaged by diseases, such as Alzheimer's disease or a series of strokes. 2 Describe the key functions of the brain that are affected by dementia…

    • 1160 Words
    • 5 Pages
    Good Essays
  • Powerful Essays

    The following information will introduce general knowledge in basic programming concepts. It shall discuss basic types of computer programming languages as-well-as program development. There are three basic types of computer programming languages that will be discussed in a simple and easy to understand manner. We shall also describe the program development cycle and discuss why it is important to use a structured and organized process to create a computer programming language.…

    • 1318 Words
    • 6 Pages
    Powerful Essays
  • Satisfactory Essays

    “Remember it’s a sin to kill a mockingbird.”(Lee 90). They’re beautiful, harmless creatures that do nothing, but sing their hearts out. In “To Kill a Mockingbird”, by Harper Lee, the literal reference of the mocking bird is depicted as an innocent creature, a creature that is considered a sin if you kill one. In the story, the mockingbirds are depicted as two characters; Boo Radley and Tom Robinson. The characters show significance towards the story and the title.…

    • 710 Words
    • 3 Pages
    Satisfactory Essays
  • Powerful Essays

    Motor Cyclists

    • 48192 Words
    • 193 Pages

    Report No. RSRG 2007-04 Publication date August 2007 No. of pages 152 ISBN 978 0 642 25564 8 ISSN…

    • 48192 Words
    • 193 Pages
    Powerful Essays
  • Good Essays

    Downloaded from http://cre.sagepub.com by Farhan Khan on February 12, 2007 © 2004 SAGE Publications. All rights reserved. Not for commercial use or unauthorized distribution.…

    • 841 Words
    • 4 Pages
    Good Essays
  • Good Essays

    What Is Professionalism?

    • 490 Words
    • 2 Pages

    Professionalism refers to exhibiting the greatest and most principled methods of fulfilling an individual’s responsibilities in any professional occupation. Regarding professionalism in teaching, the definition of professionalism, refers to exhibiting an open-minded, thoughtful, and principled method of performing the responsibilities of a teaching position. A teacher must always conduct themselves in an ethical manner, and treat students, parents/guardians, as well as coworkers, and administrators justly, fairly, friendly, and compassionately (Charles, 2014). It is a teacher’s obligation to be professional with their students by being truthful with them, and behaving toward them in a civil manner that is extremely responsible (Charles, 2014). In addition, teachers must encourage positive interactions with their students, avoid partiality amongst the students,…

    • 490 Words
    • 2 Pages
    Good Essays
  • Powerful Essays

    Jessica Codr, jmc5@cec.wustl.edu (A project report written under the guidance of Prof. Raj Jain) Download…

    • 10575 Words
    • 43 Pages
    Powerful Essays
  • Powerful Essays

    Electronc Voting Machine

    • 13812 Words
    • 56 Pages

    List of Contents Abstract 1 1. Background 2 2. Microcontroller 9 2.1 Introduction 9 2.2 History 9 2.3 Definition of a Microcontroller 11 2.4 Microcontrollers vs Microprocessors 12 2.5 Memory Unit 13 2.6 Central Processing Unit 14 2.7 Bus 15 2.8 Input Output Unit 16 2.9 Serial Communication 16 2.10 Timer Unit 17 2.11 Watch Dog 18 2.12 Analog to Digital Converter 19 3. Introduction to EEPROM 21 3.1 EEPROM 21 3.2 Application/ Operation of EEPROM 21 4.…

    • 13812 Words
    • 56 Pages
    Powerful Essays
  • Powerful Essays

    The Gizduino Manual

    • 2978 Words
    • 30 Pages

    single board AVR microcontroller platform based on highly popular open source Arduino design. It can be used as…

    • 2978 Words
    • 30 Pages
    Powerful Essays
  • Satisfactory Essays

    © the authors and HAAGA-HELIA University of Applied Sciences HAAGA-HELIA Publication Series Research 1/2007 This publication is protected by the Copyright Act (404/1961). Photocopying the publication is prohibited without a permit. More information about permits and their content will be provided by Kopiosto ry, www. kopiosto.fi. The digital copying or manipulation of the publication in full or in part is likewise prohibited. Publisher: Sales of the publication: Layout: HAAGA-HELIA University of Applied Sciences HAAGA-HELIA University of Applied Sciences Oy Graaf Ab/Jani Osolanus…

    • 41589 Words
    • 167 Pages
    Satisfactory Essays
  • Better Essays

    ce2007

    • 2780 Words
    • 12 Pages

    Cyclone 3 FPGA on the Altera’s DE0 Board [1]. Coupling to the DE0 board is a Teaching…

    • 2780 Words
    • 12 Pages
    Better Essays
  • Powerful Essays

    Family with low power consumption. Atmega32 is based on enhanced RISC (Reduced Instruction Set Computing, Know more about RISC and CISC Architecture) architecture ATmega32 is an 8-bit high performance microcontroller of Atmel’s Mega AVR with 131 powerful instructions.…

    • 1225 Words
    • 5 Pages
    Powerful Essays