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

Need help with LCD driver

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



Joined: 17 May 2008
Posts: 6

View user's profile Send private message MSN Messenger

flexible LCD driver
PostPosted: Wed May 28, 2008 7:53 am     Reply with quote

Hi all,

I've been troubleshooting but i cannot seem to find out why the LCD won't show what i've programmed it to.

I've tried using the LCD.C, doesn't work. i've tried the flexible LCD Driver from this forum, doesn't work either :(

this's my pin configuration on flexLCD.C and i'm using PIC18F4550

Code:

#define LCD_DB4   PIN_D4
#define LCD_DB5   PIN_D5
#define LCD_DB6   PIN_D6
#define LCD_DB7   PIN_D7

#define LCD_E     PIN_D3
#define LCD_RS    PIN_D2
#define LCD_RW    PIN_D1


this's the code on my main form


Code:

#include <18F4550.h>
#fuses HSPLL,NOWDT,NOPROTECT,NOLVP,NODEBUG,USBDIV,PLL5,CPUDIV2,VREGEN
#use delay(clock=48000000)
#include <flexLCD.c>

void main()
{
lcd_init(); 

lcd_putc("Hello World");

while(1);
}


what can possibly be wrong? please help :(

thanks so much!
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Wed May 28, 2008 11:04 am     Reply with quote

There are many LCD trouble-shooting threads on this board.
Here are some of them:
http://www.ccsinfo.com/forum/viewtopic.php?t=32244
http://www.ccsinfo.com/forum/viewtopic.php?t=33292
RArtz



Joined: 28 May 2008
Posts: 7

View user's profile Send private message

PostPosted: Wed May 28, 2008 2:18 pm     Reply with quote

what type of LCD?
16x2? 16x1?

Also, what happens when you apply power?
Does one line of the LCD turn on while the other off?
Be more specific if you can.

I am using a similar PIC, and am not having any problems using the flexLCD.c (the LCD.c did not work for me).

Do make sure you have everything wired correctly. Sometimes you miss the obvious.
Onemusha
Guest







PostPosted: Tue Apr 21, 2009 6:15 am     Reply with quote

I'm using 16x1 lcd and the lines are set like:

Data lines: D1,D2;D3,D4
RS PIN_E2
RW PIN_B2
E PIN_D6

----------------------------------------
The code is almost the same as from the original post.
I can't make the LCD to work.
There is no display, no black squares...

Where could be the problem?
The hardware connections are OK.
andrewg



Joined: 17 Aug 2005
Posts: 316
Location: Perth, Western Australia

View user's profile Send private message Visit poster's website

PostPosted: Tue Apr 21, 2009 8:08 am     Reply with quote

Check your contrast voltage. It should probably be quite low < 1V ? Hopefully you've got that on a pot, so twiddle the pot a bit.
_________________
Andrew
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