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

playing with serlcd

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



Joined: 09 Jun 2010
Posts: 3
Location: dunkerque, france

View user's profile Send private message

playing with serlcd
PostPosted: Wed Dec 01, 2010 2:47 am     Reply with quote

hi everyone !!

I'm playing with this little code for a serial lcd from Sparkfun.
Everything is ok but when I connect the data wire on pin_c5 nothing appear.... Shocked
My configuration is working on different pin like c0 or a0. But in my future project it must be on pin c5 !

Did I miss something ? or c5 is burned ?

Regards.

Here is the so little code :
Code:

/////////////////////////////////////////////////////////////////////////
////                           SERIALLCD.C                    ////
////                                                                 ////
////  This program will show how to use the serlcd with              ////
////  hex special command clear screen                              ////
////                                                                 ////
////  Configure the CCS prototype card as follows:                   ////
////     Connect serlcd rx pin to pic pin_c5                         ////
////     Connect  Rs232 from rs232 as usued to c6 xmit & c7 rcv      ////
//// plug serlcd data wire to c7 to take order from your pc
//// plug serlcd wire to c6 to see pc data line
//// plug serlcd wire to xx(here c5) to see lcd data line
////
/////////////////////////////////////////////////////////////////////////

#include <18F2550.h>
//#include <serLCD.c>
#fuses HS,NOWDT,NOPROTECT,NOLVP
#use delay(clock=10000000)

#use rs232(stream=PC, baud=9600, xmit=PIN_C6, rcv=PIN_C7, ERRORS)
#use rs232(stream=serLCD, baud=9600, xmit=PIN_c5, ERRORS)//configuration of your tx :D
//#include <serLCD.c>

/****************************** MAIN ******************************************/
void main(){
   int8 tartenpion=0xff;
   while(TRUE)
      {
      fprintf(pc,"  %x  ",tartenpion);
      delay_ms(1000);
      Fprintf(PC,"hello pc here is 18f2250,38400,38400   ");   //comunicate with pc line
      tartenpion=get_tris_c();
      Fprintf(serLCD,"LCD");
      delay_ms(1500);
     
      }
}
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Wed Dec 01, 2010 1:19 pm     Reply with quote

Sparkfun must have at least 15 "serial enabled" lcds. How do you expect
us to know which one you have ? Also, they have a forum. I would first
look there for tips on how to make it work.

But, you will never make pin C5 work as an output pin. The 18F2550
data sheet says it's a "digital input only" pin.
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