Glass2 Unit

Glass2 Unit is a 1.51-inch transparent OLED display unit that adopts the SSD1309 driver solution.

Support the following products:

Glass2Unit

Micropython Example::

from unit import Glass2Unit from hardware import * i2c0 = I2C(0, scl=Pin(33), sda=Pin(32), freq=100000) display = Glass2Unit(i2c).display

display.clear(0xffffff) # Clear screen

class Glass2Unit

Constructors

class Glass2Unit(port, address, freq)

Initialize the Unit Glass2

参数:
  • port (tuple) – The port to which the Unit Glass2 is connected. port[0]: scl pin, port[1]: sda pin.

  • address (int|list|tuple) – I2C address of the Unit Glass2, default is 0x3D.

  • freq (int) – I2C frequency of the Unit Glass2.

UIFLOW2:

init.svg

Methods