PICmicro & dsPIC >> PICmicro & dsPIC

Pages: 1
kcress



Reged: Feb 22 2005
Posts: 42
Debugger verses stand alone.
      #119262 - Fri Jul 03 2009 05:55 AM

Hello!

I've been struggling with an issue for tooo long. I thouhgt someone might be able to shed some light or give me a direction to chase down.

I'm running a PIC18F4520 developing with MPLAB's IDE.

When I'm in the development environment the 4x20 LCD display works flawlessly.

Then after:
1) I tell the IDE to not compile the ICD code.
2) Cancel the MPLAB ICD2 emulator.
3) Reconfigure to the MPLAB ICD2 programmer.
4) Recompile.
5) Program the PIC.
6) Release the PIC from RESET.

The display still works but has occasional flipping characters, misplaced characters, lost characters, and if left alone the display will eventually crash with various issues like lost lines or lines with blocks only, etc, etc, ad nauseum...

I suspect it's timing related but since I have no clear understanding of what the executional differences are between emulating and not, I'm having a hard time figuring out where to look.(and I have been looking....)

I thought there was zero speed difference between emulation and not emulating when just straight running. Am I mistaken?


Post Extras: Print Post   Remind Me!   Notify Moderator  
swanny
enthusiast


Reged: Sep 12 2008
Posts: 247
Loc: New Zealand
Re: Debugger verses stand alone. [Re: kcress]
      #119272 - Fri Jul 03 2009 06:57 AM

Sounds like the delays.

Can you check your delays with a scope (to compare)?

Edited by swanny (Fri Jul 03 2009 06:58 AM)


Post Extras: Print Post   Remind Me!   Notify Moderator  
jtemplesModerator
Guru
****

Reged: Oct 16 2003
Posts: 1601
Loc: Southern California
Re: Debugger verses stand alone. [Re: kcress]
      #119462 - Mon Jul 06 2009 12:19 AM

There isn't any speed difference. The only thing that changes is that in debug mode, the linker must reserve certain regions of RAM (and possibly ROM) for the debugger, which could cause some of your RAM objects to be at different addresses in the two different compilations. Thus one compilation might mask or change the behavior of a bug in your code that shows up in the other compilation.

Post Extras: Print Post   Remind Me!   Notify Moderator  
kcress



Reged: Feb 22 2005
Posts: 42
Re: Debugger verses stand alone. [Re: swanny]
      #119482 - Mon Jul 06 2009 03:45 AM

swanny; Thanks for the suggestion. I did scope everything. I eventually even attacked it with a logic analyzer.

After many hours of trying everything. I built three more identical boards. None of them showed the same LCD misbehavior. Not a hint. So I'm chocking it up to a bad display... Probably the most expensive display I will ever touch.(now)


jtemples; I believe that was happening because the issue did eventually manifest in debugger mode too.

Thanks.


Post Extras: Print Post   Remind Me!   Notify Moderator  
swanny
enthusiast


Reged: Sep 12 2008
Posts: 247
Loc: New Zealand
Re: Debugger verses stand alone. [Re: kcress]
      #119582 - Mon Jul 06 2009 05:24 PM

Good that you got it resolved.

It still sounds like something might be out of spec - voltage, timing etc. It could be that your display is at the edge of (or past) in a certain tolerance.

Or it's just a dud

Either way, if the failure rate is low enough it wont matter.


Post Extras: Print Post   Remind Me!   Notify Moderator  
Pages: 1



Extra information
2 registered and 11 anonymous users are browsing this forum.

Moderator:  mikerj, jtemples, jeff, Dan Henry, Andrew L 

Print Topic

Forum Permissions
      You cannot start new topics
      You cannot reply to topics
      HTML is enabled
      UBBCode is enabled

Rating:
Topic views: 448

Rate this topic

Jump to

Contact Us | Privacy statement HI-TECH Software

Powered by UBB.threads™ 6.5.5