User manual
Atmel-ICE [USER GUIDE]
42330A-MCU-07/2014
28
6. Software Integration
6.1 Atmel Studio
6.1.1 Software Integration in Atmel Studio
Atmel Studio is an Integrated Development Environment (IDE) for writing and debugging Atmel AVR and Atmel
SAM applications in Windows environments. Atmel Studio provides a project management tool, source file
editor, simulator, assembler and front-end for C/C++, programming, emulation and on-chip debugging.
Atmel Studio version 6.2 or later must be used in conjunction with the Atmel-ICE.
6.1.2 Programming Options
Atmel Studio supports programming of Atmel AVR and Atmel SAM ARM devices using the Atmel-ICE. The
programming dialog can be configured to use JTAG, aWire, SPI, PDI, TPI or SWD modes, according to the
target device selected.
When configuring the clock frequency, different rules apply for different interfaces and target families:
● SPI programming makes use of the target clock. Configure the clock frequency to be lower than one fourth
the frequency at which the target device is currently running
● JTAG programming on Atmel megaAVR devices is clocked by the programmer. This means that the
programming clock frequency is limited to the maximum operating frequency of the device itself. (Usually
16MHz)
● AVR XMEGA programming on both JTAG and PDI interfaces is clocked by the programmer. This means
that the programming clock frequency is limited to the maximum operating frequency of the device itself.
(Usually 32MHz)
● AVR UC3 programming on JTAG interface is clocked by the programmer. This means that the
programming clock frequency is limited to the maximum operating frequency of the device itself. (Limited to
33MHz)
● AVR UC3 programming on aWire interface is clocked by the programmer. The optimal frequency is given
by the SAB bus speed in the target device. The Atmel-ICE debugger will automatically tune the aWire baud
rate to meet this criteria. Although it's usually not necessary the user can limit the maximum baud rate if
needed (e.g. in noisy environments)
● SAM device programming on SWD interface is clocked by the programmer. The maximum frequency
supported by Atmel-ICE is 2MHz. The frequency should not exceed the target CPU frequency times 10,
.
6.1.3 Debug Options
When debugging an Atmel AVR device using Atmel Studio, the 'Tool' tab in the project properties view contains
some important configuration options. Those options which need further explanation are:
● Target Clock Frequency
Accurately setting the target clock frequency is vital to achieve reliable debugging of Atmel megaAVR
device over the JTAG interface. This setting should be less than one fourth of the lowest operating
frequency of your AVR target device in the application being debugged. See “Atmel megaAVR OCD
(JTAG)” on page 33 for more information.
Debug sessions on debugWIRE target devices are clocked by the target device itself, and thus
no frequency setting is required. The Atmel-ICE will automatically select the correct baud rate for
communicating at the start of a debug session. However, if you are experiencing reliability problems
related to a noisy debug environment, it is possible to force the debugWIRE speed to a fraction of its
"recommended" setting.
Debug sessions on AVR XMEGA target devices can be clocked at up to the maximum speed of the device
itself (usually 32MHz).
Debug sessions on AVR UC3 target devices over the JTAG interface can be clocked at up to the maximum
speed of the device itself (limited to 33MHz). However the optimal frequency will be slightly below the
current SAB clock on the target device.