print("Hello, ESP32!")
from time import sleep_ms, ticks_ms
from machine import I2C, Pin
from i2c_lcd import I2cLcd
#I2C setting
i2c = I2C(scl=Pin(22), sda=Pin(21), freq=4000000)
# LCD with I2C
AddressOfLcd = 0x27
lcd = I2cLcd(i2c, AddressOfLcd, 2, 16)
def displayLCD():
lcd.move_to(0,0)
lcd.putstr('Micropython')
lcd.move_to(5,1)
lcd.putstr("ETC613 ")
while True:
displayLCD()
sleep_ms(500)