feat(razer): offer button mapping over the Viper V3 Pro's wired connection - #26
Open
Pochiiko wants to merge 1 commit into
Open
feat(razer): offer button mapping over the Viper V3 Pro's wired connection#26Pochiiko wants to merge 1 commit into
Pochiiko wants to merge 1 commit into
Conversation
Class 0x02 was gated to the receiver (0x00c1) because it had only ever been exercised there. It is now confirmed on the cable (0x00c0) too, so the flag moves to the shared VIPER_V3_PRO preset and the comment explaining the cable's exclusion goes with it. Verified on hardware, dongle unplugged and Synapse closed: - Mouse Button 4, set to Right Click over the receiver, read back as Right Click over the cable. Mappings live in device memory, so both links see one stored state. - MB4 disabled over the cable, pressed, physically dead, restored -- setButtonMapping. - Scroll Up disabled over the cable, scrolled, physically dead, restored -- setToggleControl, a separate codec path. The cross-transport read is the check that matters, because the failure mode here is silent rather than loud. razerDecodeButtonMapping reads type=0x00, len=0x00, value=0x00 as "Disabled", so a transport that does not implement the class answers all-zero and produces a full, ordinary set of controls that every read reports as Disabled and every write appears to accept. readButtonMappings' null-collapse cannot catch that, because the dict comes back populated. Only a value that all-zero cannot forge distinguishes the two. Add the allowlist test the other hardware-gated capabilities already have -- liftOff and asymmetricLiftOff each pin their product ids, and buttonMapping had no equivalent -- and record on the field itself that the gate is per connection, not per model. No change is needed on the consumer side: availability is computed from status.razerButtonMappings and never looks at the transport.
Pochiiko
force-pushed
the
feat/vv3p-wired-button-mapping
branch
from
August 17, 2026 05:07
35ccb8c to
06997e4
Compare
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.
Class 0x02 was gated to the receiver (0x00c1) because it had only ever been exercised there. It is now confirmed on the cable (0x00c0) too, so the flag moves to the shared VIPER_V3_PRO preset and the comment explaining the cable's exclusion goes with it.
Verified on hardware, dongle unplugged and Synapse closed:
The cross-transport read is the check that matters, because the failure mode here is silent rather than loud. razerDecodeButtonMapping reads type=0x00, len=0x00, value=0x00 as "Disabled", so a transport that does not implement the class answers all-zero and produces a full, ordinary set of controls that every read reports as Disabled and every write appears to accept. readButtonMappings' null-collapse cannot catch that, because the dict comes back populated. Only a value that all-zero cannot forge distinguishes the two.
Add the allowlist test the other hardware-gated capabilities already have -- liftOff and asymmetricLiftOff each pin their product ids, and buttonMapping had no equivalent -- and record on the field itself that the gate is per connection, not per model.
No change is needed on the consumer side: availability is computed from status.razerButtonMappings and never looks at the transport.