fix(endgame): tell the OP1w 4K v1 from the v2 behind the shared dongle - #152
Merged
Merged
Conversation
All four OP1w/XM2w 4K mice share dongle PID 0x1970. The mouse-info reply (0x0E) names the paired mouse, but the v1 PIDs (OP1w 4K 0x1972, XM2w 4K 0x1968) had no profile, so a v1 kept the neutral v2 profile: v2 lift-off encoding (wire 1/2 mean 1 mm/2 mm on v1, 0.8/0.9 mm on v2), glass mode, 125 Hz Office Mode and the 11-byte 0x15 block. Add v1 profiles from re/PROTOCOL.md sections 10 and 12 (PAW3395 50-26000, LOD 1/2 mm in whole millimetres, no glass mode, 1000/2000/4000 Hz, motion jitter filter, 10-byte 0x15 block). The mouse-info reply now switches the dongle's profile to the paired model, and writes through the dongle wait until the mouse has identified itself. The neutral dongle name drops "v2". Reported on Discord ticket #126 by an original OP1w 4K owner. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
🎉 This PR is included in version 0.23.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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.
Problem
Ticket #126 (Discord): an original OP1w 4K over the 2.4 GHz dongle still shows as "Endgame Gear OP1w/XM2w 4K v2" on protocol 0.22.0, after the mouse-info fix in #139.
All four OP1w/XM2w 4K mice share dongle PID
0x1970. The0x0Emouse-info reply names the paired mouse, but the v1 PIDs had no profile, so a v1 kept the neutral v2 profile. That is more than a naming bug: the generations encode settings differently (johanneszab/endgame-op1wre/PROTOCOL.mdsections 10 and 12, checked on both generations):0x1972, XM2w 4K0x1968)0x1984,0x1982)0x14+2)1/2round(mm*10) - 7, 0.7 to 1.7 mm0x150x15payload0x40), 1000 power save (0x80)So a lift-off change on a v1 wrote 0.8/0.9 mm values that the v1 reads as 1/2 mm, and vice versa. DPI and polling round-trips passed on the reporter's mouse only because those encodings match.
Fix
endgame-gear/op1.ts: OP1w 4K (0x1972) and XM2w 4K (0x1968) profiles;EGG_4K_V1_POLLING_RATES;eggBlockWrites(config, hasGlassMode)drops the 11th power byte on v1. The neutral dongle name is now "Endgame Gear OP1w/XM2w 4K".egg-op1-hid.ts: the mouse-info reply now switches the dongle client's whole profile, not just its name. Writes through the dongle wait until the mouse has identified itself (section 12: refuse model-specific writes until0x0Eanswers). v1 gets its motion jitter filter back; LOD uses wire base 1 on v1.0x1972,0x1968) are claimed by this driver now. The WE driver already refuses any device exposing feature report0xA1, so WE-shaped devices on those PIDs are unaffected.Tests
npm test: 1973 pass. New: an OP1w 4K v1 behind0x1970gets the v1 name, LOD options, polling set, no glass mode, a 10-byte0x15write and the jitter filter; a write before the mouse identifies is refused and goes through once it answers.Not yet tested on a v1. The ticket owner can verify once released: name "Endgame Gear OP1w 4K", lift-off 1 mm / 2 mm round-trip, no glass mode toggle.