Many times people ask questions about how to fix their LCDs that don't display or displays wrong/random stuff. The following information, when supplied with your thread, will get your problem solved the quickest way. Fixing these problems ends up being mostly a frustrating experience unless the following are provided upfront without any "BUT"s. I believe several other helpers here would agree with me.
Provide what display or display shield you are using, with a link to the product page or spec sheet. 99% chance no one else on this forum has your exact display but having a spec sheet will be the closest to having that display in hand.
Provide what code you used, copy from your arduino IDE and paste it properly with the code tag, press #. Again no one will have your exact code even if you think it's THE standard code. There is a lack of standard here so everyone needs to have what you have to help.
Provide clear high-resolution pictures of your connection between arduino and LCD, giving enough angles/shots to allow someone to physically trace every wire from point A to point B. Your "My circuit is correct and beautiful" argument stands better if you accompany your argument with a few clear pictures. If you drive a car, you wouldn't want an online mechanic to fix your car without even seeing the picture of your beautiful car, would you?
In case your display is not behaving the way you want it to be, say it displays xyz when you tell it to do abc, provide some pictures of the wrong info and tell us whether the display always does this wrong in the same way or random wrong way.
Be polite to critiques. I rarely see helpers does nothing but ridiculing the help seekers. But too often the help seekers were too arrogant/ignorant to accept any critique. If you want to be applauded, hire someone of buy a magic mirror that can lie to you.
Return the favor by posting "yes, ... was exactly the problem. Now I did ... and it's fixed!". Create a proper closure.
Fill up your location information could get you more help sometimes. Say you're asking about suppliers of certain LCD and with your location people can suggest you local or regional suppliers.
Now happy solving problems
A list of frequently committed mistakes:
Hardware problems
H-1) Didn't connect ground from arduino to breadboard
H-2) Didn't use a potentiometer with the contrast pin
H-3) Didn't solder headers to the LCD but just rest the LCD on the headers instead
H-4) Shorts due to soldering
H-5) Didn't have a current-limiting resistor with the back light
H-6) Read the pin numbers backward thus thinking pin 1 is pin 16 etc.
H-7) Broken LCD, against all our hopes you have a broken LCD to start with, no fixes. Get a new one.
H-8) Didn't deal with R/W (LCD pin 5) correctly. You should tie this pin to GND.
Software problems
S-1) Used the wrong pin number in your sketch
S-2) Tried to use lcd.println. There is no such function so you will see two strange characters with your text
S-3) Did not have lcd.begin(col,row); in setup
S-4) Had lcd.begin in loop (could cause LCD to flicker due to resetting the display too often)
S-5) Used old or wrong library, such as given on irresponsible eBay sellers. If you are using an I2C backpack, stick to the seller's library!!!
GLCD specific problems, written by bperrybap:
G-1) not hooking up the RESET pin (works on some glcds but not all of them)
G-2) Confusing RESET and RS signals.
G-3) hooking up the glcd contrast pot to +5v and gnd (like a hd44780 pot) vs +5v and Vee (besides the gnd vs VEE issue, bad pot wiring is very common and happens all the time even when there are instructions in multiple places and diagrams for how to properly wire up the contrast pot)
G-4) hooking up the pins incorrectly because of wrong documentation. (hd44780's for the most part all have the same pinout) Users often assume there is a single "ks0108" pinout - yet I've seen over 11 different pinout combinations.
G-5) hooking up the pins incorrectly because of the wrong part (people often buy a "glcd" and assume it is say a ks0108 when it isn't)
G-6) using multiple wires for a single connection and twisting wires together. (This one creates all kinds of weird problems)
G-7) miscounting/interpreting pin #s on the mega board. I see this quite a bit. People sometimes start at the top for pin 22 and forget the +5 pins along the top or get the left/right pins backwards or get the pins skewed or off by 1 because of a visual parallax error when picking the pins.
G-8) getting all the LCD pins backwards. Look at the data sheet and then wire everything backwards because the view was upside down which flips the order of the pins.
G-9) Powering the display and Arduino from different power supplies and getting ground loops that crater everything.
Tutorials:
http://www.ladyada.net/learn/lcd/charlcd.html
arduino.ccThe Arduino programming language Reference, organized into Functions, Variable and Constant, and Structure keywords.
Unlike older cathode ray tube (CRT) displays that scan an electron beam over a phosphor screen to create light, LCD displays are composed of a fixed grid of tricolor pixels that change transparency based on a range of voltage levels provided by the monitor's controller. Without a voltage the pixel is opaque and blocks the screen's backlight from transferring through it, and when a full voltage is applied then the pixel allows full transmittance of the backlight. When this is done over the entire pixel grid in patterns, then you see those patterns on the screen.
At a very basic level, the way pixels work is a voltage change alters the pixel to allow more or less light through. When there is no voltage, no light is let through (darker), and when the voltage is at its maximum level then 100 percent of the light is allowed to pass through (brighter). By supplying intermediate voltages the computer adjusts the pixel's transmittance levels for its three color components, to display various combined colors and intensities.
This pixel-based setup for LCD monitors provides many advantages over CRT displays, but does have potential drawbacks arising from the fact that the image is dependent on millions of independent electrical components as opposed to a single scanning beam, so if faults occur in these components then the display output can be affected. The resulting problems include stuck or dead pixels, as well as a residual image effect.
Fixing stuck pixels
One of the more common problems with LCD displays is the potential for stuck or broken pixels, where the pixel either does not receive a voltage and remains black, or does not respond to voltage changes and stays at a set luminance level. Sometimes this can happen for individual pixels, suggesting a problem with the pixel itself, or it can happen to groups of pixels, suggesting the possibility of problems with the display's controller or a defect in a portion of the pixel grid.
When stuck or broken pixels occur, there are a couple of things you can try in order to fix the problem. One is to apply a small amount of pressure to the pixel when turning the display on or off, which can sometimes help stimulate the electronics to work properly. Unfortunately, Apple's glass-covered glossy displays prevent this from working on modern Mac systems.
The alternative to using pressure is to exercise the pixel's electronics by using a program that displays quick-changing patterns on the screen and thereby rapidly switches the pixels on and off. Three such programs that will work on the Mac are the following:
Do keep in mind that fixing stuck or dead pixels can be a hit-or-miss process, so do not be surprised if a broken pixel does not come back to life.
Fixing LCD residual images
LCD monitors can also be affected by another problem called "transient persistence" that is reminiscent of CRT burn-in. Classic burn-in would happen because the phosphor coating on the screen would get depleted by the persistent bombardment of electrons from the CRT, resulting in the inability of those sections of the display to convert the electron beam to visible light. This meant that if you kept a specific pattern showing on the screen then over time it could become a permanent residual image on the display that would show even when the display was turned off. This was a reason why screensavers were developed--to keep the wear on the screen's phosphor coating as even as possible.
The physical burn-in of displays is no longer an issue now that LCD displays have taken over, but while transient image persistence is not a physical burn of the device, it is an alteration of the pixel response to voltage changes (usually temporary) that prevents pixels from getting as bright as others on the screen.
Similar to CRT burn-in, LCD image persistence generally happens after you have displayed a pattern of intense colors on screen; however, unlike CRT burn-in, LCD persistence can sometimes set in after only a few hours of displaying the image, as opposed to the weeks or even months that it can take for burn to set in on a CRT monitor. Additionally, unlike CRT burn-in, image persistence can often be reversed.
What happens with LCD monitors is the affected pixels have lost their ability to respond to the full range of voltages that the display gives them, resulting in a limited range of colors that can be output. This can happen if the pixel is acting like a capacitor and is retaining a residual charge, or if it is not able to reach the level of luminance that is desired when given a specific voltage. Either way, the pixel is not able to reach its full range of possible intensities.
Unlike stuck or dead pixels that may benefit from having the monitor turned on and off rapidly to produce rapid voltage changes, image persistence will benefit from a lengthy stretching of the pixel's range. Therefore, instead of using tools like JScreenFix to run random patterns over the affected screen area, you might instead place a pure white window (such as an empty TextEdit window, or what you get using the "White" option in the LCD Repair tool listed above) over the affected area for a few hours or even a few days if necessary. Doing this will force those pixels to be fully on, and over time their intensities may increase to be the same as the surrounding pixels.
Likewise, try turning off the pixels fully by shutting down the display for a long period of time or placing a pure black texture over the affected area (see the LCD Repair tool listed above for this option as well). This will turn the pixels completely off and allow residual voltage in them to drain slowly over time.
Beyond pixels
So far we have discussed pixel-based problems with LCD displays, but the system's backlight can also suffer some common problems that include the backlight randomly blinking off, not turning on, or only illuminating part of the screen.
fiendie
When the display fully cuts out and does not show any light, one possibility could be that your computer is not properly communicating with the display, or the display's controllers or power supply are not working properly. If this occurs, try connecting the display to another system. But if power LEDs and other indicator lights turn off when the backlight goes out, then it may be your display's power supply is failing.
If only the backlight is malfunctioning, then the LCD panel itself should still be working just fine and should be rendering the text and images of your computer's output. To test for this, use a bright flashlight and shine it on your screen at an angle in an area where you expect images and text to be (such as the Dock or menu bar). On Apple's laptop systems, you can shine the flashlight through the Apple logo on the back to illuminate the screen on the front and better detect text and images that way.
If shining an alternative light source on the display causes graphical content to show up, then either the backlight or some component involved in controlling it (such as the power inverter for it) have failed and will likely need to be replaced, especially if you cannot rectify the problem by restarting the system, resetting PRAM and SMC, or otherwise toggling different hardware and software settings on your system.
Questions? Comments? Have a fix? Post them below or e-mail us!
Be sure to check us out on Twitter and the CNET Mac forums.