2017-11-01

When 1602 LCD print only one character

아두이노
1602 LCD 에서
lcd.print("hello, world!");
하는데 h 한글자만 찍힐 때는 라이브러리를 바꾸어 보세요.

예제.

#include <Wire.h>
#include <LiquidCrystal_I2C.h>

LiquidCrystal_I2C lcd(0x27,16,2);

void setup() {
  // put your setup code here, to run once:
  lcd.init();
  lcd.backlight();

  lcd.setCursor(0, 0);
  lcd.print(" This stop is");
  lcd.setCursor(0, 1);
  lcd.print("  Akihabara");

}

void loop() {
  // put your main code here, to run repeatedly:
}


저는 lcd.print 했을 때 한 글자씩만 나오기에 여러 글을 검색해보고, 아래 라이브러리를 써서 해결했습니다.

https://github.com/marcoschwartz/LiquidCrystal_I2C

댓글 없음:

댓글 쓰기