5
\$\begingroup\$

What sort of LCD should should i be using to go with my Arduino?

I have used the HD44780-compatible LCD in the past, but heard that the Serial Enabled LCDs make life a lot easier.

\$\endgroup\$
5
\$\begingroup\$

It really depends upon what you want to do with the Arduino, besides displaying information on the LCD. Like you, I used an HD44780-compatible LCD for my first project, and while it worked fine, it consumed half of my digital I/O pins, and seriously limited what I could do with my project. If you don't really need a lot of I/O, that can be fine.

On the other hand, if you want to do more than that, a serial LCD interface may make more sense. They cost twice as much, but as you can see from this example, you can daisy chain with I2C.

/* Quick example to use FunGizmos serial LCD in I2C mode
*
* Connections between LCD & Arduino 
* LCD P2
*   Pin1 not connected
*   Pin2 not connected
*   Pin3 SCL -> Analog in 5 (Arduino has internal pullup resistor)
*   Pin4 SDA -> Analog in 4 (Arduino has internal pullup resistor)
*   Pin5 VSS -> gnd
*   Pin6 VDD -> +5V
*
* To enable I2C mode of LCD Pads of R1 must be jumpered on back of LCD 
* (Between R6 & R14 right below the black IC glob)
*
*/

#include <Wire.h>

int lcd_addr = 0x50; //default I2C hex address from datasheet
int blink;

void setup(){
  delay(1000); //allow lcd to wake up.

  Wire.begin(); //initialize Wire library

  // Wire library expects 7-bit value for address and shifts left appending 0 or 1 for read/write
  // Lets adjust our address to match what Wire is expecting (shift it right one bit)
  lcd_addr = lcd_addr >> 1;

  //Send lcd clear command
  Wire.beginTransmission(lcd_addr);
  Wire.send(0xFE); //Cmd char
  Wire.send(0x51); //Home and clear
  Wire.endTransmission();

  Wire.beginTransmission(lcd_addr);
  Wire.send(0xFE); //Cmd char
  Wire.send(0x70); //Display LCD firmware version
  Wire.endTransmission();

  delay(2000);

  //Send lcd clear command
  Wire.beginTransmission(lcd_addr);
  Wire.send(0xFE); //Cmd char
  Wire.send(0x51); //Home and clear
  Wire.endTransmission();

  Wire.beginTransmission(lcd_addr);
  Wire.send("Hi I'm using I2C");
  Wire.endTransmission();

  Wire.beginTransmission(lcd_addr);
  Wire.send(0xFE); //Cmd char
  Wire.send(0x45); //Set Cursor pos
  Wire.send(0x40); //Line 2
  Wire.endTransmission();

  Wire.beginTransmission(lcd_addr);
  Wire.send("FunGizmos.com");
  Wire.endTransmission();

}



void loop(){

  Wire.beginTransmission(lcd_addr);
  Wire.send(0xFE); //Cmd char
  Wire.send(0x45); //Set Cursor pos
  Wire.send(0x40+15); //Line 2 last char
  Wire.endTransmission();

  Wire.beginTransmission(lcd_addr);
  if(blink)
     Wire.send('*');
  else
     Wire.send(' ');
  Wire.endTransmission();
  blink = !blink;

  delay(500);
}
\$\endgroup\$
5
\$\begingroup\$

I use a parallel LCD display unit which I converted to I2C by using the BV4208 I2C LCD Controller chip from ByVac or consider its new replacement the BV4638.

Here is a library for use with this unit: http://john.crouchley.com/blog/archives/264.

I2C only uses two wires - Analog 4 and Analog 5, you can connect a number of devices from these wires each with their own I2C address. This is a very easy way to extend the Arduino.

\$\endgroup\$
3
\$\begingroup\$

If you have HD44780-compatible LCD and want to use it without consuming too many output pins, you could use a shift register (such as 74VHC164 or 74HC595).
Here is a link to an example project.
Effectively this is very much like a Serial Enabled LCD.

\$\endgroup\$
2
\$\begingroup\$

I use serial lcd's and they're very easy to use and helpful, but if your not using an Arduino Mega you will only have one serial port.This can be solved by using software serial though as long ads you only need to do a write not a read. A good software serial library can be found here

\$\endgroup\$
2
\$\begingroup\$

I have used one serial LCD before, the 20x4 black on green one from SparkFun. The 3-wire interface is very easy to work with but be warned, the back-light draws a lot of power.

Also, if you connect it to a PICAXE the serial 1/0 vs high/low is around the wrong way and you will have to put a logic inverter inline.

\$\endgroup\$
0
\$\begingroup\$

You could use the adafruit LCD backpack. It supports either I2C or SPI. In SPI mode it's really just using a 74HC595 shift register.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.