LCD only show squares - SOLVED

Hey!

I'm new here an I need you help. I've search in a lot of other threads for a solution, but I got no one.
So i try to get help here :slight_smile:

My Problem...
I want to use a LCD-Display (Model pinted on the back: SCM1602C) with my Arduino 2560Mega. But all I got are some squares in a row (Photo). No flashing, no blinking. Such these solid LCD-Blocks ... :~ :~ :~ I tried a lot of different things. Change Breadboard and Cables, using another LCD-Pannel, soldering the pins again.
The code i use is the default "LiquidCrystal-HelloWorld"-Example, which is coming with the default "LiquidCristal.h"-Libary.

The Connections are correct and set like in this Diagramm. Here is a Picture of my setup.

This is driving me crazy. I'm realy glad for every advice! Please help!

Here is a Picture of my setup.

Try to take a better picture, perhaps outside where there is more light, so that we can easily follow each of the wires.

Here is my generic step by step approach that should work:

(1) If the module has a backlight then get it working properly. This involves only pins 15 and 16 on your LCD module. Make sure to use a current limiting resistor if there is none on the LCD module.

(2) Get the power and contrast working properly. This involves only pins 1, 2, and 3 on your LCD module. You should be able to see blocks on one row of a two row display and on two rows of a four row display.

NOTE: The Arduino has not been used yet, except as a possible source for the power needed for the first two steps. Do not try to go any further until this is working. If you don't see the blocks then no amount of program code will help.

(3) Connect the LCD R/W pin (pin 5) to GND.

(4) Connect the six control and data wires between your LCD module and your Arduino.

(5) Upload your sketch and it should work.

If you still don't get a display then make sure that your wiring matches the numbers in the descriptor (or vice versa).

//LiquidCrystal lcd(RS, E, D4, D5, D6, D7);
LiquidCrystal lcd(7, 8, 9, 10, 11, 12);      // put your pin numbers here

If you get a display but it is garbled or has some other problems then try again with a 'static' sketch, one that displays a simple message on the top row of the display and then stops. All of your code should be in setup() and loop() should be empty between the brackets.

If you are still having problems then we need to see a photograph of your setup that clearly and unambiguously shows all of the connections between your Arduino and your LCD module.

Don

I can't quite tell where all the wires go, but the pot looks a little strange.
It could be the photo, but the ground connection looks like it is in the same row
as the V0 pin on the LCD.
The Vo pin should be the wiper, and gnd & vcc should be the ends of the pot.

OR, are all 3 pins of the pot on the one side?
Some have the 2 end pins on one side and the wiper on the other.
If that is the case, then you need to move the Vo pin wire to the other side.

--- bill

OK, to my eye your wiring checks out.

The photo indicates that you already have in fact, the LED backlight and contrast control working properly.

What I do notice which is quite wrong, is that the "block" display is the first line and part of the second line. This is not normal behaviour of the device before initialisation and I must conclude it is in fact a dud. Need to try another one. :frowning:

Paul__B:
OK, to my eye your wiring checks out.

The photo indicates that you already have in fact, the LED backlight and contrast control working properly.
Ah, there are two photos. I only saw the one of the setup.

What I do notice which is quite wrong, is that the "block" display is the first line and part of the second line. This is not normal behaviour of the device before initialisation and I must conclude it is in fact a dud. Need to try another one. :frowning:

But what if the LCD is accidentally improperly initalized from the wires not making proper connection?
Can you get that pixel effect if the F (font) bit is set on function_set command?
(F set uses something other than 5x8 font pixels)
i.e.maybe bit 2 is stuck/floating which would correspond to the wire to DB6 in 4 bit mode
or Arduino pin 11 in this wiring.
This also happens if the code does:

  lcd.begin(16,1); // single line mode

I've seen some crazy stuff on LCDs, when garbage signals are presented
to the LCD pins.
I've even seen the pixels of some characters be different contrast/intensity
compared to other characters, which I'm not sure how that is possible.

--- bill

bperrybap:
I've seen some crazy stuff on LCDs, when garbage signals are presented
to the LCD pins.

As we all know, anything is possible, but he does seem to have it pretty solidly assembled - unlike some. :wink:

There is of course that matter about scraps of varnish/ glue on those jumper leads (as well as just plain breaks at the crimps), and bad contact in the breadbaords.

bperrybap:
I've even seen the pixels of some characters be different contrast/intensity
compared to other characters, which I'm not sure how that is possible.

Perhaps the HD44780 - or the later chips now in use - have "extra" and possibly undocumented functions/ attributes.

I shall have to look up that "font set" business you mention, not aware of it so far.

For the moment however, I am chasing up the matter of floating inputs from another thread, going to use the LCD as a display for this.

Hey Guys!

Thank you so much for your tipps! :slight_smile:

I'm started with the steps given by floresta.

  1. check only the backlight "standalone".
    connect the LCD-Pin 15 with a 100 Ohm ressistor to +5V an LCD-Pin 16 to GND.
    Works perfectly!

  2. check only the contrast.
    first without backlight - so disconnected everything from LCD-Pannel.
    connect LCD-Pin 1 to GND, LCD-Pin 2 to +5V, LCD-Pin 3 to the middle from potentiometer.
    connect POT-Pin 1 to GND, POT-Pin 3 to +5V.
    Note: The Potentiometer I'm using looks a bit different and I was not shure what kind of POT it is (was in a starter-set without some documentations). So I've checked that with a Multimeter. It is a 10kOhm Potentiometer and it works properly.
    Back to contrast... this setup is working fine.

  3. Connect the LCD-Pin 5 to GND.
    Done!

  4. Connect the Data-Pins.
    LCD-Pin 4 to PWM-Pin 7, LCD-Pin 6 to PWM-Pin 8, LCD-Pin 11 to PWM-Pin 9, LCD-Pin 12 to PWM-Pin 10, LCD-Pin 13 to PWM-Pin 11 and LCD-Pin 14 to PWM-Pin 12.
    Connect the LCD-Backlight as in step 1.

  5. Load the default "HelloWorld"-Example Sketch.
    Edit the interfacePins in the Sketch to "LiquidCrystal lcd(7,8,9,10,11,12);"
    Upload and voila... my LCD talks to me! :smiley: :smiley: :smiley:

I thank you for all of your Tipps :))

I'm absolut don't know what is different from my setup before...... :frowning: