I need Bare Minimum for a serial LCD "Hello World"

I have a matrix orbital LK162-12 serial LCD display. It is the same one on the arduino playground serial LCD tutorial if you can imagine that. In fact if you google serial LCD Arduino this page comes up first.

http://playground.arduino.cc/Learning/SerialLCD

So I am not sure who the guy that said arduino is good to learn and there are lots of examples and people that help. Ummm Yeah right. So far every single example put forth by arduino on its site or plyground just simply dosent work its outdated code from arduino updates etc. etc. etc.

So I am asking again Does anyone have the bare minimum instructions, code, tutorial, etc. etc. (THAT WORKS ANS IS NOT OUTDATED CODE(How you can have outdated code on your own product and have your own examples on your site be outdated I dont know)) All I want it to do is say hello world.

For example i bought the r3 motor shield...why...? There are no examples at all lessons etc period anywhere and i had to figure it all out myself for a week and it was pretty damn simple if someone had a single page with one example from arduino.

Anyway yeap as you can guess that example is so full of errors and things i have to change let alone has about a million too many lines on it blocked or unblocked by // and the guy is just like keep what you want etc. not helpful at all.

If i go back to whatever version of arduino IDE this guy used when this webpage was made would it work or has it always been BS?

and i mean to tell you i have looked and looked and looked for an example or tutorial they are all shit or outdated or they just say do this and dont explain how. I am about to just sell off all my arduino crap as its no use to me if they dont have current examples what a joke.....

I did figure out about removing the byte a while ago and it still does not work on my display or on the serial monitor hence my being upset with arduinos basic tutorials really really fall short in the LCD department if not are actually negative since they are all wrong and i am one of what has to be many that spent a lot of time trying to figure it out with no actual stable reference.

here is what the serial monitor puts up for me ï ¼­?®Ö ¼­?®Ö ¼­?®Ö and yeah it just about looks like grabage like that on my display also. Have you tried the code you edited for me there on your serial monitor? Thanks for the help but this is what i mean people say this is the problem or that is and like arduino they seem to take more time programming responses to errors, changing their code up, or taking time editing the page like you did when all i really need is the basic most most most most most basic hello world and it seems No one including anyone reading this knows what that is.

So again i am asking for the basic hello world sketch to talk to a display No one in months has been able to answer that so go community. At what point does leaving wrong instructions up and leaving freaking links to it in your actual examples page etc do more harm than good? maybe they should replace it with a real simple hello world to see if the damn display is working before you put 50 commands up in the text like the example above. if no one can show a hello world sketch to me then what the hell chance do i have of getting any other help and or succeeding in any project i think up.

I tried it with the baud rate reset jumper it still has problems. basically it used to say "12hello world12 " adn i think it was an error in code but at some point i messed up the display and now its gibberish.

I have other displays brand new like thsi one was but i am actually going to try and use my serial port on the back of my pc to connect the lcds as i know they work that way perfect and just route the arduino data through my pc and the IDE out the serial port com 2 or whatever it is to my lcd's.

This would save my time and save me from soldering my displays and maybe ruining them until i am familiar with the arduino code and can make it say hello world or what i want then i will worry about hooking up the display directly to the arduino when i know the code is taken care of.

Thanks for your help anyway. here is the code i found as the hello world that is the simplest.

/*
 * Hello World!
 *
 * This is the Hello World! for Arduino. 
 * It shows how to send data to the computer
 */


void setup()                    // run once, when the sketch starts
{
  Serial.begin(9600);           // set up Serial library at 9600 bps
  
  Serial.println("Hello world!");  // prints hello with ending line break 
}

void loop()                       // run over and over again
{
                                  // do nothing!
}

ghost2501:
soldering my displays and maybe ruining them

Since you are having so much strife with this display, ruining it sounds like a pretty good option. This just might then give you sufficient motivation to invest $3.25 in a proper, up-to-date HD44780 LCD that, not only will everybody know, love, and understand, but also runs with established software that you already have - and stands a good chance of doing so first time.

http://www.ebay.com.au/itm/LCD-HD44780-1602-16x2-Character-Display-Module-Blue-Blacklight-For-Arduino-/190782257646?pt=AU_B_I_Electrical_Test_Equipment&hash=item2c6b8239ee

The Arduino is a moveable feast. All you have to do move with it. Right now, you seem to be flogging a dead horse, a horse I'm afraid I never knew existed.

This just might then give you sufficient motivation to invest $3.25 in a proper, up-to-date HD44780 LCD that, not only will everybody know, love, and understand, but also runs with established software that you already have - and stands a good chance of doing so first time.

I thought this thread was about using "a serial LCD"....

Don

OK guys its not hard to understand I bought a brand new LK162-12 matrix orbital R2.220 http://www.matrixorbital.com/product_info.php?products_id=73

My point is everyone is complicating things instead of just giving the simple hello world example. Its 50 questions etc etc. I just want an example that works as the ones from arduino website do not and are outdated. The examples do not even work on the serial monitor so they sure as hell will not work on my serial display right?

if you dont understand stop here and read that last paragraph again. Then read it again if you have to.

For the guy saying soldering my displays may be ruining them i have many displays all new some i modified some i didn't so i would have a new unmodified display to compare too all along etc. you know the control example, scientific method. All i did was solder the TTL comunication jumpers so i can hook it into the arduino.

Somewhere along the lines with the BS code from arduino playground and their updates etc i must have hooked a wire wrong from rx to tx etc. or something in the 50 times i hooked and unhooked the display trying to get it to say hello world with outdated and incorrect code and now its garbled. I have another fresh new display actually 5 of them so I can move forward but first:

BEFORE I TRY HOOKING UP A LCD TO AN ARDUINO AGAIN CAN ANYBODY......ANYBODY AT ALL GIVE OR CONFIRM THE CODE I MADE UP IS THE BASIC HELLO WORLD FOR A SERIAL DISPLAY. OTHER THAN THAT I DO NOT CARE FOR YOUR COMMENTS. AND BY ALL MEANS IF YOU HAVE A MORE SIMPLER ONE OFFER IT THAT IS ALL I WAS ASKING ALL ALONG AND NO ONE AT ALL HAS EVER EVEN COME CLOSE TO ANSWERING IT.

/*
 * Hello World!
 *
 * This is the Hello World! for Arduino. 
 * It shows how to send data to the computer
 */


void setup()                    // run once, when the sketch starts
{
  Serial.begin(9600);           // set up Serial library at 9600 bps
  
  Serial.println("Hello world!");  // prints hello with ending line break 
}

void loop()                       // run over and over again
{
                                  // do nothing!
}

You haven't told us much about what you have done on your part.

Are you sure that the default baud rate for your device is 9600?

Are you sure that you have connected the Tx and Rx lines to the appropriate pins on the Arduino? Note: Before you make any wise remarks you should research this topic.

DON"T SHOUT AT THE PEOPLE WHO ARE TRYING TO HELP YOU.

Don

floresta:
You haven't told us much about what you have done on your part.

Are you sure that the default baud rate for your device is 9600?

Are you sure that you have connected the Tx and Rx lines to the appropriate pins on the Arduino? Note: Before you make any wise remarks you should research this topic.

DON"T SHOUT AT THE PEOPLE WHO ARE TRYING TO HELP YOU.

Don

I am not asking for help i just want a standard serial example for hello world. I have other threads for the problems you guys are trying to solve I have explained i dont need help for those really anymore i got it pretty much squared away but all along that time still noone has given a good serial example i guess i will just go with this one as it works in the serial monitor but still noone can confirm it if works on their serial lcd or provide a standard hello world to me that is confirmed to freaking work so i can move on from there, so yeah so much for this site not much help as you never get replies to what the freaking subject is or what you ask for.

I gave all that info in the first place to explain why even now more than ever its important to as the title of my post suggests------> I need Bare Minimum for a serial LCD "Hello World" and to try and head off all the what are you trying to do questions etc. but it backfired.

That is i need the bare minimum of ARDUINO CODE for hello world on serial i dont need anything else. can anyone understand that

comment as follows:

  1. oh sorry i was just trying to help you but i dont know the bare minimum arduino code for hello world and i will move on good luck.

OR

  1. here is what i use for bare min code for hello world on serial, or i will try your bare min code on my serial lcd to see if it works.

NO NEED AT ALL TO RESPOND SAYING ANYTHING OTHER THAN 1. OR 2. ABOVE THANK YOU I CANT BE MORE CLEAR AT THIS POINT.

Sorry I confused you all with the original post but when i try to just say what the title of the post asks I need Bare Minimum for a serial LCD "Hello World", all i get is what are you trying to do if you are trying to do this do this etc. etc. etc. what display are you using etc.etc. they ignore what you are asking.

I am asking for arduino code for any serial lcd to say hello world. nothing more. The info i put in was to thwart off everyone asking what i tried so far what i am trying to do what lcd i have but i guess it backfired. so maybe i will post another post and ask literally only what is the bare minimum arduino code for a serial lcd to say hello. emphasis on Bare Minimum.

you can check my past posts and see they all spiral into madess but my original question remains:

All the arduino code on all the websites for serial lcds are outdated by outdated i mean i understand the arduino code changed and thanks but everytime somone changes all the outdated stuff and submits it to me as fixed form the original serial lcd example in the arduino playground it still, still does not work and returns random characters on the serial monitor. so you run the code on your arduino serial monitor to see the code you just spent time on and provided my with still still does not work even on your PC so who are you helping why are you wasting your time all i want is the bare minimum serial for hello world as the arduino example on the playground is obviosly too complex even for the 2-3 guys they keep trying to edit it down after i post it and it still dosent work for them then maybe you can see why i originally was confused and asking for the bare minimum hello world for lcd and not complicating it any further is an actually worth goal for me but keeps spiraling into madness for some reason so yeah.......

here is a post i made in September still same question and point by me but still the same responses, people fixing the code but not checking it in their serial monitor to find the arduino example after being fixed is still poop in poop out. I just dont know how much clearer i can ask really.

http://forum.arduino.cc/index.php?topic=124140.msg933051#msg933051

I am asking for arduino code for any serial lcd to say hello world. nothing more.

This is impossible, which is why you are getting questions instead of answers.

The code that you presented in reply #8 may work if:
(1) The device you are communicating with is set up to work at the same baud rate and
(2) You are not trying to put data into the output pin of the display.

So, once again, here are two questions that must be answered before we can proceed:
(1) Are you sure that the default baud rate for your device is 9600?
(2) Are you sure that you have connected the Tx and Rx lines to the appropriate pins on the Arduino?

Don

First, I confirm your sketch works on my nameless serial display.

A simpler version of the code:

  • removed comments that are obvious from code
  • replaced println with print => on a serial display you normally do not to use \r\n, but position text explicitly. This differs from a terminal with "endless" number of lines/rows
void setup()               
{
  Serial.begin(9600);
  Serial.print("Hello world");
}

void loop() 
{
}

For a Serial Display you only need to connect the Arduino Tx line to the Serial Display Rx line and of course the ground line.

Elaboration of the question:
The problem with the above sketch is that it has a fixes baud rate and thus will not print on all serial display's.
AFAIK there is no serial display that can be interrogated what its baud rate is as you need the right baud rate for that.
Note: protocols exist to solve this for bidirectional serial devices, but a display is not.

A possible work around might be to send the string on all "well known" baud rates. Lets see, that would be something like this
(this is code for IDE Serial Monitor version)

int rates[] = { 300, 1200, 2400, 4800, 9600, 14400, 19200, 28800, 38400, 57600, 115200};
int rateCount = 11;

void setup()               
{
  for (int i=0; i< rateCount; i++)
  {
    Serial.begin(rates[i]);
    Serial.print("\nHello world @");  // Serial.print("Hello world @"); // serial display version
    Serial.println(rates[i], DEC);     // Serial.print(rates[i], DEC);
    Serial.end();
    delay(1000);
  }
}

void loop() 
{
}

The Serial Monitor of the IDE fails on the sketch above (added \n's to let the readable line pop out of the garbage) so I do expect a serious chance of garbage on any Serial Display.

Note: the IDE does some wonderful things at 14400 and 28800 baud => wonderful? just plain buggy

Note: really small display's e.g. - http://www.newhavendisplay.com/lcd-character-1-x-8-characters-c-2_76.html - cannot hold the text as it is too long
=> OK not serial but can be made serial with additional HW.