feat(target): add 8BitDo Ultimate 2 Wireless controller emulation#544
Open
honjow wants to merge 2 commits intoShadowBlip:mainfrom
Open
feat(target): add 8BitDo Ultimate 2 Wireless controller emulation#544honjow wants to merge 2 commits intoShadowBlip:mainfrom
honjow wants to merge 2 commits intoShadowBlip:mainfrom
Conversation
Emulates the 8BitDo Ultimate 2 Wireless controller (DInput mode, VID=0x2DC8/PID=0x6012) as a UHID target device. - HID report structure derived from SDL_hidapi_8bitdo.c - Full button mapping including L4/R4/PL/PR back buttons - Gyroscope and accelerometer with coordinate rotation matching SDL - Rumble support via OutputEvent::Rumble routed through evdev FF - Add generic OutputEvent::Rumble variant and process_rumble handler in evdev gamepad source for direct magnitude-based rumble control
Allow the current session user to read/write the UHID hidraw node (VID=0x2DC8, PID=0x6012) so Steam can use the emulated device.
pastaq
reviewed
Mar 6, 2026
| OutputEvent::DualSense(report) => report.use_rumble_not_haptics, | ||
| OutputEvent::SteamDeckHaptics(_) => true, | ||
| OutputEvent::SteamDeckRumble(_) => true, | ||
| OutputEvent::Rumble { .. } => true, |
Contributor
There was a problem hiding this comment.
I'm not familiar with this syntax, what does { .. } do?
pastaq
reviewed
Mar 6, 2026
| DualSense(SetStatePackedOutputData), | ||
| SteamDeckHaptics(PackedHapticReport), | ||
| SteamDeckRumble(PackedRumbleReport), | ||
| Rumble { |
Contributor
There was a problem hiding this comment.
Is there a reason UinputOutputEvent wasn't usable here?
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.
Adds a
8bitdo-u2target device that emulates the 8BitDo Ultimate 2 Wireless in DInput mode (VID=0x2DC8, PID=0x6012) via UHID.Steam uses SDL_hidapi_8bitdo.c to identify and parse this device by VID/PID, reading the 34-byte input report at fixed offsets. The HID report structure and IMU coordinate mapping are derived from that source.
Supported features:
To support rumble routing, this also adds
OutputEvent::Rumbleand aprocess_rumblehandler in the evdev gamepad source that keeps a single persistentFF_RUMBLEeffect alive and updates its magnitude in-place.A udev rule is included to grant hidraw access so Steam can open the virtual device without root.
Tested on MSI Claw 8 and GPD Win5 .