LCD Display Shows All White on Top Row - Need Help!

Hello everyone,

I am experiencing an issue with my LCD display. The top row is completely white (filled with blocks) and does not display any text, while the bottom row remains blank. Here are the details of my setup:

Hardware:

  • Microcontroller: Arduino Uno
  • LCD Model: 16x2
  • Temperature Sensor: DHT11
  • Wiring: I am using the following pin connections:
    • LCD RS: Pin 12
    • LCD E: Pin 11
    • LCD D4: Pin 5
    • LCD D5: Pin 4
    • LCD D6: Pin 3
    • LCD D7: Pin 2
    • DHT11 Data Pin: Pin 6
    • Fan Control Pin: Pin 7

Here is the code I am using:

#include <dht.h>
#include <LiquidCrystal.h>

LiquidCrystal lcd(12, 11, 5, 4, 3, 2);  // (RS, E, D4, D5, D6, D7)

// Button Pin
const int fanPin = 7;
const int tempPin = 6;

dht DHT;

void setup() {
    lcd.begin(16, 2);
    pinMode(fanPin, OUTPUT);
    pinMode(tempPin, INPUT);
    Serial.begin(9600);
}

void loop() {
   DHT.read11(tempPin);    
   digitalWrite(fanPin, HIGH);
   
   // Clear the LCD at the beginning of the loop
   lcd.clear();
   lcd.setCursor(0, 0); // Set cursor to the second line
   lcd.print("Proj 3 - ");
   lcd.print(round((DHT.temperature * 1.8) + 32));
   lcd.print(" F"); // Add unit for clarity
   
   // Print to Serial Monitor for debugging
   Serial.println(round((DHT.temperature * 1.8) + 32));
   
   delay(1000); // Wait for 1 second before the next reading
}

Troubleshooting Steps Taken:

  1. Checked all wiring and connections multiple times.
  2. Adjusted the contrast potentiometer.
  3. Tested with a simple LCD example code (only displaying text).
  4. Verified that the temperature sensor is functioning.
  5. Tried a different LCD (if available).
  6. Reinstalled the LiquidCrystal and dht libraries.
  7. Power cycled the setup multiple times.

Observations:

  • The top row is completely white and does not display any text.
  • The bottom row remains blank.
  • The LCD was working previously with the same code.

Questions:

  • What could be causing the top row to display all white?
  • Are there any additional troubleshooting steps I can take to resolve this issue?

Thank you for your help!

The controller for the LCD has a different address than you one you are trying to use. I have several of those LCD and many time I get the same result as you describe. Changing the program to use the second possible address results in perfect operation and display.

Note, there is also a sample program that comes with the IDE that will scan your display and tell you the correct address.

?

This doesn't seem to be an i2c LCD.

What address do you mean? Do you mean the LCD address? Because if so, I checked under my LCD and it said 1602, which means 16x2. I am pretty sure. If not, please help me find which address you're talking about!

This usually means an incorrect connection. Maybe post some bright, clear photos of the circuit, taken from directly above.

Try the LCD example sketch again. You seem to be saying you tried this already, but maybe something important has changed since then.

If that example sketch no longer works, start removing (commenting out) other parts of the code, one by one, re-testing after each change.

Is this a 4-pin 12V PC fan? Is it connected? Did you try a flyback diode and/or noise suppression capacitor?

What do you see on serial monitor?

likely to be so. Wonder why people make it so difficult when the I2C is so easy.

I2C? I am thinking @noxid1 would have found it difficult to connect it to 6 Arduino pins if there was already a backpack soldered to the LCD. But let's see when photos are posted.

What do you get in most starter kits? An Uno, a breadboard, a 1602 LCD without a backpack, a DHT11...

1 Like

My fan is a 2-pin 12V, and yes, it is connected. Then, on the Serial Monitor, I see the displayed temperature in my household between 70 to 72. Will this help?

  1. Adjusted the contrast potentiometer.

Did adjusting the potentiometer change the appearance of the top row?

Yes, @cattledog I did adjust the potentiometer a lot of times, and I still can't see any characters. Is there any way to fix this?

Make certain the pot setting has the top row just starting to come off the full on bright white.

Can you post a photograph showing the soldering of your lcd to the header pins.

I can't show a photo, but the rectangles where words and numbers can be displayed are white. When I turn the potentiometer, it dims, but it still doesn't display text.

:grinning_face:

If the display once worked with the soldering and code you have, the perhaps some of the header pins has lost connection. Are the headers pins plugged into a breadboard?

Why can't you show a picture of your soldering and how things are connected.

It's possible if everything was once working correctly and now it is not, then its possible that something (voltage spike, static, bad juju) damaged the hd44780 controller on the display and its broken.

What does this mean? Did you try a different display or not?

  1. Tried a different LCD (if available).
1 Like

How is it connected?

Or a fan connected directly to an Arduino pin with nothing to limit the current or protect from the negative voltage that would be generated when the fan is switched off...

Are you going to post the photos I suggested in post #5?

1 Like

My fan's GND is connected to the power source's GND, and the voltage is connected to the relay output. The power source voltage is connected to the relay output, then the relay GND is connected to the Arduino 5V, and the signal is connected to Arduino pin 7.

Can anybody help please! If you can please tell me what I need to fix!

Have you tried without the fan and dht temperature sensor, and just run a simple lcd "HelloWorld" library example?

If simple code won't run and you wiring is correct as you insist, then either the controller on the lcd module is broken, or somewhere between the pin holes on the module and the connection to an Arduino pin there is a disconnect. Most frequently it is from the solder connections at the lcd, or the bread board connection where pins from the lcd are pressed in. Dupont connector wires are often defective and you can try change those.

Without any photos, I can't give any more advice.

1 Like