Debugger lost green arrow PC loc & ERROR#12 on WATCH
Posted: Fri Sep 04, 2015 10:14 pm
I've been using CCS C compiler for a little over a month and having quite a few issues with the debugger. I find when I'm single stepping the green arrow showing the current line will sometimes disappear on STEP OVER. It seems to occur on calls to functions. Sometimes if I continue to step the green arrow will come back at some point on another line but what was executed during the mystery steps is . . . a mystery. This can occur on an if statement that calls a function such that I don't know if the if was executed (true) or not. Along with this I'm getting ERROR #12 in the WATCH window when trying to display local variables and parameters to functions. For example in the screen capture image FAILED-WATCH
The symbols i_TimeoutInTicks, this and nowTick all give the ERROR #12 Undefined identifier yet the green arrow in Timer.c shows execution is within the TimerStart function where the first two are input parameters and the last is a local variable.
I've already submitted this to support but don't expect a reply till Monday and thought other users might be able to help. My target processor is PIC18F87J94 and CCS PCWH Compiler V5.048.
Jon Newbill _________________ I remember the days before OPS (Other Peoples Software) when all the bytes in my computer were written by me.
Ttelmah
Joined: 11 Mar 2010 Posts: 19546
Posted: Sat Sep 05, 2015 12:18 am
One thing that affects what you can see, is the #nolist option. This is enabled at the top of every processor include file (simply rem it out), and makes all the calls to CCS functions be excluded from the listing file.
Can I say how nice it is to see some properly commented code.
Most readable code I have seen here for ages.
jonnewbill
Joined: 29 Jul 2015 Posts: 10
Posted: Sat Sep 05, 2015 3:59 pm
The code I'm executing is not CCS library code the routine being called is my own routine within the project. The behavior is intermittent as now when I recompile the same code it steps correctly at the same line. I have also tried stepping using the assembly listing and when the green arrow disappears the PC= in the debug window reports the current PC location and that address can be searched for in the .lst window but when the address is located it does not have a green arrow. Stepping at this point changes the PC= field but does not update the source or .lst window with a green arrow. And I still can't see any of the local symbols in the WATCH window due to the ERROR #12. _________________ I remember the days before OPS (Other Peoples Software) when all the bytes in my computer were written by me.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum