Skip to main content

Module host

Expand description

Frame kinds a host sends.

Constants§

ACTIVITY
No payload — answered by super::board::ACTIVITY, the fabric engine’s last frame of activity.
ALL
CURSOR
row, col, shown — place the text cursor; shown 0 hides it.
ENGINE
byte, … — bytes for the fabric engine’s loader, in order; at most super::ENGINE_FRAME_MAX per frame, and the next frame only after super::board::ENGINE_TAKEN.
ENGINE_RESET
No payload — hold the fabric engine in reset for one engine clock and release it: a running program stops, and the loader waits for a new image.
FILL
row, col, height, width, attribute, glyph — fill a rectangle with one cell.
PING
No payload — answered by super::board::PONG.
POINTER
row, col, shown — place the pointer (a mouse’s position, drawn as an inverted cell).
PS2_SEND
byte — send one byte to the PS/2 device (a mouse needs 0xF4 before it reports).
PUT
row, col, cell_hi, cell_lo, … — write consecutive cells from (row, col); each cell is two bytes, the attribute byte (background << 4 | foreground) then the glyph byte (blink << 7 | glyph).
READ
row, col, count — read count cells back from (row, col); answered by super::board::CELLS.
RESULT
b3, b2, b1, b0 — a 32-bit value for the 7-segment display, shown in signed decimal.
TOTALS
No payload — answered by super::board::TOTALS, the engine clocks of the run so far, by block and cell.
WINDOW
row, col, rows, cols — the small-text window: text rows row..row + rows and columns col..col + cols show the small plane (super::SMALL_FIRST_ROW) instead, two of its 8-pixel rows to each text row, drawn in the small font (super::FONT8_ROWS); rows 0 closes it.