Skip to content

Update LCD.py #2

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions LCD.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ class CharLCD(object):
E_DELAY = 0.0005
HOMEDELAY = 0.05

def __init__(self, rs=1, en=3, d4=15, d5=13, d6=12, d7=14,
cols=16, rows=2):
def __init__(self, rs, en, d4, d5, d6, d7,
cols=8, rows=2):
"""Constructor for LCD.

Args:
Expand All @@ -57,7 +57,7 @@ def __init__(self, rs=1, en=3, d4=15, d5=13, d6=12, d7=14,
d6 (int): Data6 GPIO pin.
d7 (int): Data7 GPIO pin.
cols (int): Number of character columns.
lines (int): Number of display rows.
rows (int): Number of display rows.
"""
# Define GPIO to LCD mapping
self.rs = machine.Pin(rs, machine.Pin.OUT)
Expand Down