USB and serial LCD backpack commands

From DP

Jump to: navigation , search

The controller implements a (subset) of the serial interface provided by Matrix Orbital Serial LCDs.

Text

To write text on the display simply send the ASCII characters. Control the position of the cursor with the POSITION command.

Commands

To send a command, first send the MATRIX_ORBITAL_COMMAND byte (0xFE), followed by the command (with any parameters).

For example, to turn on the backlight, send 0xFE, 0x42, 0x00.

Name Decimal Hex Parameters
MATRIX_ORBITAL_COMMAND 254 0xFE None
BACKLIGHT_ON 66 0x42 1 (0=forever)
BACKLIGHT_OFF 70 0x46 None
CLEAR 88 0x58 None
HOME 72 0x48 None
POSITION 71 0x47 2 (col, row)
UNDERLINE_CURSOR_ON 74 0x4A None
UNDERLINE_CURSOR_OFF 75 0x4B None
BLOCK_CURSOR_ON 83 0x53 None
BLOCK_CURSOR_OFF 84 0x54 None
BACKLIGHT_BRIGHTNESS 152 0x98 1 (0=on)
CUSTOM_CHARACTER 78 0x4E 9 (character #, 8-byte bitmap)
  • BACKLIGHT_ON optional parameter may support a time in minutes in the future
  • BACKLIGHT_BRIGHTNESS optional parameter may support brightness levels between 0 (0x00) and 255 (0xFF) in the future
  • POSITION requires two additional parameters: the column and row number to move to. To move to the first character send 0xFE 0x47 0x01 0x01