At 04:52 PM 5/12/01 +1000, Roman Black wrote:
{Quote hidden}>David VanHorn wrote:
> >
> > At 11:29 AM 5/11/01 -0700, David W. Gulley wrote:
> > >On Fri, 11 May 2001, David VanHorn wrote:
> > > > I'm getting some anomalous behaviour.
> > ><SNIP>
> > > > However, later, I commented out panic_a and panic_c.
> > > > When I breakpoint, and pull up the trace memory, it shows that I came
> > > > through panic_a, which now looks like this:
> > > >
> > > > (some code)
> > > > ;btfss port,bit
> > > > ;goto panic_a
> > > >
> > > > I did re-assemble, reset, and run, and I even tried closing the entire
> > > > project and coming back in.
> > > > Still, according to the trace, it's getting to the panic code, via
> panic_a.
> > >
> > >Just a random thought, but did you comment out the panic_a label?
> >
> > no, but according to the trace, it's executing the commented line "goto
> > panic_a"
>
>
>David, the IDE doesn't handle stacked (overloaded)
>goto labels very well. If you have two labels with
>one line of code, (like if you comment-out the code
>but leave a label) the MPLAB IDE will decide which
>label it will accept for debugging etc.
OK, but the problem isn't there.
When the only line of source in the project that reads:
"goto panic_a" has a semicolon in front of it, then it had better not show
up in a trace.
The problem appears to be that I had a complex trigger defined on this
line, and then commented it out (and rebuilt the entire project) It seems
that the complex trigger somehow overrides the commenting.
>Have a look at the code in the ROM window, then top
>left button of it to select "dissassembly display"
>then you can see which of the labels the debugger
>has used. I imagine it always uses the first (or last)
>label if they are stacked. I don't know which because
>I try to avoid stacking labels for exactly the reason
>you have now! :o)
The stacked labels weren't the problem.
--
Dave's Engineering Page: http://www.dvanhorn.org
Where's dave? http://www.findu.com/cgi-bin/find.cgi?kc6ete-9
--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads