1
\$\begingroup\$

I have a 16x2 LCD display that I'm just trying to use for the first time. The model number is 1602D1 according to this datasheet from where I purchased it. I first tried attaching it to a Raspberry Pi using Adafruit's tutorial, which had the same pinouts as the LCD display I have. Now I've tried using an Arduino and I get the same results, which are shown in the picture below.

enter image description here

The LCD display never updates when I try to send text to it and only displays the blocks in the bottom row. Adjusting the 10k variable resistor doesn't seem to do anything. When I send data to the LCD, I notice it flickering slightly as if its updating, but no text is displayed. I'm simply using the code from tutorials, nothing special. Any ideas what I am doing wrong? Thanks.

For clarity because the picture might be misleading, here is how I have the pins hooked up:

LCD Pins:

  • LCD 1 - Ground
  • LCD 2 - 5V
  • LCD 3 - 10k Variable resistor middle pin
  • LCD 4 - Arduino 12
  • LCD 5 - Ground
  • LCD 6 - Arduino 11
  • LCD 7 through 10 empty
  • LCD 11 - Arduino 5
  • LCD 12 - Arduino 4
  • LCD 13 - Arduino 3
  • LCD 14 - Arduino 2
  • LCD 15 - 5V
  • LCD 16 - Ground

Variable resistor:

  • Left - 5V
  • Middle pin - LCD pin 3
  • Right - Ground
Bence Kaulics
6,47312 gold badges35 silver badges61 bronze badges
asked Mar 18, 2015 at 18:20
\$\endgroup\$
4
  • \$\begingroup\$ Its not entirely clear from your pic, but it looks as though you've got pin 4 of your LCD tied to ground (through the 2 green wires) as well as over to your arduino. \$\endgroup\$ Commented Mar 18, 2015 at 18:34
  • \$\begingroup\$ No, I have pin 5 tied to ground. Pin 4 goes to arduino pin 12. I'll edit my question to clarify. \$\endgroup\$ Commented Mar 18, 2015 at 19:00
  • 2
    \$\begingroup\$ That's actually the top row, and the display hasn't been initialized properly. \$\endgroup\$ Commented Mar 18, 2015 at 19:11
  • \$\begingroup\$ The LCD by default is in the 8-bit mode. Did you send the proper init sequence to it to use the 4-bit mode? It's probably a matter of calling the right init from the library. \$\endgroup\$ Commented Mar 18, 2015 at 19:35

1 Answer 1

5
\$\begingroup\$

You're reading the pins upside down.

whatsisname
1,4441 gold badge10 silver badges16 bronze badges
answered Mar 18, 2015 at 19:41
\$\endgroup\$
1
  • 2
    \$\begingroup\$ Hey you're right. Doh! It works great now. Good thing I didn't fry anything. I should be more careful next time. \$\endgroup\$ Commented Mar 18, 2015 at 19:43

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.