Microchip Technology ATmega4809 Xplained Pro Getting Started
Microchip Technology ATmega4809 Xplained Pro Getting Started

Microchip Technology ATmega4809 Xplained Pro Getting Started

Hide thumbs Also See for ATmega4809 Xplained Pro:

Advertisement

Quick Links

Getting Started with megaAVR

Features

Getting Started with megaAVR
Getting Started with ATmega4809 Xplained Pro and Atmel

Introduction

Author: Irun Walberg, Microchip Technology Inc.
This application note outlines how to get started with the megaAVR
Refer to the data sheet for further information on the differences between the megaAVR
devices.
©
2018 Microchip Technology Inc.
®
0-series Microcontrollers and Tools
Application Note
AN2653
®
0-Series
®
Studio 7.0
®
0-series devices.
®
DS00002653A-page 1
0-series

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the ATmega4809 Xplained Pro and is the answer not in the manual?

Questions and answers

Summary of Contents for Microchip Technology ATmega4809 Xplained Pro

  • Page 1: Features

    • Getting Started with megaAVR 0-series Microcontrollers and Tools ® • Getting Started with ATmega4809 Xplained Pro and Atmel Studio 7.0 Introduction Author: Irun Walberg, Microchip Technology Inc. ® This application note outlines how to get started with the megaAVR 0-series devices.
  • Page 2: Table Of Contents

    1.1. megaAVR 0-Series........................3 2. Get the Device Datasheet..................4 3. Get the Tools......................5 3.1. Get the ATmega4809 Xplained Pro Evaluation Kit...............5 3.2. Get the STK600 Starter Kit......................7 3.3. Get Source Code from Atmel | START..................8 3.4. Get Atmel Studio 7.0........................9 3.5.
  • Page 3: Relevant Devices

    Horizontal migration to the left reduces the pin count and therefore the available features. ® Figure 1-1. megaAVR 0-Series Overview Flash 48KB ATmega4808 ATmega4809 32KB ATmega3208 ATmega3209 16KB Pins 28/32 Devices with different Flash memory size typically also have different SRAM and EEPROM. Application Note DS00002653A-page 3 © 2018 Microchip Technology Inc.
  • Page 4: Get The Device Datasheet

    (includes all device dependent descriptions of the device, number of peripherals, pinout and electrical characteristics) • Errata (includes all known erratas for the device) For devices that are future products, the product brief is available instead of the datasheet. Application Note DS00002653A-page 4 © 2018 Microchip Technology Inc.
  • Page 5: Get The Tools

    Get the Tools Get the Tools ® Atmel Studio 7.0, which uses GCC compiler, is the preferred IDE to get started with megaAVR 0-series. Get the ATmega4809 Xplained Pro Evaluation Kit Figure 3-1. ATmega4809 Xplained Pro Kit CURRENT MEASUREMENT SW0 USER BUTTON HEADER...
  • Page 6 C, four GPIOs – Virtual COM port (CDC) • USB Powered The ATmega4809 Xplained Pro user guide covers how to power the kit and the detailed information on board components, extension interface, and the hardware guide. Application Note DS00002653A-page 6 ©...
  • Page 7: Get The Stk600 Starter Kit

    Two Adjustable Reference Voltages with High Accuracy (0-5.0V, 10mV res.) • Clock Oscillator, Adjustable On-The-Fly from Atmel Studio (0-50MHz, 0.1% res.) ® ® • Serial In-System Programming (ISP) of tinyAVR and megaAVR Devices Application Note DS00002653A-page 7 © 2018 Microchip Technology Inc.
  • Page 8: Get Source Code From Atmel | Start

    Atmel | START user guide can be found by clicking About from the Atmel | START front page or Help And Support within the project configurator, both located in the upper right corner of the page. Application Note DS00002653A-page 8 © 2018 Microchip Technology Inc.
  • Page 9: Get Atmel Studio 7.0

    IAR: Support for new devices in IAR Embedded Workbench can be added by installing the latest service pack. The service pack is available from My Pages on https://iar.com. Application Note DS00002653A-page 9 © 2018 Microchip Technology Inc.
  • Page 10: Atmel Studio Users Getting Started

    The kit will be powered by the USB, and the embedded debugger will enable debugging and programming via the USB. Workflow Launch Atmel Studio 7.0. The page shown in the figure below will appear when ATmega4809 Xplained Pro is connected to Atmel Studio 7.0. Application Note DS00002653A-page 10 ©...
  • Page 11 AN2653 Atmel Studio Users Getting Started Figure 4-1. ATmega4809 Xplained Pro Page in Atmel Studio Start creating a new project by clicking New → Project... or by using the shortcut Ctrl+Shift+N, as shown in the figure below. Application Note DS00002653A-page 11 ©...
  • Page 12 (e.g. GETTING_STARTED and LED_TOGGLE), and click OK. Figure 4-3. New Project Wizard Select ATmega4809 from the device selection wizard as shown in the figure below, and click OK. Application Note DS00002653A-page 12 © 2018 Microchip Technology Inc.
  • Page 13 */ PORTB.OUTSET = PIN5_bm; /* 1: Released */ else /* LED0 off */ PORTB.OUTCLR = PIN5_bm; In the code editor, the code should appear as shown in the figure below. Application Note DS00002653A-page 13 © 2018 Microchip Technology Inc.
  • Page 14 Open project properties by clicking Project → Properties or by using the shortcut ALT+F7. In the Tool view (see the figure below) set Selected debugger/programmer to mEDBG and Interface to UPDI. Application Note DS00002653A-page 14 © 2018 Microchip Technology Inc.
  • Page 15: Atmel Studio With Stk600

    11. Run the code by clicking Debug → Continue or by using the shortcut F5). 12. Verify that LED0 is lit when SW0 is pushed on the ATmega4809 Xplained Pro. Atmel Studio with STK600 Prerequisites •...
  • Page 16 (e.g. GETTING_STARTED and LED_TOGGLE), and click OK. Figure 4-8. New Project Wizard Select ATmega4809 from the device selection wizard as shown in the figure below, and click OK. Application Note DS00002653A-page 16 © 2018 Microchip Technology Inc.
  • Page 17 /* LED0 on */ PORTB.OUTCLR = PIN1_bm; /* 1: Released */ else /* LED0 off */ PORTB.OUTSET = PIN1_bm; In the code editor, the code should appear as shown in the figure below. Application Note DS00002653A-page 17 © 2018 Microchip Technology Inc.
  • Page 18 Open project properties by clicking Project → Properties or by using the shortcut ALT+F7. In the Tool view (see the figure below) set Selected debugger/programmer to STK600 and Interface to UPDI. Application Note DS00002653A-page 18 © 2018 Microchip Technology Inc.
  • Page 19 Connect the embedded debugger on STK600 to ATmega4809 by connecting a cable between the ISP/PDI headers, as shown in the figure below. Figure 4-12. UPDIConnection on STK600 10. Connect PB2 to SW0, and PB5 to LED0 by using cables. Application Note DS00002653A-page 19 © 2018 Microchip Technology Inc.
  • Page 20 12. Run the code by clicking Debug → Continue or by using the shortcut F5. 13. Verify that LED0 is lit when SW0 is pushed on STK600. Application Note DS00002653A-page 20 © 2018 Microchip Technology Inc.
  • Page 21: What's Next

    All relevant application notes can be found under the documentation tab. • AVR product selector: http://www.microchip.com/paramChartSearch/chart.aspx?branchID=30047 • More technical documentation concerning various products: http://www.microchip.com/webdoc/ • Microchip Technical Support: http://www.microchip.com/support/hottopics.aspx Application Note DS00002653A-page 21 © 2018 Microchip Technology Inc.
  • Page 22: Revision History

    AN2653 Revision History Revision History Doc. Rev. Date Comments 02/2018 Initial document release Application Note DS00002653A-page 22 © 2018 Microchip Technology Inc.
  • Page 23: The Microchip Web Site

    Microchip’s Data Sheets. Most likely, the person doing so is engaged in theft of intellectual property. • Microchip is willing to work with the customer who is concerned about the integrity of their code. Application Note DS00002653A-page 23 © 2018 Microchip Technology Inc.
  • Page 24: Legal Notice

    SQTP is a service mark of Microchip Technology Incorporated in the U.S.A. Silicon Storage Technology is a registered trademark of Microchip Technology Inc. in other countries. GestIC is a registered trademark of Microchip Technology Germany II GmbH & Co. KG, a subsidiary of Microchip Technology Inc., in other countries.
  • Page 25: Quality Management System Certified By Dnv

    AN2653 © 2018, Microchip Technology Incorporated, Printed in the U.S.A., All Rights Reserved. ISBN: 978-1-5224-2693-6 Quality Management System Certified by DNV ISO/TS 16949 Microchip received ISO/TS-16949:2009 certification for its worldwide headquarters, design and wafer fabrication facilities in Chandler and Tempe, Arizona; Gresham, Oregon and design centers in California ®...
  • Page 26: Worldwide Sales And Service

    New York, NY Sweden - Stockholm Tel: 631-435-6000 Tel: 46-8-5090-4654 San Jose, CA UK - Wokingham Tel: 408-735-9110 Tel: 44-118-921-5800 Tel: 408-436-4270 Fax: 44-118-921-5820 Canada - Toronto Tel: 905-695-1980 Fax: 905-695-2078 Application Note DS00002653A-page 26 © 2018 Microchip Technology Inc.

This manual is also suitable for:

Megaavr 0 series

Table of Contents