Go Down

Topic: LiquidCrystal.h for 8*2 display? (Read 488 times) previous topic - next topic

mortni11

Does anyone know if the LiquidCrystal.h library is working with a 8*2 display?

I use the EONE high cost-effective 8*2 Characters LCD display but i can't seem to get it to do anything.

Thanks alot!

floresta

That display should work with the LiquidCrystal library.

Post a photograph of your connections and a copy of your sketch and we will try to help.


Don

mortni11





Code: [Select]
/*
  Project:   LCD til test
  Hardware:  LCD 8x2
  Filename:  LCD_test_8x2_standard.pde
  Rev. nr.:  001
  Author :   Hans Erik Tjelum
  Company:   www.let-elektronik.dk
  Date:      2011-03-31
  Copyright: Copyleft

  Detaljeret beskrivelse:
  LCD-program til at teste et LCD
 
  The circuit:

  LCD pins:
  1:  GND - digital common
  2:  +5V - digital supply
  3:  Vo - LCD contrast input*
  4:  RS - Register Select -> Arduino pin 12
  5:  Enable - Active low -> GND
  6:  R/W - Read/Write 1=Read -> Arduino pin 11
  7:  D0 - Not used
  8:  D1 - Not used
  9:  D2 - Not used
  10: D3 - Not used
  11: D4  - Used for 4-bit mode -> Arduino pin 5
  12: D5  - Used for 4-bit mode -> Arduino pin 4
  13: D6  - Used for 4-bit mode -> Arduino pin 3
  14: D7  - Used for 4-bit mode -> Arduino pin 2
  15: LED Anode -> Arduino pin 9 (PWM)
  16: LED Cathode -> GND

* 10K trimmer resistor:
   ends to +5V and ground, wiper to LCD Vo

*/

// include the library code:
#include <LiquidCrystal.h>

// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);

void setup() {
  // set up the LCD's number of columns and rows:
  lcd.begin(8, 2);
  // Print a message to the LCD.
  lcd.print(" LE 2011");
  pinMode(9, OUTPUT);
  analogWrite(9, 128);
}

void loop() {
  // set the cursor to column 0, line 1
  // (note: line 1 is the second row, since counting begins with 0):
  lcd.setCursor(0, 1);
  // print the number of seconds since reset:
  lcd.print(millis()/1000);
  analogWrite(9, 64);
  delay(1000);
  analogWrite(9, 255);
  delay(1000);
}


Thanks alot!

floresta

Quote
Post a photograph of your connections ...

We have to be able to follow each wire and determine exactly where it is connected.  We also have to be able to see what is being displayed.

Are you able to see a single row of blocks on the top line of your display with only pins 1, 2, 3, 15, and 16 connected?


Don

Go Up