Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - cloudtree99

Pages: [1]
1
OLEDs / NHD-0420DZW-AY5 - Line3 and 4 reversed right and left.
« on: December 03, 2018, 12:12:32 AM »
Display:    NHD-0420DZW-AY5

Interface : parallel 4-bit mode

Usage:     Clear display and display text using Arduino Mega 2560. Nothing more complicated than that.

Problem :
Line 3 and 4's characters reversed  right and left.
please see below link image.

https://t1.daumcdn.net/cfile/tistory/99B9683A5C04C89608

here's my arduino source code.
Code: [Select]
#include <LiquidCrystal.h>

LiquidCrystal lcd(30, 32, 5, 4, 3, 2);  // RS connected to Arduino digital pin 30

                                        // E  connected to Arduino digital pin 32

                                        // R/W connected to Ground

                                        // DB4 connected to Arduino digital pin 5

                                        // DB5 connected to Arduino digital pin 4

                                        // DB6 connected to Arduino digital pin 3

                                        // DB7 connected to Arduino digital pin 2

void setup()

{

  lcd.begin(20, 4);                      // 20 columns, 4 rows

}



void loop()



  lcd.clear();                          //clear LCD and set cursor for upper-left corner

  lcd.setCursor(0,0);                   //set cursor for column 0, row 0

  lcd.print("     Hello World    ");

  lcd.setCursor(0,1);                   //set cursor for column 0, row 1

  lcd.print(" New Heaven Display ");

  lcd.setCursor(0,2);                   //set cursor for column 0, row 2

  lcd.print("     Hello World    ");

  lcd.setCursor(0,3);                   //set cursor for column 0, row 3

  lcd.print(" New Heaven Display ");

  delay(1000);                          //delay for 1000ms (1 second)

}

why this happend?? Waht can I do something for solve this problem?

Pages: [1]