Skip to content

OsmsPad: own virtual gamepad driver (UMDF + VHF) to replace ViGEmBus - #65

Merged
mlopezsegura merged 4 commits into
masterfrom
feature/osms-pad
Nov 16, 2026
Merged

mlopezsegura merged 4 commits into
masterfrom
feature/osms-pad

Conversation

@mlopezsegura

Copy link
Copy Markdown
Collaborator

Adds OsmsPad, a UMDF filter on top of VHF that creates Xbox Series controllers seen by XInput, with rumble back to the client. It loads without test signing (one-off test certificate, like RemoteIdd).

  • Native/OsmsPad: driver, package and install/uninstall scripts
  • Gamepad isolation uses the controller's instance ID (OSMS_S<session>_P<n>) instead of guessing from the Sunshine log
  • Installer builds, signs and installs it (Windows 10 2004+; older systems keep ViGEmBus)
  • The service sets gamepad_driver = osmspad when the driver is installed

Note: the bundled sunshine.exe doesn't have the OsmsPad backend yet, so it ignores that setting and keeps using ViGEmBus. Controllers switch to OsmsPad once a Sunshine-Web-RTC build with the backend ships.

Tested: build, unit and i18n tests; driver tested locally with OsmsPadTest (buttons, sticks, triggers, rumble, removal).

🤖 Generated with Claude Code

mlopezsegura and others added 4 commits November 14, 2026 14:03
A UMDF filter above Windows' Virtual HID Framework that creates Xbox Series
controllers on demand through a private IOCTL interface. Windows attaches its
inbox xinputhid filter, so games see them through XInput, GameInput and
DirectInput, without ViGEmBus. Each controller belongs to the handle that
created it and goes away when that handle closes, and its instance ID carries
the Windows session it was created for (OSMS_S<session>_P<n>), so the service
can isolate it without guessing. Rumble comes back to the client.

Signed like RemoteIdd with a one-use test certificate; being user-mode only,
it loads without test signing. Includes OsmsPadSetup (root device), package,
install and uninstall scripts, a unit test of the report encoding and an
end-to-end test that checks the controller through XInput.

Adapted from ideas in libvirtualgamepad (MIT, see THIRD_PARTY_NOTICES.md).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
OsmsPad's root device is treated like a ViGEm bus: its children are the
controllers. Their instance ID ends in OSMS_S<session>_P<n>, so the session
comes straight from the driver instead of from Sunshine's log; the log only
gives the pad's number in that Sunshine ("OsmsPad controller P created for
gamepad N") for the mosaic. A controller from a Windows session with no
OpenStreamMS session (e.g. OsmsPadTest) is still confined to that session.
Sunshine is configured with gamepad_driver = osmspad when the driver is
installed; it falls back to ViGEmBus by itself if the driver goes missing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
build-installer compiles and signs OsmsPad like RemoteIdd (one-use test
certificate) into osmspad-pkg; setup installs it on Windows 10 2004 or later,
before the service starts so Sunshine picks gamepad_driver = osmspad, and the
uninstaller removes the device, the driver package and its certificate.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
# Conflicts:
#	Core/Installer/messages.generated.iss
#	Core/Installer/messages/bg.json
#	Core/Installer/messages/cs.json
#	Core/Installer/messages/de.json
#	Core/Installer/messages/en.json
#	Core/Installer/messages/en_GB.json
#	Core/Installer/messages/en_US.json
#	Core/Installer/messages/es.json
#	Core/Installer/messages/fr.json
#	Core/Installer/messages/hu.json
#	Core/Installer/messages/it.json
#	Core/Installer/messages/ja.json
#	Core/Installer/messages/ko.json
#	Core/Installer/messages/pl.json
#	Core/Installer/messages/pt.json
#	Core/Installer/messages/pt_BR.json
#	Core/Installer/messages/ru.json
#	Core/Installer/messages/sv.json
#	Core/Installer/messages/tr.json
#	Core/Installer/messages/uk.json
#	Core/Installer/messages/vi.json
#	Core/Installer/messages/zh.json
#	Core/Installer/messages/zh_TW.json
@mlopezsegura
mlopezsegura merged commit ec68043 into master Nov 16, 2026
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.

1 participant