Newhaven Products > Character LCDs

RS232 PIC CCS COMPILER COMANDS FOR NHD-0420D3Z-NSW-BBW-V3 ISSUE

(1/1)

DavidVM:
Just acquired NHD-0420D3Z-NSW-BBW-V3 Serial display, Im currently using PIC 18f4550 on ccs compiler, with recommended standard 232, with the following header #use rs232(baud=9600,parity=N,xmit=Pin_C6,rcv=Pin_c7,bits=8), The LCD 4x20 has the following conections On J1 PIN 1=RX (To TX on PIC) PIN 2=VSS PIN 3=VDD, On J2 just PIN 5=VSS PIN 6=VDD.
I have a simple question, how can I send the commands to the LCD, for example If I want to clear the screen datasheet says 0xFE as prefix and 0x51 as command, but I have no clue how should I send this command, I used printf, putc, puts, and so on.

Saurabh_B:
Hello David,

If you have VDD and VSS going to pins 2 & 3 of the display, they do not need to be applied to pins 5 & 6, they are all tied internally.

For this i would recommend using the following:
putc(0xFE)  // Prefix
putc(0x51) // Clear Screen

DavidVM:
Thanks a lot for the help, it did work as you stated.

Navigation

[0] Message Index

Go to full version