Skip to content

Elgato Stream Deck hardware, a browser Web Deck, and a device picker - #5

Merged
vman26 merged 1 commit into
developfrom
claude/elgato-hardware
Nov 15, 2026
Merged

vman26 merged 1 commit into
developfrom
claude/elgato-hardware

Conversation

@vman26

@vman26 vman26 commented Nov 13, 2026

Copy link
Copy Markdown
Owner

Stacked on #4 (claude/icon-library). It's a draft because the Elgato support hasn't been tested on real hardware yet.

Elgato Stream Deck (DeckHost.Device.Elgato)

  • Talks to the deck directly over USB HID through HidSharp 2.6.4 (Apache-2.0), so Elgato's software isn't needed. That software has to be closed, though, because it keeps the device to itself.
  • Supported models: MK.2 / Original v2, XL, Neo, Stream Deck + and Pedal.
    • On the Stream Deck +, the four touch-strip zones are linked to the four dials, the same way the N4 Pro's knobs work. A swipe on the strip comes in as touch.swipe.
    • The first-edition Stream Deck and the Mini use the older BMP protocol. They're recognized and logged, but not driven yet.
  • The protocol code is pure and unit-tested:
    • JPEG key images go out as 0x02 0x07 reports, touch-strip images as 0x02 0x0C, both in 1024-byte chunks.
    • Brightness and reset are feature reports.
    • Input parsing covers keys, dial presses and turns, and touch taps, long presses and drags.
  • Hot-plug works through DeviceList.Local.Changed, with one read thread per deck and long-press synthesis.
  • A deck's device id is elgato.<pid>.<serial>. Decks seen before are remembered and stay listed while unplugged, so their profiles can still be edited.
  • Device settings has a screen brightness option.
  • The udev rule now also covers vendor 0fd9.

Web Deck (DeckHost.Device.Web)

  • Shows a grid of keys in a browser: on a phone or tablet on the same network, or in a window on this computer as an on-screen deck.
  • It's off by default. In Device settings you choose This computer only (loopback) or Phones and tablets on this network, plus columns, rows, port and the pairing code.
  • A small TcpListener serves the page (an embedded deck.html) and a WebSocket at /ws. Every request needs the pairing code, which is compared in constant time.
  • Images go to the page as PNG. Presses come back as down/up messages, and long presses are synthesized. Each page has its own bounded send queue, so a slow phone can't hold up the host.

Several devices

  • When more than one device is listed, the header shows a device picker. Each device keeps its own profiles.
  • MainViewModel holds the edited device's profiles in Profiles and the other devices' profiles in a stash. The host gets and saves all of them (EveryLayout).
  • Switching devices rebuilds the canvas, creates a Default profile for a device that has none, and calls the new IDeviceHostService.Redraw.
  • At start, the editor opens on the device of the last selected profile. If nothing was picked by hand and the shown device is offline, it switches to the first plugged-in deck.

Tests

  • 16 new tests: report chunking, input parsing, the Stream Deck + layout, JPEG size and rotation, device ids, and the Web Deck's message checks.
  • One end-to-end test runs the Web Deck server: a request without the code is refused (403), then the test connects over WebSocket, receives the layout and images, and its presses reach the host.
  • All 528 tests pass on Linux. The app starts with all three device plugins.

Not verified yet

  • Real Stream Deck hardware: image orientation per model, the Stream Deck + touch coordinates, and the Neo's extra touch keys.
  • A phone on a real network with a firewall in the way.

Generated by Claude Code

- DeckHost.Device.Elgato: Stream Decks over USB HID (HidSharp), no Elgato
  software. MK.2 / Original v2, XL, Neo, Stream Deck + (dials and touch
  strip linked like the N4 Pro's knobs), Pedal. JPEG key and touch-strip
  reports, brightness setting, hot-plug, long press; decks seen before
  stay listed while unplugged.
- DeckHost.Device.Web: a deck in a browser (phone, tablet or a window on
  this computer), off by default, served over HTTP + WebSocket with a
  pairing code; grid size in Device Settings.
- Several devices: a device picker in the header, each device with its own
  profiles; the host can redraw a device on request.
- udev rule covers vendor 0fd9; README and CLAUDE.md describe both.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012EBcvHpHJnyUyHcb3dfxyi
@vman26
vman26 force-pushed the claude/elgato-hardware branch from ade3840 to ce6da3a Compare November 15, 2026 11:55
@vman26
vman26 marked this pull request as ready for review November 15, 2026 11:56
@vman26
vman26 merged commit cc6da8c into develop Nov 15, 2026
1 of 7 checks passed
@vman26
vman26 deleted the claude/elgato-hardware branch November 15, 2026 12:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants