Serial Graphic LCD 128x64 with Arduino: Hello World code?

Have questions about a SparkFun product or board? This is the place to be.

Moderator: phalanx

Post Reply
doctor_speed
Posts: 3
Joined: Mon Jun 28, 2010 1:28 pm

Serial Graphic LCD 128x64 with Arduino: Hello World code?

Post by doctor_speed » Mon Jun 28, 2010 1:37 pm

Hi,

I have the "Serial Graphic LCD 128x64" connected to an Arduino, but I can't seem to get it to produce any normal characters. This LCD uses the Graphic LCD Serial Backpack to interface to the 128X64 LCD.

The board is connected okay and responds to input consistently, it's just that I think I'm using it wrong.

Does anyone have any 'hello world' code for the Arduino that gets the "Serial Graphic LCD 128x64" to produce correct results?

I see some code around on the net that uses special libraries (e.g. NewSerial.h) but I'd like to stick to the stock Arduino setup if possible.

Thanks,
DS

coyote20000
Posts: 339
Joined: Mon Jun 07, 2010 12:27 pm
Location: Rahway, NJ

Re: Serial Graphic LCD 128x64 with Arduino: Hello World code?

Post by coyote20000 » Tue Jun 29, 2010 5:52 am

Try this... I think it will work..

void setup()
{
Serial.begin(115200);
Serial.print("Hello World!");
}

void loop()
{
}

doctor_speed
Posts: 3
Joined: Mon Jun 28, 2010 1:28 pm

Re: Serial Graphic LCD 128x64 with Arduino: Hello World code?

Post by doctor_speed » Tue Jun 29, 2010 9:59 am

Hi,

Thanks for responding to my post. In your code example you don't configure the digital line. What pin would the serial ackpack's input be connected to?

Does it default to TX?

Thanks,
DS

coyote20000
Posts: 339
Joined: Mon Jun 07, 2010 12:27 pm
Location: Rahway, NJ

Re: Serial Graphic LCD 128x64 with Arduino: Hello World code?

Post by coyote20000 » Wed Jun 30, 2010 5:21 am

The RX pin of the packpack goes to the TX (Pin 1 digital) on the arduino.

doctor_speed
Posts: 3
Joined: Mon Jun 28, 2010 1:28 pm

Re: Serial Graphic LCD 128x64 with Arduino: Hello World code?

Post by doctor_speed » Thu Jul 01, 2010 6:17 pm

Mr. Hashbrown,

You rock! That worked. Thanks for your help. :D

-DS

coyote20000
Posts: 339
Joined: Mon Jun 07, 2010 12:27 pm
Location: Rahway, NJ

Re: Serial Graphic LCD 128x64 with Arduino: Hello World code?

Post by coyote20000 » Mon Jul 05, 2010 1:11 pm

Anytime man.
:D

stuart007
Posts: 5
Joined: Fri Mar 16, 2012 5:28 am

Re: Serial Graphic LCD 128x64 with Arduino: Hello World code

Post by stuart007 » Fri Mar 16, 2012 6:11 am

Hi Guys

How do you pass special commands to this LCD. The "Graphic LCD Serial Backpack Datasheet" says you can pass special commands, like 0x7C 0x00 to clear screen for example.

Just not sure how this is done in the arduino code...

fll-freak
Support Volunteer
Posts: 1518
Joined: Tue May 12, 2009 8:23 am
Location: New Hampshire, USA
Contact:

Re: Serial Graphic LCD 128x64 with Arduino: Hello World code

Post by fll-freak » Fri Mar 16, 2012 3:00 pm

DANGER DANGER. Using the Rx and Tx lines is fine in a finished system. But if you are using the Arduino's USB port to program, all those funky bytes go to the LCD as well. You risk changing the configuraiton of the LCD in such a way as you can no longer talk to it easily. Simple solution is to disconnect the LCD before each time you program it. Adding a switch in the data lines makes it simpler. Or learn to use the softserial library to use digital pins to bit bang the serial.

Post Reply