Skip to content

Search the documentation

Kit
Firmware

Display

Smart Home

The house’s screen: 128 x 64 dots, x from 0 (left) to 127, y from 0 (top) to 63.

The Display class is reached through this attribute of home.

Can be None.

All the attributes of home are in its table. Read Attributes that can be None to see when a part is None.

Writes text with its top-left corner at dot (x, y); each letter is 8 x 8 dots and a new line starts 8 dots lower.

show_text(text, x, y)

Used in examples: Hello, house, Web dashboard, Smart house, Doorbell

Clears the whole screen.

clear()

Used in examples: Hello, house, Web dashboard, Smart house, Doorbell

Draws a straight line from dot (x1, y1) to dot (x2, y2).

draw_line(x1, y1, x2, y2)

Used in examples: Hello, house

draw_rectangle(x, y, width, height, filled)

Section titled “draw_rectangle(x, y, width, height, filled)”

Draws a rectangle with its top-left corner at (x, y), width x height dots, filled in when filled=True.

draw_rectangle(x, y, width, height, filled: bool)

You can leave out filled.

Used in examples: Hello, house

Draws a circle around dot (x0, y0), radius dots wide, filled in when filled=True.

draw_circle(x0, y0, radius, filled: bool)

You can leave out filled.

Used in examples: Hello, house

draw_triangle(x0, y0, x1, y1, x2, y2, filled)

Section titled “draw_triangle(x0, y0, x1, y1, x2, y2, filled)”

Draws a triangle between the dots (x0, y0), (x1, y1) and (x2, y2), filled in when filled=True.

draw_triangle(x0, y0, x1, y1, x2, y2, filled: bool)

You can leave out filled.

Used in examples: Hello, house

Draws one of the built-in faces by name ("happy", …), scale times its 16 x 16 dots, in the middle unless x and y are given.

show_emoji(name: str, scale: int, x=None, y=None, clear: bool)

You can leave out name, scale and clear.

Used in examples: Hello, house, OLED picture

Draws the MoBot logo, in the middle unless x and y are given.

show_logo(x=None, y=None, clear: bool)

You can leave out clear.

Used in examples: Hello, house

Draws a whole screen at once from 1024 bytes, one bit per dot, row by row (MONO_HLSB).

show_frame(buffer)

Used in examples: OLED picture