summaryrefslogtreecommitdiff
path: root/bin/i2c.py
diff options
context:
space:
mode:
Diffstat (limited to 'bin/i2c.py')
-rw-r--r--bin/i2c.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/bin/i2c.py b/bin/i2c.py
index 75a3509..1afb219 100644
--- a/bin/i2c.py
+++ b/bin/i2c.py
@@ -1,4 +1,4 @@
-from smbus import SMBus
+from smbus2 import SMBus
from time import sleep
ALIGN_FUNC = {"left": "ljust", "right": "rjust", "center": "center"}
@@ -63,3 +63,6 @@ class LCD(object):
def clear(self):
self.write(CLEAR_DISPLAY)
+
+ def read(self):
+ self._read_i2c_block_data