View previous topic :: View next topic |
Author |
Message |
Langton
Joined: 29 Nov 2009 Posts: 25
|
Can program but not debug?!?!?!??! |
Posted: Thu May 15, 2014 9:16 pm |
|
|
Hi Guys,
I'm using MPLAB X 1.90 and PCH4.14 on a PIC18F45K20 via a Real Ice.
I can program but not debug. The message i get is...
The target device is not ready for debugging. Please check your configuration bit settings and program the device before proceeding.
I removed the entire program leaving only main() and played a lot with fuse combinations but it's left me at wits end, any ideas would be much appreciated.
fuse combination presently is...
#fuses INTRC_IO,HFOFST,NOWDT,NOLVP,noBROWNOUT,NOPBADEN,NOXINST,NOWRT,NOWRTD,noEBTR,NOCPB,noEBTRB,NOWRTC,NOWRTB,NOCPD,NOIESO,noPUT,noPROTECT,debug,MCLR,NOFCMEN
Thanks |
|
|
Langton
Joined: 29 Nov 2009 Posts: 25
|
|
Posted: Sun May 18, 2014 4:34 pm |
|
|
Anyone??? Even an opinion e.g. should be fine at that would be of some assistance to me |
|
|
temtronic
Joined: 01 Jul 2010 Posts: 9245 Location: Greensville,Ontario
|
|
Posted: Sun May 18, 2014 4:38 pm |
|
|
You might have to tell MPLAB X 1.90 to USE the program fuses and NOT use it's fuses options.
Might also have to TELL Real Ice the same thing....
As it stands you've got THREE 'programs' that control the fuses
Real Ice, MPLAB and your PIC program....
Things were a LOT easier using paper tape...
jay |
|
|
Langton
Joined: 29 Nov 2009 Posts: 25
|
|
Posted: Sun May 18, 2014 8:38 pm |
|
|
Hmmmmm good idea, I'll try that now, thanks heaps for taking the time to reply, much appreciated |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19549
|
|
Posted: Mon May 19, 2014 1:16 am |
|
|
Normally the problems the other way, with MPLAB insisting on overriding the fuses so everything is in debug mode....
There are two ways of connecting to the Real ICE from MPLAB. As a programmer, or as a debugger. Obviously to debug, you need it selected in the debug mode, not the programmer mode. Then MPLAB needs to be set to compile for debug, not for program, otherwise it'll override the debug fuse. |
|
|
Langton
Joined: 29 Nov 2009 Posts: 25
|
|
Posted: Mon May 19, 2014 4:39 pm |
|
|
Hi guys,
Still not getting any love from this thing.
Would anybody please be able to confirm that there is nothing wrong with the way I have set the fuses above.
Any addition comments or thoughts would be a bonus
Thanks |
|
|
temtronic
Joined: 01 Jul 2010 Posts: 9245 Location: Greensville,Ontario
|
|
Posted: Mon May 19, 2014 5:32 pm |
|
|
OK...I do NOT use RealIce or MPLAB X, prefer to burn/test in the real real world...
I downloaded the RealIce manual..seems to be a LOT of 'why debug doesn't work' comments near the end of the manual.I suspect 'one of them' may be the culprit.Most are hardware related..obviously only you can 'look and see' if it's one of those.I would create a '1Hz blinking LED ' program and use it for testing.As you say you can download and run..it will confirm the PIC is still 'alive and well'.
Might want to googl your problem...you can't be the first...maybe the uC site has a few ideas ??
make a list, check off things as you go...too easy to skip the 'one' that IS the culprit.
good luck, report back .....
jay |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Mon May 19, 2014 5:37 pm |
|
|
Did you build your own board or did you buy it ? If you bought it,
post a link to the board's website.
You said you can program it. Does it blink an LED at the expected rate ?
If you're in a company, there will probably be other debug tools available.
Can get an ICD2 or ICD3 ? Try it. See if you can debug with it.
Look at this document, which tells how to use Real Ice with MPLAB X:
http://ww1.microchip.com/downloads/en/DeviceDoc/51997A.pdf
Have you done every test recommended by Microchip, such as the
loopback test ?
http://ww1.microchip.com/downloads/en/DeviceDoc/52085A.pdf
If all else fails, sign up on the Microchip support website and open a
trouble ticket. Real Ice is their product and they will support it. |
|
|
Langton
Joined: 29 Nov 2009 Posts: 25
|
|
Posted: Tue May 20, 2014 3:28 pm |
|
|
Hi guys, thanks heaps for your input. I went through the list re 'why it may not debug' and couldn't find a fault. I did the loop back test and it came up with some strange stuff, not a fail, more a can't test or something to that effect. The boards are prototypes and I have only 3 so I'm going to abort and just program - test - change - program the old school way as the project is almost finished and I'd rather the devil I know at this point. Thanks heaps for your help, much appreciated |
|
|
|