Skip to content
This repository has been archived by the owner on Aug 17, 2024. It is now read-only.

pl31/python-liquidcrystal_i2c

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

python-liquidcrystal_i2c

licquidcrystal_i2c is a python library for the LCD-Module LCM1602 IIC V2 and LCM2004 IIC V2. More information could be found in dfrobot wiki.

This module is a port of the sources found here.

LCM2004 IIC V2

[Keywords: LCM1602 IIC V2, LCM2004 IIC V2, LCM IIC V2, LCD1602 I2C, V1, V2, I2C1602V2, YWROBOT, DFROBOT]

Install

Install directly from gihtub using pip:

pip install https://github.com/pl31/python-liquidcrystal_i2c/archive/master.zip

Install directly from gihtub using easy_install as user:

python -m easy_install --user https://github.com/pl31/python-liquidcrystal_i2c/archive/master.zip

Install from cloned github repository (may need admin rights for python setup.py install):

git clone --depth=1 https://github.com/pl31/python-liquidcrystal_i2c.git
(cd python-liquidcrystal_i2c/ && python setup.py install)

Dependencies

python-liquidcrystal_i2c depends on a smbus-distribution.

Access rights

python-liquidcrystal_i2c needs read/write access to the i2c-bus. Either add your user to the i2c group (adduser <user> i2c) or grant rights to anyone (chmod 666 /dev/i2c-*).

Examples

YWROBOT LCM2004 IIC V2

import liquidcrystal_i2c

cols = 20
rows = 4

lcd = liquidcrystal_i2c.LiquidCrystal_I2C(0x27, 1, numlines=rows)

lcd.printline(0, 'LCM2004 IIC V2'.center(cols))
lcd.printline(1, 'and'.center(cols))
lcd.printline(2, 'python-')
lcd.printline(3, 'liquidcrystal_i2c'.rjust(cols))

Todo

Nice to have:

  • A lot of methods from the original sources are still missing, as I do not need them. For a complete port these should be included
  • Add docstring

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages