CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Can program but not debug?!?!?!??!

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
Langton



Joined: 29 Nov 2009
Posts: 25

View user's profile Send private message

Can program but not debug?!?!?!??!
PostPosted: Thu May 15, 2014 9:16 pm     Reply with quote

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

View user's profile Send private message

PostPosted: Sun May 18, 2014 4:34 pm     Reply with quote

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

View user's profile Send private message

PostPosted: Sun May 18, 2014 4:38 pm     Reply with quote

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

View user's profile Send private message

PostPosted: Sun May 18, 2014 8:38 pm     Reply with quote

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

View user's profile Send private message

PostPosted: Mon May 19, 2014 1:16 am     Reply with quote

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

View user's profile Send private message

PostPosted: Mon May 19, 2014 4:39 pm     Reply with quote

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

View user's profile Send private message

PostPosted: Mon May 19, 2014 5:32 pm     Reply with quote

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

View user's profile Send private message

PostPosted: Mon May 19, 2014 5:37 pm     Reply with quote

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

View user's profile Send private message

PostPosted: Tue May 20, 2014 3:28 pm     Reply with quote

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 Smile
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
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


Powered by phpBB © 2001, 2005 phpBB Group