Skip to content

Repository files navigation

Banner

CtrlAssist brings "controller assist" to Linux gaming by allowing multiple physical controllers to operate as a single virtual input device. This enables collaborative play and customizable gamepad setups, making it easier for players of all ages and abilities to enjoy games together: a parent taking the hard jumps for a child, a friend steering while you handle the buttons, a player with limited mobility sharing a game's controls with a partner. While similar features exist on modern game consoles, CtrlAssist is an open source project that enhances accessibility for PC gaming, offering additional quality-of-life improvements through virtual input devices on Linux.

CI Pipeline Coverage Documentation Latest release License

✨ Features

  • 🎮 Combine or split controllers into virtual gamepads
    • Merge a Primary and an Assist into one virtual gamepad
    • Or split one controller across several virtual gamepads
  • 🎛️ Customizable multiplexing modes for buttons and axes
    • Logically merging or preempting events is flexible
    • Route to one virtual gamepad at a time, or to all at once
  • 🙈 Real controllers hidden while it runs
    • A game never sees a press twice, Steam included
    • They come back when the profile stops
  • 🕹️ A virtual controller games recognize
    • Appears as a plain gamepad, an Xbox or a DualSense
    • Xbox or PlayStation button prompts, where a game has them
  • 🫨 Feedback reaches the real controllers
    • Rumble to the primary, the assist, or both
    • A DualSense's lightbar, player lights and trigger effects
  • 🧭 Motion and touchpad pass-through
    • Gyro and touchpad of a DualSense or DualShock 4
    • The assist can take the aim while holding a button
  • 🔌 Disconnects are held, not broken
    • The other player carries on with the same virtual controller
    • A returning controller takes its place again
  • 🖱️ Graphical user interfaces
    • A GUI for controllers, profiles and settings
    • A system tray for quick start, stop and hand-over
  • 🛋️ Couch mode for the big screen
    • Drive the GUI from a TV remote or a gamepad, no mouse needed
    • Scaled-up 10-foot layout, automatic under Plasma Bigscreen
  • ⌨️ Scriptable for custom automation
    • A ctrlassist command for everything, with shell completions
    • Profiles as short files, for arrangements of your own
  • ⚡ Low latency and minimal overhead
    • One thread carries all input, real-time where the system allows
    • Tens of microseconds from a real controller to the virtual one

🎛️ Modes

🔀 mux

Combine Primary and Assist controllers into one virtual gamepad.

  • 👑 Priority (default): Assist controller overrides when active
    • Sticks and D-pad: Prioritize Assist when active (exceeds deadzone)
      • Buttons: Pressed while either controller presses
      • Triggers: Prioritize largest value from either
      • Touchpad: Prioritize Assist while touched
      • Gyro: Primary's, or Assist's while a chosen button is held
    • Ideal for partial and asynchronous assistance
      • E.g. Assist for camera while Primary for actions
  • ⚖️ Average: Blend inputs from both controllers
    • Sticks: Averaged when both are active (exceed deadzone)
      • Buttons and D-pad: Logically OR'ed between controllers
      • Triggers: Averaged when both are active (exceed deadzone)
      • Touchpad: First to touch keeps it until lifted
      • Gyro: Never blended; as in Priority
    • Ideal for cooperative input and subtle corrections
      • E.g. For counter steer/brake assist in racing games
  • 🔃 Toggle: Switch Active controller on demand
    • All inputs forwarded from currently active controller
      • Touchpad and gyro included
      • Toggle Active controller via Mode button on Assist
      • Or hand over from the GUI or the system tray
    • Ideal when fine-grain conflict-free control is needed
      • E.g. Game menu navigation or precise interventions

🔁 demux

Split one controller into multiple virtual gamepads.

  • 🔂 Unicast: Route controller to Active gamepad
    • All inputs forwarded to currently active virtual gamepad
      • Cycle Active gamepad via Mode button on the controller
      • Force feedback synchronized with Active gamepad
    • Ideal for switching between multiple virtual gamepads
      • E.g. Assist multiple players in turn, in a custom profile
  • 📢 Multicast: Route controller to all virtual gamepads
    • All inputs forwarded to all virtual gamepads simultaneously
      • Including Mode button events from the controller
      • Force feedback synchronized with all virtual gamepads
    • Ideal for replicating input across multiple devices
      • E.g. For more advanced input multiplexing pipelines

📸 Screenshots

GUI and system tray follow your desktop's theme and accent color.

Pads — every controller and usage Pads — in the light theme
Pads page showing a DualSense that the running couch profile has hidden Pads page in the light theme, on the assist's controller
Profiles — who plays which part Virtual controller — what games see
Profiles page on a running profile, with its Stop button and its two controllers Pads page on the virtual DualSense a running profile makes
Settings — notifications and couch mode About — component status and versions
Settings page with a switch for each kind of notification About page listing the daemon, the hiding service, the tray, GUI and CLI
Tray menu — start, stop and change a profile Tray tip — what runs, at a glance
Tray menu open on the running default profile, with its controllers, mode, rumble, gyro and visibility Tray icon with a green mark for a running profile, and its tip listing the default profile running and the couch profile ready

🏛️ Architecture

CtrlAssist is comprised of a collection of cooperating components:

graph LR

subgraph User
    Gui["GUI<br/><i>settings window</i>"]
    Cli["CLI<br/><i>command line</i>"]
    Tray["Tray<br/><i>system tray</i>"]
    Daemon["Daemon<br/><i>user daemon</i>"]
end

subgraph System
    Hider["Hider<br/><i>hiding service</i>"]
end

subgraph Controllers
    Real["Real"]
    Virtual["Virtual"]
end

Games["Games"]

Gui -->|socket| Daemon
Cli -->|socket| Daemon
Tray -->|socket| Daemon
Daemon -->|socket| Hider
Real -.->|input| Daemon
Daemon -.->|output| Virtual
Virtual -.-> Games
Hider -.->|hides| Real
Loading
Component Description
Daemon Combines real controllers into virtual ones via profiles
Hider Hides a running profile's real controllers from games
Tray System tray for quick access and desktop notifications
GUI Controller status, profile editor, and stack settings
CLI Command line for everything the GUI and Tray can do

The daemon and the tray ship as ctrlassist CLI subcommands; ctrlassist-gui and ctrlassist-hider as separate binaries.

📖 Documentation

Rendered docs available at ctrlassist.readthedocs.io. Relative source links below:

📚 Background

🙏 Acknowledgments

Full third-party notice included with releases. Notable third-parties include:

  • Slint – Declarative GUI toolkit powering ctrlassist-gui's responsive interface
  • Zenoh – Zero-overhead pub/sub unifying socket IPC across the ctrlassist stack
  • ksni – StatusNotifierItem library behind the system tray
  • evdev – Reading real controllers and making virtual ones
  • SDL_GameControllerDB – Community controller layout database
  • TisVlay – Tooling, GUI and conventions this rewrite is built on

Releases

Sponsor this project

Packages

Used by

Contributors

Languages