Skip to main content

LCD2USB's Python Library

Project description

LCD2USB’s Python Library

home: http://github.com/xyb/lcd2usb

PyPI: http://pypi.python.org/pypi/lcd2usb

Introduce

The LCD2USB’s Python Library is a Pure-python wrapper for LCD2USB which provide a simple way to control your LCD2USB display device. LCD2USB is a open source/open hardware project to connect HD44780 based text LCD displays to various PCs via USB.

Usage

Connect a lcd2usb device is easy:

>>> from lcd2usb import LCD
>>> lcd = LCD()
>>> lcd.info()
Found LCD2USB device on bus 004 device 004.

Get lcd2usb firmware version:

>>> lcd.version
(1, 9)

Write something on the screen:

>>> lcd.write('Hello, LCD2USB!')

Clean screen and wirte some on the 2nd row:

>>> lcd.clear()
>>> lcd.goto(0, 1)
>>> lcd.write('Flying with PYTHON')

Or simpler:

>>> lcd.write('Flying with PYTHON', 0, 1)

Define a custom smile symbol and display it on the center of first row (on a 4x20 display):

>>> from lcd2usb import SMILE_SYMBOL
>>> lcd.define_char(0, SMILE_SYMBOL)
>>> lcd.write('\0', 9, 0)

That it!

If you need a quickly running test for your device, use this:

python -m lcd2usb

Requirements

Installation

Installation is done just as for any other Python library. Using the pip or easy_install command from setuptools is the easiest:

pip install lcd2usb

Or:

easy_install install lcd2usb

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lcd2usb-1.3.tar.gz (8.0 kB view details)

Uploaded Source

Built Distribution

lcd2usb-1.3-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file lcd2usb-1.3.tar.gz.

File metadata

  • Download URL: lcd2usb-1.3.tar.gz
  • Upload date:
  • Size: 8.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: Python-urllib/3.8

File hashes

Hashes for lcd2usb-1.3.tar.gz
Algorithm Hash digest
SHA256 08b4e4514afdd8a0f9b2dd14c1815385ebf9730900a8f850787deb8337bb9eb2
MD5 8013daaa5435afd5589f8f9df7659555
BLAKE2b-256 79f9ad5be4c32f10a0096ef996c3b7dab883ce57f41614b8e7126726fb385a31

See more details on using hashes here.

File details

Details for the file lcd2usb-1.3-py3-none-any.whl.

File metadata

  • Download URL: lcd2usb-1.3-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: Python-urllib/3.8

File hashes

Hashes for lcd2usb-1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 bbbc4df379ee00e0d6016f6d5a82a63d0d0006e008bac657056b71c7acb3f8e2
MD5 d0db57c6d3e4e7008662fa67aa25f6ec
BLAKE2b-256 9cb053fd79c0f5c760465ab490d9e26c6c1e456a90b70614c1a73bbd3d4d8131

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page