problem with PIC16F877+LCD display

Status
Not open for further replies.
meera83 said:
what's mean by this code?

LCD_RS Equ 0x04 ;LCD handshake lines
LCD_RW Equ 0x06
LCD_E Equ 0x07
Define LCD_RS as bit 4 of the port, RW as bit 6 and E as bit 7.
So during programming, when you want to set RS, you simply
Code:
bsf PORTA, LCD_RS
if my port pin connection is like
RA1 - E
RA2 - RW
RA3 - RS

DB4 - RD0
DB5 - RD1
DB6 - RD2
DB7 - RD3

then what location should i write??
You can define them as:
Code:
LCD_RS		Equ	0x03		
LCD_RW		Equ	0x02
LCD_E		Equ	0x01
Depends on which port and which pin are you connecting them to.
You use portD for the data bits, just change it in the code.
 


i had re-attach the file again..

i think the port pin that i define is right, but i didn't understand that why the LCD still no respond...
 

Attachments

  • lcd1.txt
    5.8 KB · Views: 149
Did you notice this:
Code:
LCD_CTRL	Equ	PORTA
LCD_TRISA	Equ	PORTA
Have you connected them well? Or did you adjust the contrast?
 
meera83 said:
i didn't connect anything to CONTRAST part, what use of this part??

Hi,
You require a 10K0 potentiometer, between +5V and 0V and the wiper of the pot connected to Vo of the LCD pcb. Adjusting the pot will set the 'contrast' of the LCD so that you can see the LCD characters.
At first, set the contrast so that you can just see the pixel blocks on the LCD.

Have a look where the +5V and 0V wires are connected to the LCD pcb, next them [on my lcd] is pin#3, which is Vo.

Does this help?
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…