from machine import Pin, I2C
import ssd1306
import time
WIDTH = 128
HEIGHT = 64
i2c = I2C(0, scl=Pin(22), sda=Pin(21))
oled = ssd1306.SSD1306_I2C(WIDTH, HEIGHT, i2c)
def draw_glasses():
oled.fill(0)
oled.rect(20, 20, 30, 20, 1)
oled.fill_rect(22, 22, 26, 16, 1)
oled.rect(50, 25, 20, 5, 1)
oled.fill_rect(52, 27, 16, 1, 1)
oled.rect(70, 20, 30, 20, 1)
oled.fill_rect(72, 22, 26, 16, 1)
oled.show()
while True:
draw_glasses()
time.sleep(1)