Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Liquid Crystal LCD Library(I²C)

License

NotificationsYou must be signed in to change notification settings

polarspetroll/LiquidCrystalRPI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A simple LCD controller package for raspberry pi liquid crystal I²C displays.

Example

import ("log""time"  lcd"github.com/polarspetroll/LiquidCrystalRPI")funcmain() {l,err:=lcd.NewLCD(0x27,16,2)// specify the I²C device address, width and heightiferr!=nil {log.Fatal(err)  }/* You can also use the default configuration like so :  l := lcd.DefaultLCD  */l.Print("Hello World!",1)// print 'Hello World' at line 1l.Print("Second Line",2)// print 'Second Line' at line 2time.Sleep(3*time.Second)l.Clear()// clear the displaytime.Sleep(3*time.Second)l.BackLightOff()// turn off backlighttime.Sleep(2*time.Second)l.BackLightOn()//turn on backlight}

Features

  • Scrolling text
  • Backlight control
  • Printing on a specific line
  • Custom characters

About

Liquid Crystal LCD Library(I²C)

Topics

Resources

License

Stars

Watchers

Forks

Languages


[8]ページ先頭

©2009-2025 Movatter.jp