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 support@ccsinfo.com

pic16f690 and 12X2 hantronix lcd display

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







pic16f690 and 12X2 hantronix lcd display
PostPosted: Fri Nov 11, 2005 5:31 pm     Reply with quote

When my program is running the D4 bit (C4 of the pic) is being held high.
So when i ask to print a "C" i get an "S" ect. The lcd is intilizing properly (or seems to be) and the other bits look fine. When the program does a read from the lcd the C4 bit follows as a input but when it configures as an out put (tris c) it goes high and stays high.

I am using the LCD driver configured for port C. The pic is running at 31KHz (int osc) and my compiler is version 3.228.

I have run the code on Mtlabs sim and it looks like it should work.

Any help would be greatly appr.
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Fri Nov 11, 2005 6:06 pm     Reply with quote

In your version of the compiler, CCS has some incorrect initialization
code which turns on comparator #2 by mistake. To fix this problem,
you need to add the line of code shown below in bold:

Quote:
void main()
{
setup_comparator(NC_NC_NC_NC); // Turn off comparators

// Put your other code here.

while(1);
}
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