Serial Comm PC to PIC for Graphic LCD

Coding and general discussion relating to user created compiler modules

Moderators: David Barker, Jerry Messina

Post Reply
yudi
Posts: 10
Joined: Sat May 23, 2009 3:02 am
Location: Indonesia

Serial Comm PC to PIC for Graphic LCD

Post by yudi » Sat May 23, 2009 3:56 am

Dear All,

I have succesfully displaying text & graphic to my LCD with T6963 controller using T6963c module from Ahmed Lazreg ([email protected]).. Thanks.

But now, i will control the LCD from PC using serial communication.
F.Y.I, i have succesfully send/receive a string from PC to PC using my serial module written in visual C++ 6.0.

Sending code is as follow:

{ . .
send_string = "123456789";
port.Write(send_string , send_string.GetLength() , len);
. .
}

Can anyone give an example how to receive a string data to be displayed on the LCD. I am using PIC18F452.

Thanks a lot.

Francis
Registered User
Registered User
Posts: 314
Joined: Sun Mar 25, 2007 9:40 am
Location: Devon

Post by Francis » Tue Jun 09, 2009 6:07 pm

yudi,

I found the easiest way is to use the Rx buffer in conjuntion with the USART.DataAvailable boolean.

Then write a loop using USART.Readbyte to pick up the string of chars from your PC. There will be variations on this theme. Once your chars are in an array or string you can then write them to your GLCD.

Some may prefer to use interrupts, it depends on your app.

yudi
Posts: 10
Joined: Sat May 23, 2009 3:02 am
Location: Indonesia

Post by yudi » Tue Jun 16, 2009 2:04 pm

Thanks Francis,

I have found the way how to read strings as multy byte using ISRRX. I can send string from my PC, and display it on the LCD.

Post Reply