Skip to content

Commit 4fecb44

Browse files
committed
Update the Readme
1 parent 6ae8372 commit 4fecb44

File tree

1 file changed

+36
-14
lines changed

1 file changed

+36
-14
lines changed

README.md

Lines changed: 36 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,56 @@
11
lcd and i2c_lcd
22
===============
33

4-
Python code for talking to character based LCDs.
5-
6-
The I2c_Lcd class allows for talking to i2c based LCDs. There are also variants
7-
of the code for MicroPython. All of the files which start with pyb were tested
8-
on the pyboard.
4+
Python code for talking to HD44780 compatible character based dot matrix LCDs.
5+
6+
You can communicate with the LCDs using either 4 or 8 GPIO pins.
7+
8+
Alternatively, the I2C classes implement 8-bit GPIO expander boards
9+
[PCF8574](http://www.ti.com/lit/ds/symlink/pcf8574.pdf) and
10+
[MCP23008](http://www.microchip.com/wwwproducts/en/MCP23008)
11+
which reduces the number of required GPIO pins to two (SCL, SDA).
12+
The boards usually mount behind the LCDs and are commonly called "backpacks".
13+
14+
The most commonly used display is a "1602" or "16x2", which features 16 columns
15+
and 2 rows of characters. There are also other LCDs using the same HD44780
16+
controller. eg. 8x2, 16x1, 16x4, 20x2, 20x4, 40x1, 40x2. Each come in various
17+
backlight and pixel colours.
18+
19+
There are also variants of the code for [MicroPython](http://micropython.org/).
20+
All of the files which start with **pyb_** were tested on the
21+
[pyboard](https://store.micropython.org/store/#/products/PYBv1_1).
22+
Files starting with **esp8266_** were tested on a
23+
[WeMos D1 Mini](https://www.wemos.cc/product/d1-mini.html).
24+
Files starting with **nodemcu_** were tested on a
25+
[NodeMCU development board](https://en.wikipedia.org/wiki/NodeMCU).
26+
The files containing **adafruit_lcd** were tested on an Adafruit
27+
[I2C / SPI character LCD backpack](https://www.adafruit.com/product/292)
928

1029
Files
1130
=====
1231

1332
| File | Description |
1433
| ----- | ----------- |
34+
| esp8266_i2c_lcd.py | ESP8266 PCF8574 I2C HAL |
35+
| esp8266_i2c_lcd_test.py | ESP8266 test using PCF8574 backpack |
36+
| i2c_lcd.pyb | Linux PCF8574 I2C HAL |
37+
| i2c_lcd_test.pyb | Linux test using PCF8574 backpack |
1538
| lcd.py | Core logic |
16-
| i2c_lcd.pyb | Linux I2C HAL |
39+
| nodemcu_gpio_lcd.py | NodeMCU GPIO HAL |
40+
| nodemcu_gpio_lcd_test.py | NodeMCU test using 4-bit GPIO |
1741
| pyb_gpio_lcd.py | Pyboard GPIO HAL |
1842
| pyb_gpio_lcd_test8.py | Pyboard test using 8-bit GPIO |
1943
| pyb_gpio_lcd_test.py | Pyboard test using 4-bit GPIO |
20-
| pyb_i2c_adafruit_lcd.py | Pyboard I2C HAL for Adafruit backpack |
21-
| pyb_i2c_adafruit_lcd_test.py | Test for Adafruit backpack |
22-
| pyb_i2c_lcd.py | Pyboard I2C HAL for PCF8574 backpack |
23-
| pyb_i2c_lcd_test.py | Test for PCF8574 backpack |
24-
| nodemcu_gpio_lcd.py | NodeMCU GPIO HAL |
25-
| nodemcu_gpio_lcd_test.py | NodeMCU test using 4-bit GPIO |
44+
| pyb_i2c_adafruit_lcd.py | Pyboard MCP23008 I2C HAL |
45+
| pyb_i2c_adafruit_lcd_test.py | Pyboard test using Adafruit backpack |
46+
| pyb_i2c_lcd.py | Pyboard PCF8574 I2C HAL |
47+
| pyb_i2c_lcd_test.py | Pyboard test using PCF8574 backpack |
2648

2749

28-
The files which end in _test.py are examples which show how the corresponding
50+
The files which end in **_test.py** are examples which show how the corresponding
2951
file is used.
3052

31-
i2c_lcd.py was tested on a BeagleBone Black using a 2 x 16 LCD with an i2c
53+
**i2c_lcd.py** was tested on a [BeagleBone Black](https://beagleboard.org/black) using a 2 x 16 LCD with an I2C
3254
module similar to [this one](http://arduino-info.wikispaces.com/LCD-Blue-I2C).
3355

3456
This code was adapted from some C code that I had written previously for

0 commit comments

Comments
 (0)