# ShortcutDeck serial protocol The Arduino and the Electron app talk over the Uno USB serial at 115200 baud. Every message is ASCII text ended by a newline. A carriage return is ignored. ## Arduino to PC | Message | Example | Meaning | |----------------|-----------|-------------------------------------------| | `RDY` | `RDY` | Firmware booted, serial port is up | | `BTN:` | `BTN:3` | Button index (0-5) was pressed | | `OK` | `OK` | Command processed successfully | | `ERR:` | `ERR:idx` | Command rejected (idx, cmd, argc, ...) | `ERR` reasons: | Reason | Meaning | |---------|------------------------------------------| | `empty` | empty line received | | `cmd` | unknown command keyword | | `argc` | missing fields | | `idx` | button index out of range (0-5) | | `oledN` | display N failed to initialise | ## PC to Arduino The app sends commands. The Arduino replies `OK` or `ERR:`. | Command | Example | Meaning | |----------------------------|---------------------|--------------------------------------| | `SET|||