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

PIC18F67J10 - Code is making a non-requested jump?

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



Joined: 21 Jun 2010
Posts: 11

View user's profile Send private message

PIC18F67J10 - Code is making a non-requested jump?
PostPosted: Sat Aug 28, 2010 7:34 am     Reply with quote

Ok, I have a really strange problem. I have a project with multiple C modules. Two of the modules are very similar (MotorA and MotorB). The MotorB routine seems to be functioning correctly, but MotorA is not. Using the debugger, I am able to step through the code, and a really strange thing is happening.

It executes the first couple statements of the MotorA routine correctly. Then it enters a select-case statement. It jumps to the correct case, BUT IN THE MotorB ROUTINE! I don't understand why it is jumping to the other module. Could this be some kind of linking error? Everything has distinct naming (variables, function names, ...), so I don't know what could be making it jump. Has anyone seen this happen to them?

I am using a PIC18F67J10 device.
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Sat Aug 28, 2010 2:14 pm     Reply with quote

Do you have the XINST fuse set ? If so, change it to NOXINST.
Using XINST can cause erratic operation (it's not supported by CCS).
KentR



Joined: 21 Jun 2010
Posts: 11

View user's profile Send private message

PostPosted: Sun Aug 29, 2010 5:47 pm     Reply with quote

Thanks! I'll try that first thing Monday!
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