What is DebugWire interface

Debug wire is an interface which enables debugging AVR microcontrollers by using one wire. All new AVR microcontrollers with less than 16kByte memory have built in one wire bidirectional debugging interface which allows debugging devices at the real time.

Like JTAG interface DebugWIRE can handle full execution and program flow control. It also supports unlimited number of breakpoints, adjusting memory contents. Good thing is that interface doesn’t require additional pins as only RESET pin is used for debugging purposes.

debug_wire_interface.PNG

 

To enable debugwire interface DWEN fuse has to be programmed also lock bits has to be un-programmed. Then RESET port pin is activated as open-drain bi directional I/O pin with pullup enabled. Reset pin becomes communication gateway between target and emulator. When debugging external reset circuitry should be disconnected – so no external reset source will be present during debugging.

Debug wire adapter-debugger communicates through one data register DWDR which can only be accessed by debugger.

Using debugwire there it isnot possible to program Fuse settings, so it has to be done via ISP as debugWire is only for debugging and not for programming like JTAG. So once debugwire is enabled ISP becomes disables as RESET pin purpose is changed. So you need to restore from dw withing debugging system to be able to program chip again. Debugwire interface can be accessed using AVRStudio and AVRJTAG MKII adapter. With AVRStudio and AVRJTAG MKII you dont have bother about entering DW and exiting from debugging as it is done automatically.

 

Blogsphere: TechnoratiFeedsterBloglines
Bookmark: Del.icio.usSpurlFurlSimpyBlinkDigg
RSS feed for comments on this post
 |  TrackBack URI for this post

New on WinAVR Tutorial
Running TX433 and RX433 RF modules with AVR microcontrollers,
Sometimes in embedded design you may want to go wireless. Might be you will want to log various readi …
Programming AVR ADC module with WinAVR,
Most of AVR microcontrollers have Analog to Digital Converter (ADC) integrated in to chip. Such solut …
New on WinARM Tutorial
What are differences between WinARM and WinAVR,
Everyone who is working with AVR microcontrollers knows this powerful tool – WinAVR (http://win …
LPC2000 watchdog timer,
As in all microcontrollers watchdog timers purpose isto reset microcontroller after reasonable amount …

Leave a Reply