6 Appendix

Schematic, Assembly Drawing, Adapter Pinout, Programming External MCUs, External Debuggers

6.1 Schematic

Figure 6-1 6-5. AVR16EB32 Curiosity Nano MCU Schematic
Figure 6-2. AVR16EB32 Curiosity Nano Debugger Schematic

6.2 Assembly Drawing

Figure 6-3. AVR16EB32 Curiosity Nano Assembly Drawing Top
Figure 6-4. AVR16EB32 Curiosity Nano Assembly Drawing Bottom

6.3 Curiosity Nano Base for Click boards

Figure 6-1 6-5. AVR16EB32 Curiosity Nano Pinout Mapping

6.4 Programming External Microcontrollers

Use the on-board debugger on AVR16EB32 Curiosity Nano to program and debug microcontrollers on external hardware.

6.4.1 Supported Devices

All external AVR microcontrollers with the UPDI interface can be programmed and debugged with the on-board debugger with Microchip Studio.

External SAM microcontrollers having a Curiosity Nano Board can be programmed and debugged with the on-board debugger with Microchip Studio.

AVR16EB32 Curiosity Nano can program and debug external AVR16EB32 microcontrollers with MPLAB X IDE.

6.4.2 Software Configuration

No software configuration is required to program and debug the same device mounted on the board.

To program and debug a different microcontroller than the one mounted on the board, configure Microchip Studio to allow an independent selection of devices and programming interfaces.

  1. Navigate to Tools > Options through the menu system at the application top.
  2. Select the Tools > Tool settings category in the options window.
  3. Set the Hide unsupported devices option to False.
Figure 6-6. Hide Unsupported Devices
Info: Microchip Studio allows any microcontroller and interface to be selected when the Hide unsupported devices setting is set to False - also microcontrollers and interfaces not supported by the on-board debugger.

6.4.3 Connecting to External Microcontrollers

The figure and table below show where to connect the programming and debugging signals to program and debug external microcontrollers. The on-board debugger can supply power to the external hardware or use an external voltage reference for its level shifters. Read more about the power supply in Power Supply.

The on-board debugger and level shifters actively drive data and clock signals used for programming and debugging (DBG0, DBG1, and DBG2). Pull-down resistors are required on the ICSP™ data and clock signals to debug PIC® microcontrollers. All other interfaces are functional with or without pull-up or pull-down resistors.

DBG3 is an open-drain connection and requires a pull-up resistor to function.

Remember:
  • Connect GND and VTG to the external microcontroller
  • Tie the VOFF pin to GND if the external hardware has a power supply
  • Make sure there are pull-down resistors on the ICSP data and clock signals (DBG0 and DBG1) to support the debugging of PIC microcontrollers
Figure 6-7. Curiosity Nano Standard Pinout
Table 6-1. Programming and Debugging Interfaces
Curiosity Nano PinUPDIICSP™SWD
DBG0UPDIDATASWDIO
DBG1CLKSWCLK
DBG2
DBG3MCLRRESET

6.5 Connecting External Debuggers

Even though there is an on-board debugger, external debuggers can be connected directly to the AVR16EB32 Curiosity Nano to program/debug the AVR16EB32. When not actively used, the on-board debugger keeps all the pins connected to the AVR16EB32 and board edge in tri-state. Therefore, the on-board debugger will not interfere with any external debug tools.

Figure 6-8. Connecting the MPLAB® PICkit 5 In-Circuit Debugger/Programmer to AVR16EB32 Curiosity Nano
Figure 6-9. Connecting the Atmel-ICE to AVR16EB32 Curiosity Nano
CAUTION: To avoid contention between the external debugger and the on-board debugger, do not start any programming/debug operation with the on-board debugger through MPLAB® X IDE or mass storage programming while the external tool is active.

6.6 Disconnecting the On-Board Debugger

The on-board debugger and level shifters can be disconnected from the AVR16EB32.

The power supply block diagram (Figure 4-5 4-7) shows all connections between the debugger and the AVR16EB32. The signal names are also printed in silkscreen on the top or bottom side of the board.

To disconnect the debugger, cut the GPIO straps shown in Cut Straps.

Attention: Cutting the GPIO straps to the on-board debugger will disable the virtual serial port, programming, debugging, and data streaming. Cutting the power supply strap will disconnect the on-board power supply.
Tip: Reconnect any cut connection by using solder. Alternatively, mount a 0Ω 0402 resistor.
Tip: When the debugger is disconnected, an external debugger can be connected to the holes. Connecting External Debuggers describes how to connect an external debugger.

6.7 Getting Started with IAR

IAR Embedded Workbench® for AVR® is a proprietary high-efficiency compiler not based on GCC. Programming and debugging of AVR16EB32 Curiosity Nano is supported in IAR Embedded Workbench for AVR using the Atmel-ICE interface. To get the programming and debugging to work, some initial settings must be set up in the project.

The following steps will explain how to get the project ready for programming and debugging:

  1. Make sure that the project to be configured is opened. Open the OPTIONS dialog for the project.
  2. In the category General Options, select the Target tab. Select the device for the project, or if not listed, the core of the device, as shown in Figure 6-10.
  3. In the category Debugger, select the Setup tab. Select Atmel-ICE as the driver, as shown in Figure 6-11.
  4. In the category Debugger > Atmel-ICE, select the Atmel-ICE 1 tab. Select UPDI as the interface. Optionally select the UPDI frequency, as shown in Figure 6-12.
Info: If the selection of Debug Port (mentioned in step 4) is grayed out, the interface is preselected, and the user can skip this configuration step.
Figure 6-10. Select Target Device
Figure 6-11. Select Debugger
Figure 6-12. Configure Interface