Yahoo Groups archive

AVR-Chat

Index last updated: 2026-04-28 22:41 UTC

Thread

Re: Debugwire, stk-500 and M168

Re: Debugwire, stk-500 and M168

2008-01-24 by Zapper77DK

------------
I deleted all previous history because this post is just my experience
with DebugWire.
------------

I tried all sorts of things - with and without pull up resistor on a
JTAGICE Mk2.

However, my conclusion after having spent hours (and four different
JTAGS) was that the DebugWire ONLY works using a JTAG Mk2 with a green
LED on the PCB. Not talking about the three status LEDs - but the
extra fourth LED which is mounted on the PCB and visible through the
blue plastic.

This JTAG (which is also blue) has newer hardware (Production date
should say somewhere in 2006 I think).

Well.. Just my 10c

Cheers,
Jesper

Re: [AVR-Chat] Re: Debugwire, stk-500 and M168

2008-01-24 by John Samperi

At 06:59 AM 25/01/2008, you wrote:
>Even though I wasn't USING the breakpoints, (I was
>single-stepping), that was causing the problem.
>
>I may not have read ALL the documentation, but as far as I'm aware,
>setting a breakpoint is not supposed to also cause the debugger to
>ignore the instruction at the breakpoint.

...and the other bits from other posts...

I have been using DW with the Dragon for about 18 months now,
it has been working very well. I have only worked with 5V supplies
though and ALWAYS a 4K7 pull up resistor in the reset line, with
clock ranging from internal 1MHz to crystal 14MHz.

I must admit that it is not the most solid of debugging environments
but it does work. At times I need to unplug the Dragon and restart
Studio but rarely.

As far as the wrong values in the registers, is the list file correct
or is something happening at assembly time?

With the breakpoint issue, I always do a "build and run" every time I
make the smallest chance. New code gets uploaded to the chip and any
old set breakpoints get cleared, at times some cannot be set in the
original location but they get highlighted and you get asked to remove
them which I do. Remember that breakpoints do in fact change memory
locations, (they are placed in memory with DW not hardware like JTAG)
so it is useful to reload the code and overwrite them.

Hang in there, I have done about a dozen or more project with DW
and I love it. I would prefer if all chips had DW instead of JTAG
as one does not waste any pins. It WILL get better :-)


Regards

John Samperi

********************************************************
Ampertronics Pty. Ltd.
11 Brokenwood Place Baulkham Hills, NSW 2153 AUSTRALIA
Tel. (02) 9674-6495       Fax (02) 9674-8745
Email: john@ampertronics.com.au
Website  http://www.ampertronics.com.au
*Electronic Design * Custom Products * Contract Assembly
********************************************************

Re: [AVR-Chat] Re: Debugwire, stk-500 and M168

2008-01-24 by David VanHorn

> I have been using DW with the Dragon for about 18 months now,
> it has been working very well. I have only worked with 5V supplies
> though and ALWAYS a 4K7 pull up resistor in the reset line, with
> clock ranging from internal 1MHz to crystal 14MHz.

In my case, I'm talking to an STK-500 board, with no other "stuff" on
the chip, just the bare minimum.
Chip is running on internal RC clock.

> I must admit that it is not the most solid of debugging environments
> but it does work. At times I need to unplug the Dragon and restart
> Studio but rarely.

Hmm..

>
> As far as the wrong values in the registers, is the list file correct
> or is something happening at assembly time?

No, the lst is right, it's just NOPing some instructions.
I've not yet caught it loading anything other than what I said, or
doing the wrong instruction, it just looks like the instruction was a
nop instead of what I asked for.

> With the breakpoint issue, I always do a "build and run" every time I
> make the smallest chance. New code gets uploaded to the chip and any
> old set breakpoints get cleared, at times some cannot be set in the
> original location but they get highlighted and you get asked to remove
> them which I do. Remember that breakpoints do in fact change memory
> locations, (they are placed in memory with DW not hardware like JTAG)
> so it is useful to reload the code and overwrite them.

Right, same here.  I've had long standing issues in all the debug
platforms with what I originally called "ghostpoints".
Lotsa debugging happens, many breakpoints get set/cleared etc.
Clear all breakpoints, uninstall studio, use a different chip,
reinstall studio, start debugging again, and suddenly when you should
have been running right through, you're sitting breakpointed at a
location where there's no breakpoint, but it IS one that you'd used
before.


> Hang in there, I have done about a dozen or more project with DW
> and I love it. I would prefer if all chips had DW instead of JTAG
> as one does not waste any pins. It WILL get better :-)

That's just about the only direction it CAN go in from my experience.

Re: [AVR-Chat] Re: Debugwire, stk-500 and M168

2008-01-24 by David VanHorn

> However, my conclusion after having spent hours (and four different
> JTAGS) was that the DebugWire ONLY works using a JTAG Mk2 with a green
> LED on the PCB. Not talking about the three status LEDs - but the
> extra fourth LED which is mounted on the PCB and visible through the
> blue plastic.
>
> This JTAG (which is also blue) has newer hardware (Production date
> should say somewhere in 2006 I think).

20071109 with a green LED down near the USB port.

Re: [AVR-Chat] Re: Debugwire, stk-500 and M168

2008-01-24 by David VanHorn

Watching reset on a scope, the risetime is about 7uS, fall time is a
bit less, as you'd expect with an O/C line.
I don't see any overshoot, undershoot, or ringing.. Looks pretty clean
from here.

I can catch it on my LA, but I can't decode the bitstream, so not much point.

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.