Connecting to Target through the debugWIRE Interface

A minimum of three wires are required for communication between Atmel AVR Dragon and the target board with the debugWIRE interface. These signals are RESET, VTref, and GND.

Important!

This interface uses only 1 pin, (RESET pin) for communication with the target. To enable the debugWIRE interface on an AVR Device, the debugWIRE Enable fuse (DWEN) must be programmed, (DWEN=0). AVR devices with debugWIRE interface are shipped with the DWEN fuse un-programmed from the factory. The debugWIRE interface itself cannot enable this fuse. The DWEN fuse can be programmed through SPI programming mode, which requires connection to a 6-pin header. For this reason it is recommended to place the full 6-pin SPI connector on your target board to simplify debugging and programming.

NOTE: When the DWEN fuse is enabled the SPI interface is overridden internally in order for the OCD module to have control over the RESET pin. The debugWIRE OCD is capable of disabling itself temporarily (using the button on the debugging tab in the properties dialog in Atmel Studio), thus releasing control of the RESET line. The SPI interface is then available again (only if the SPIEN fuse is programmed), allowing the DWEN fuse to be un-programmed using the SPI interface. If power is toggled before the DWEN fuse is un-programmed, the debugWIRE module will again take control of the RESET pin. It is HIGHLY ADVISED to simply let Atmel Studio handle setting and clearing of the DWEN fuse!

If using this connection from AVR Dragon on a Atmel STK500, be sure to detach the RESET jumper on the STK500. And connect to the correct ISP header for the actual AVR device, guided by the color code in the STK500 silk-print.