Atmel AVR042 Application Note
Hide thumbs Also See for AVR042:

Advertisement

Quick Links

AVR042: AVR Hardware Design Considerations
Features
Providing robust supply voltage, digital, and analog
Connection of RESET line
SPI interface for In-System Programming
Using external crystal or ceramic resonator oscillators
Description
This application note has been written to provide answers to some of the questions
and problems faced when starting designs involving Atmel
microcontrollers. The application note treats topics that are known to cause
problems. The scope is to provide an introduction to potential design problems
rather than being an exhaustive walk-through of how to design applications using
the AVR microcontrollers. This document is thus a collection of information from
existing Atmel AVR documents, combined with information that is not previously
documented.
It is highly recommended to read the application note
Considerations"
– before initiating a new design, especially if the aim of the design
is a commercial application that needs to meet the requirements of the EMC
directive (or similar directives in countries outside Europe). The application note is
available from the AVR section of the official Atmel website http://www.atmel.com.
APPLICATION NOTE
AVR 8-bit Microcontrollers
®
AVR040 - "EMC Design
Atmel-2521M-AVR-Hardware-Design-Considerations_ApplicationNote_092014
®
AVR

Advertisement

Table of Contents
loading

Summary of Contents for Atmel AVR042

  • Page 1 AVR microcontrollers. This document is thus a collection of information from existing Atmel AVR documents, combined with information that is not previously documented. It is highly recommended to read the application note AVR040 - “EMC Design...
  • Page 2: Table Of Contents

    General About Crystals and Ceramic Resonators ................11 Recommended Capacitor Values ......................12 Unbalanced External Capacitors ......................13 RTC Crystals ............................13 PCB Layout ............................13 Example Layout ......................13 Revision History ......................16 AVR Hardware Design Considerations [APPLICATION NOTE] Atmel-2521M-AVR-Hardware-Design-Considerations_ApplicationNote_092014...
  • Page 3: Power Supply

    Digital Supply Looking at the datasheet for an Atmel AVR microcontroller, one can be fooled to believe that power supply is not critical. The device has a very wide voltage range, and draws only a few mA supply current. But as with all digital circuits, the supply current is an average value.
  • Page 4: Analog Supply

    Figure 1-2. Decoupling with Series Inductor Generally, the Atmel AVR devices where power and ground lines are placed close together (like the Atmel ATmega8535) will get better decoupling than devices with industry standard pin-out (like the Atmel ATmega8515), where the power and ground pins are placed in opposite corners of the DIP package. This disadvantage can be overcome by using for example a TQFP package, which allows decoupling capacitors to be placed very close to the die.
  • Page 5: External Reset Switch

    The pull-up resistor can in theory be of any size, but if the Atmel AVR should be ® programmed from e.g. STK 500/AVRISP the pull-up should not be so strong that the programmer cannot activate RESET by draw the RESET line low. The recommended pull-up resistor is 4.7kΩ or larger when using STK500 for programming.
  • Page 6: Connecting Isp Lines

    — just in case. The different programming interfaces are introduced in the following subsections. Refer to the device datasheet and Atmel AVR Tools help for further information on which interfaces are supported by the device, and how to connect the programming tool.
  • Page 7: Shared Use Of Spi Programming Lines

    Connecting the SPI Lines to the ISP Interface Multiple Atmel AVR in a single application can share the same ISP interface to allow for programming of all the devices through a minimal interface. However, the AVR devices will all respond to the ISP instructions if special design considerations are not made.
  • Page 8: Shared Use Of Jtag Lines

    3-2, are necessary if the JTAG lines are also used for other purposes. For example, if they are used for analog input to the Atmel AVR, there are often analog filters on the lines. If such filters are present on the JTAG lines, it may be required to eliminate the filter capacitor during programming to ensure that the load is mainly resistive.
  • Page 9: Pdi Interface

    Figure 3-5. Filters on JTAG Pins – Correct and Incorrect Ways to Connect PDI Interface The Program and Debug Interface (PDI) is an Atmel proprietary two-line interface that was introduced with the ® Atmel AVR XMEGA microcontroller family. As the name implies, this interface can be used for both In-System Programming and on-chip debugging of devices.
  • Page 10: Tpi Interface

    Atmel STK600, AVRISP mkII and AVR Dragon™ during programming and the JTAGICE mkII and the Atmel AVR ONE! during programming and debugging. Pull-up resistors should be at least 10kΩ, or be removed from the RESET line if an Atmel programmer is used. TPI Interface ®...
  • Page 11: General About Crystals And Ceramic Resonators

    Oscillator circuit for crystals and ceramic resonators faster than 400kHz. Circuit for low frequency crystals (32.768kHz) (not on all Atmel AVR). Simplifying the description of the Atmel AVR built-in oscillator circuits they can be understood as the inverter based oscillator circuits illustrated in Figure 4-1.
  • Page 12: Recommended Capacitor Values

    4-2. The CKOPT Fuse should not be programmed when using external capacitors. Refer to the datasheet to assure whether the device has internal capacitors or not. Note that Atmel AT90S8535, Atmega163, and Atmega103 do not have the CKOPT-fuse; instead they have dedicated pins (TOSC1-TOSC2), to connect the 32.768kHz watch crystal to.
  • Page 13: Unbalanced External Capacitors

    However, unbalanced capacitive loads will affect the duty cycle of the oscillation and therefore one should in general not use unbalanced capacitive loads. This is especially critical if running the Atmel AVR close to its maximum speed limit. RTC Crystals Many AVR devices have the possibility use asynchronous clocking of the built-in timer/counter.
  • Page 14 Figure 5-1. (A) Basic Schematic of Required/Recommended Connections for ATxmega32A4. (B) Copper PCB Layout and (C) Top Silk Prints AVR Hardware Design Considerations [APPLICATION NOTE] Atmel-2521M-AVR-Hardware-Design-Considerations_ApplicationNote_092014...
  • Page 15 AVR Hardware Design Considerations [APPLICATION NOTE] Atmel-2521M-AVR-Hardware-Design-Considerations_ApplicationNote_092014...
  • Page 16: Revision History

    Revision History Doc Rev. Date Comments 2521M 09/2014 Fixed some typos in Section 2.1. 2521L 07/2013 Updated the diagram of Filters on JTAG pins. Fixed some typos. 2521K 03/2011 Initial document release. AVR Hardware Design Considerations [APPLICATION NOTE] Atmel-2521M-AVR-Hardware-Design-Considerations_ApplicationNote_092014...
  • Page 17 DISCLAIMER: The information in this document is provided in connection with Atmel products. No license, express or implied, by estoppel or otherwise, to any intellectual property right is granted by this document or in connection with the sale of Atmel products. EXCEPT AS SET FORTH IN THE ATMEL TERMS AND CONDITIONS OF SALES LOCATED ON THE ATMEL WEBSITE, ATMEL ASSUMES NO LIABILITY WHATSOEVER AND DISCLAIMS ANY EXPRESS, IMPLIED OR STATUTORY WARRANTY RELATING TO ITS PRODUCTS INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT.

Table of Contents