View previous topic :: View next topic |
Author |
Message |
m4rcdbk
Joined: 29 Aug 2016 Posts: 10 Location: Michigan, USA
|
PIC24F debugger and the watch/RAM window |
Posted: Wed Oct 12, 2016 6:24 pm |
|
|
Hi group,
Been searching around and haven't found exactly what I've been looking for (or at least not solution wise). I haven't run across any technical bulletins or updates that indicate this is a resolved issue or if I just am a terrible programmer.
I have a Pic24FJ128GA010 and am using the debugger to step through it.
So far that part works great, except all the RAM shows as 00 00 00 00 in the RAM column. For everything. The Variable watches, even as I step through functions, relevant local variables show up as 0, even when they're being set to a specific value. Global values, on the other hand, change randomly inside that function.
The relevant fuses I have included:
DEBUG
JTAG
ICD = 2
I have also tried increasing the stack size to 1024, as well as using only 1 break point and stepping from there. Neither of them seems to resolve the issue. In fact -- the ONLY way I get a value (and this also includes the SFR window) in RAM or otherwise, is if I intentionally cause an address error.
[edit: ] Even THEN it doesn't always show the contents of RAM.
So far the only mechanism I have of debugging is using a FTDI cable connected to a UART (just RX/TX) and pushing variables into the TXREG to see. But, kind of non-optimal to view a struct and other data through a console output.
I am using version 5.056 of the compiler. |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19539
|
|
Posted: Thu Oct 13, 2016 1:02 am |
|
|
"The debugger".....
What debugger?.
Presumably the CCS IDE?. With what hardware?. (ICD-U64 etc..).
Except for the specification of which ICD connection to use, get rid of your debug fuses. The ICD will set what it needs automatically, and I don't think JTAG is wanted.
Run up CCSLOAD, and use it's diagnostics. Is the ICD firmware up to date?. Is it showing the voltages as OK?. |
|
|
m4rcdbk
Joined: 29 Aug 2016 Posts: 10 Location: Michigan, USA
|
|
Posted: Thu Oct 13, 2016 1:47 pm |
|
|
Ttelmah wrote: | "The debugger".....
What debugger?.
Presumably the CCS IDE?. With what hardware?. (ICD-U64 etc..). |
ICD-U64 with the CCS IDE, yes.
On that note, do you know of any other debuggers that will work with ICD-U64 that is recommended?
Ttelmah wrote: |
Except for the specification of which ICD connection to use, get rid of your debug fuses. The ICD will set what it needs automatically, and I don't think JTAG is wanted. |
Removed all noted fuses. Only ICD = 2 is specified.
Ttelmah wrote: |
Run up CCSLOAD, and use it's diagnostics. Is the ICD firmware up to date?. Is it showing the voltages as OK?. |
ICD firmware is 3.18 Voltage is right at 3.2~3.3, everything else shows as expected on the CCSLOAD.
But sadly still no difference thus far. |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19539
|
|
Posted: Fri Oct 14, 2016 12:36 am |
|
|
You need to be asking CCS then.
There have been firmware versions that have caused similar problems on other chips, This one does have some oddities, so it may simply be that the current firmware has not been tested on this particular chip, and is causing problems.
One other question, how long is your ICD cable/PCB connection?. The faster PIC24's, do become quite fussy about the cable. |
|
|
m4rcdbk
Joined: 29 Aug 2016 Posts: 10 Location: Michigan, USA
|
|
Posted: Fri Oct 14, 2016 2:51 pm |
|
|
I will ask them then =[.
As for the lengths, the chip is about 1 CM from the connector and the cable is about 15CM from ICD to PCB. |
|
|
|