Serial Wire Debug Specification

Installing electric trim tabs. debugWIRE is a serial communications protocol, designed by Atmel. It is used for on-chip debugging of Atmel AVR microprocessors.

Protocol[edit]

debugWIRE is designed as a simpler alternative to JTAG, aimed at processors with limited resources. It is supported by most modern 8-bit AVRs. By using debugWIRE one has full read and write access to all memory and full control over the execution flow. It supports single-step, run-to-cursor, step-out, and software break instructions. A breakpoint (run-to-cursor) will be set by reprogramming the BREAK[1]opcode into the FLASH storage of the AVR. Care must be taken due to the limited guaranteed write cycles (10000) of the device.[2]

Programmer models[edit]

The copyrights embodied in the USB Type-C Cable and Connector Specification to use and reproduce the Specification for the sole purpose of, and solely to the extent necessary for, evaluating whether to implement the Specification in products that would comply with the specification. Without limiting. Feb 22, 2015  Serial Wire Debug (SWD) Serial Wire Debug (SWD) is a debug port similar to JTAG, and provides the same debug capabilities (run, stop on breakpoints, single-step) but with fewer pins. It replaces the JTAG connector with a 2-pin interface (one clock pin and one bi-directional data pin). The SWD port itself does not provide for real-time tracing.

debugWIRE is supported by all modern debuggers from Atmel. This includes the Atmel-ICE, the JTAGICE3, the AVR Dragon and the JTAGICE mkII.

debugWIRE specifications[edit]

debugWIRE is activated by setting (programming to zero) of the fuse DWEN (debugWIRE enable), normally located in the high fuse byte. After this action the /RESET pin function isn't available anymore and the ISP protocol cannot be used.debugWIRE can be disabled with e.g. JTAGICE mkII by sending a special reset command that disables temporarily the debugWIRE function and reenables /RESET and also ISP until next power down cycle. debugWIRE is not able to program the fuses of a device.If you want to disable debugWIRE permanently you have to disable the function temporarily and program the fuse using the now available ISP function.[3]debugWIRE uses a 1 wire open drain serial connection. The default baud rate used is AVR clock/128. Sending a BREAK 0x00 will return 0x55 which is used to detect the baud rate. The AVR will return a BREAK when a breakpoint is hit or a collision is detected on the debugWIRE connection. 0x06 is used to disable debugWIRE and reenable /RESET and ISP, 0x07 resets the AVR, 0xF0 returns the PC, 0xF3 the debugWIRE ID.[4][5][6]

References[edit]

  1. ^AVR Assembler Instructions
  2. ^ATtiny25-ATtiny45-ATtiny85_Datasheet-Summary.pdf
  3. ^debugWIRE article (in German)
  4. ^The debugWIRE protocol
  5. ^Simple stand-alone debugWIRE debugger (open source)
  6. ^Microchip Makes (25 November 2015). 'Advanced Debugging with Arduino Boards' – via YouTube.
Retrieved from 'https://en.wikipedia.org/w/index.php?title=DebugWIRE&oldid=940590925'