""" Micropython
LCD1602 Display
mit Keypad
"""
from machine import Pin
import time
#from utime import sleep_ms, ticks_ms
from esp32_gpio_lcd import GpioLcd
print("Start")
lcd = GpioLcd( rs_pin = Pin(4),
enable_pin = Pin(15),
d4_pin = Pin(5),
d5_pin = Pin(18),
d6_pin = Pin(21),
d7_pin = Pin(22),
num_lines = 2,
num_columns = 16)
select_pin = Pin(34)
down_pin = Pin(35)
left_pin = Pin(32)
right_pin = Pin(33)
up_pin = Pin(25)
lcd.move_to(1, 0)
lcd.putstr("Young Engineers")
lcd.move_to(4, 1)
lcd.putstr("mrge.de")
while True:
if select_pin.value()==0:
print("Select")
if down_pin.value()==0:
print("Down")
time.sleep(0.5)