avr-chat
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-chat] sample code for ATmega48? ... and a debugWIRE question


From: Graham Davies
Subject: Re: [avr-chat] sample code for ATmega48? ... and a debugWIRE question
Date: Thu, 31 May 2007 22:02:21 -0400

Joe Strout wrote:
.... Anybody have something like that?

Well, it just so happens that I'm working on a new product with an ATmega168 and I think it's quite likely that the same code will run on your ATmega48. So, here is what you asked for, source and hex. (Warning - most people on this list will regret looking at the attachments as they will be too boring.)

Now I have a question ...

In order to run this code in the debugger (using AVR Studio with WinAVR and an AVR Dragon), I had to let AVR Studio use debugWIRE to set the DWEN fuse. Now that the DWEN fuse is set, I can't use ISP. The AVR Dragon Help explains this, and further says "Use debugWIRE or High Voltage programming to disable the DWEN fuse." OK, I can re-configure for High Voltage, but that's quite a chore and won't be possible in many people's target systems. But, I can't figure out how to use debugWIRE to disable the DWEN fuse. Can anyone point me in the right direction?

Graham.

Attachment: Flash168.c
Description: Binary data

Attachment: Flash168.hex
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]