Skip to content

Instantly share code, notes, and snippets.

@ProbablePrime
Last active September 15, 2022 00:02
Show Gist options
  • Save ProbablePrime/b65b1f46452be6c14c7ce4d0ae45d8ef to your computer and use it in GitHub Desktop.
Save ProbablePrime/b65b1f46452be6c14c7ce4d0ae45d8ef to your computer and use it in GitHub Desktop.
Elgato Stream Deck Notes

Notes

Button Map

Streamdeck uses Hex HID values to map to its buttons. Their Hex values range from 01 - 0F.

Filters

Capture software adds junk to the copied output of bytes this regex can remove it in vscode: .{8} (.*) .* $

Startup

After sending the initial data set the streamdeck software sends this report: [0x05, 0x55, 0xAA, 0xD1, 0x01, 0x63, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00]

I don't know what this does.

Pull Current State

On startup Streamdeck device sends the current state as a Report, with id 2. Its the exact same format as the write operation.

Image Format

Image format is BGR NOT RGB.

Image Size

72 x 72

Writing an Image

Writing an image is sent as an OUPUT report. The first few bytes are easy to figure out, here's the first page of our red square: 02 01 01 00 00 06

  1. 02: This is the report id, for writing an image its always 2.
  2. 01: Unknown but never changes
  3. 01: "Page" number. Each image is sent as 2 pages.
  4. 00: This is padding
  5. 00: This is 01 on the second page, Presumeably its used to signal that the data is a contiuation from the first page
  6. 06: Hex value for the Button

The rest of the data before image data is uknown but a second page's prefix bytes look like this:

02 01 02 00 01 06

Where the only two changes are items 3 and 5.

First Page Prefix

02 01 01 00 00 06 00 00 00 00 00 00 00 00 00 00 42 4D F6 3C 00 00 00 00 00 00 36 00 00 00 28 00 00 00 48 00 00 00 48 00 00 00 01 00 18 00 00 00 00 00 C0 3C 00 00 C4 0E 00 00 C4 0E 00 00 00 00 00 00 00 00 00 00 00 00

Second Page Prefix

02 01 02 00 01 06 00 00 00 00 00 00 00 00 00 00 00 00

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment