Add Glorious Model O 2 / I 2 family support - #35
Open
user-vtp2 wants to merge 1 commit into
Open
Conversation
Pure codec (src/glorious/index.ts): settings and lighting payload builders, DPI/polling/LOD/debounce normalization and validation, extracted from openmouse-main's glorious-protocol.ts. No WebHID or DOM dependencies. WebHID driver (src/drivers/glorious/hid.ts): GloriousHidClient with isSupported collection probing, local state caching for the write-only protocol, and UI hints that hide LOD-Low, unsupported polling rates, and the processing card. Registry: Glorious VID 0x093a added to vendors.ts, SUPPORTED_HID_FILTERS, and DEVICE_DRIVERS. MouseStatus brand union extended with 'Glorious'. 13 protocol tests ported from openmouse-main's glorious-protocol.test.ts, all passing.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Glorious Model O 2 / I 2 family — write-only Pixart config protocol
Device and connection
Brand: Glorious
Model: Model O 2 Mini Wireless (dongle PID 0x826d, wired PID 0x826a), VID 0x093a
USB: Interface 1, report ID 0x03, 64-byte feature reports on vendor usage page 0xff00
Family: Model O 2 / I 2 / D 2 (wired and wireless variants share the same Pixart firmware protocol)
What was implemented
Pure codec (src/glorious/index.ts):
Settings and lighting payload builders (four 64-byte settings fragments, three 64-byte lighting fragments)
DPI encoding (50-step grid, 100–26000), polling rate mapping (125/250/500/1000 Hz), LOD (1 mm / 2 mm), debounce (0–16 ms even)
Normalization and validation of untrusted persisted state
No WebHID or DOM dependencies
WebHID driver (src/drivers/glorious/hid.ts):
GloriousHidClient with collection-based isSupported probing (vendor usage page + config feature report)
Local state caching in localStorage (write-only protocol — nothing to read back)
UI hints: hides LOD-Low, unsupported polling rates, and the processing card
Registry:
Glorious VID 0x093a added to vendors.ts, SUPPORTED_HID_FILTERS, and DEVICE_DRIVERS
MouseStatus.brand union extended with "Glorious"
Tests: 13 protocol tests ported from openmouse-main's glorious-protocol.test.ts, all passing.
Hardware verification
Write-only Pixart config protocol verified via Raw Input capture (90s) and reversed against gloriousctl-linux
DPI, polling rate, LOD, debounce, and lighting payloads confirmed working on hardware
HID descriptor collection structure confirmed: COL01 (config, report ID 3), COL02 (mouse), COL03 (consumer), COL04 (sysctrl), COL05 (vendor)
Battery
Not supported on this SKU. Zero COL05 vendor frames observed over the 90-second capture; all community protocol variants exhausted (Sinowealth, Pixart A/B/C/D/F). TechPowerUp review confirms the battery indicator "did not work at all" on the Model O 2 Mini. No fuel-gauge IC is present — the device does not expose battery data over USB.
Unknowns
Protocol is write-only — no settings readback, so local state in localStorage is the only source of truth until a read command is reverse-engineered.
The 0.7 mm LOD option referenced in some community documentation is not exposed by this firmware revision.
Lighting effects are write-only; the last-applied state is cached client-side.