Bauanleitungen

Der Kusstester





Projekt Home Automation mit Arduino und Dispay

Das 4 zeilige Display

/*
 PC4004-A 40x4 LCD character display - Hello World
 http://code.google.com/p/liquidcrystal440/

  The circuit:
 * LCD RS       pin 11 to arduino digital pin 12
 * LCD R/W      pin 10 to arduino digital pin 11
 * LCD Enable 1 pin 9  to arduino digital pin 10
 * LCD Enable 2 pin 15 to arduino digital pin 9
 * LCD D4       pin 4  to arduino digital pin 5
 * LCD D5       pin 3  to arduino digital pin 4
 * LCD D6       pin 2  to arduino digital pin 3
 * LCD D7       pin 1  to arduino digital pin 2
 * 10K potentiometer:
 * ends to +5V and ground
 * wiper to LCD Vo pin 12

 This example code is in the public domain.
*/

// include the library code
// don't forget to get the modified LiquidCristal library
// by John Raines at http://code.google.com/p/liquidcrystal440/
#include 

// LCD function:  RS,RW,EN1,EN2,D4,D5,D6,D7
// PC4004-A pins: 11,10,  9, 15, 4, 3, 2, 1
LiquidCrystal lcd(12,11, 10,  9, 5, 4, 3, 2);

void setup() {
  // set up the LCD's number of columns and rows:
  lcd.begin(40, 4);
  // show some output
  lcd.setCursor(0, 0);
  lcd.print("hello, world!");
  lcd.setCursor(0, 1);
  lcd.print("hello, world 2!");
  lcd.setCursor(0, 2);
  lcd.print("hello, world 3!");
  lcd.setCursor(0, 3);
  lcd.print("hello, world 4!");
}

void loop() {

}



Pinbelegung des LCD Displays OPTREX DMC-40457

18 PIN INTERFACE
Used on the L40x4 (4x40)
Optrex - DMC-40457

On DMC-40457, signals on pins 17 & 18 are reversed.
E1 is the enable signal for the first HD44780 controller.
E2 is the enable signal for the second HD44780 controller.
VA is the LED backlight Anode.
VC is the LED backlight Cathode.

Datenblatt unter http://pdf1.alldatasheet.com/datasheet-pdf/view/86008/OPTREX/DMC40457.html