Help me connect my LCD to my mega !

hi 'wismie', i have the exact same problem as u, im (my LCD looks different) but its using the same 'HD44780' chipset, (with another chip 'sanyo'), the model of this LCD is 'OPTREX dmc16249'
with only 14 pins (it has no backlight)

i too am a newbie to arduino, i love it, but would hope to get it displaying on LCD, so for the next few project we can out the data (e.g resistance of pot or temperature data to LCD) but i seems to have same issues as u

by screen shows 2 lines of blocks. and my contrast control works too, so i suppose the pin wiring to power are working..

hope to get some replies, altho i can understand how difficult it is to troubleshoot this, via post.

Wismie's problems were due to incorrect wiring and that is also likely in your case if you have the same symptoms.

Triple check that your wiring uses exactly the same pins as you have in your sketch. If it still does not work, post the pins you are using and a clear photo of the wiring

... screen shows 2 lines of blocks. and my contrast control works too, so i suppose the pin wiring to power are working.

The power may be working, but the contrast may be adjusted improperly. A two line display that is not initialized will show only one line of dark blocks when the contrast is properly adjusted. A four line display will have the first and third lines dark. The other line(s) of blocks may be faintly visible. If both (all) of your lines of blocks appear dark then try turning the contrast down.

Don

hi [floresta], [mem],
thanks for the reply,
i did try again rewiring it yesterday in this setup

my code for mapping pins is :-
LiquidCrystal lcd(12, 11, 10, 5, 4, 3, 2);

I checked with the documentation: dmc16249.pdf

this is their Pin Assignment:-

LCD Pin No. Symbol
1 Vss
2 Vcc
3 Vee
4 RS
5 R/W
6 E
7 DB0
8 DB1
9 DB2
10 DB3
11 DB4
12 DB5
13 DB6
14 DB7

This is how i wired my arduino to the LCD

LCD Pin. To:
1 Ground
2 5V / 1st pin of Pot
3 Middle Pin of Pot
4 Ard:12
5 Ard:11
6 Ard:10
7
8
9
10
11 Ard:5
12 Ard:4
13 Ard:3
14 Ard:2

The wire configuration is different as compared to my first attempt, but i got same result, 2 row of i think 8 full blocks. One interesting discovery was when im done, i touched the LCD and found the 'hitachi hd44780a00' chipset to be hot,

could i have still miswire it or am i connecting it in the wrong order?
i will take a photo of it and show you guys, hope with the photo you guys would have better idea..
thanks all

1       Ground

This should also go to the other end of the pot.

i touched the LCD and found the 'hitachi hd44780a00' chipset to be hot,

Do you have a datasheet. There are some oddball LCD's but Optrex is typically not one of them) with the power connections reversed (pin 1 = 5V, pin 2 = GND).

[EDIT] I just noticed that the modules that I have been using for 20 years are DMC16249s - they are quite normal and I do not remember them running hot.

am i connecting it in the wrong order?

Pin 1 is almost always near the edge of the PC board and pin 14 near the center.

[Edit] Take a look at the photos in this thread (scroll down for the photos): http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1265969050/0

Din

Take a look at the photos in this thread (scroll down for the photos): http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1265969050/0

Din

You changing your name now?

Oops

floresta: Pin 1 is almost always near the edge of the PC board and pin 14 near the center.

thanks floresta, guess what! i suppose for alot of arduino LCD newbies, this is our problem, having a headache! which ONE is pin one!

your one line response, made it so clear!

so that why the chip was so hot i wired it the wrong way and YEAAAAAA! finally

  1. contras control works properly
  2. HELLO world is finally displaying!!!!!

i feel like i should wrote a NEWBIES tutorial on connecting LCD to arduino.

Anyways Pix of my Newbie Project

And this is the Pin Number, One of the biggest problems that I face was to determine which is Pin on the LCD was pin No 1, as its not marked on the PCB board, and the datasheet does not show any diagram.

The cause of confusion is that for most example LCD, rather the one used in tutorials, has the LCD pins placed at the bottom, but for this model the LCD is at the top. But i assume that these pins are at the bottom this my wiring was wrong and so causing the chip on board to heat up! Quite glad that didint killed the LCD.

...which ONE is pin one!

Now that you know - take a look at the markings on the pc board and you will almost always find the pins identified. Look for a "1" near pin 1 and a "14" near pin 14. On my Optrex DMC16249s the information is next to the pins, on the top of the board. On my other LCD modules the information is on the bottom side of the board.

Don

on the pc board and you will almost always find the pins identified. Look for a "1" near pin 1 and a "14"

your right, its there, but not obvious, look like a line, and no 14 is only visible after i scratch some solder dirt of the pcb

but its there, alright, thanks for the tip, next time, this should be the first thing to look for, the LCD tutorial badly needs to be updated with this info.