How OpenJoystickDriver Works
A few ideas explain almost everything OpenJoystickDriver does. The app, its menus, the ojd command line, and these docs all use the same words for them.
- Your controllerXbox, PlayStation, Switch, or another USB or Bluetooth pad.
- OJDOpenJoystick
Driver reads the controller and applies your profile. - Virtual gamepadOne standard pad that macOS and games recognise.
- Your gamesSteam, emulators, and native Mac games.
Who Reads a Controller
Every controller you connect is read by one of two things, and you choose which in the Controllers area under Handled by.
- Handled by macOS: macOS reads the controller by itself, the way it would without OpenJoystickDriver. OJD stays out of the way and makes no virtual gamepad for it. Pick this when a game already works with the controller as it is.
- Handled by OpenJoystickDriver: OJD reads the controller and passes its input on through a virtual gamepad. Pick this when a game ignores the controller, or when you want a profile to change what the buttons do.
In Terminal: ojd controller claim hands a controller to OJD, and ojd controller release gives it back to macOS.
Virtual Gamepad
Most Mac games understand only a few kinds of controller. A virtual gamepad is a pretend controller that OJD makes in software. Games see it instead of your real controller, like a stand-in actor who copies every move: you press a button on your pad, and the virtual gamepad presses the same button a moment later.
In Terminal: ojd virtual.
Virtual Gamepad Kind
The kind is which controller the stand-in pretends to be. Different games read different kinds, so pick the one your game understands best:
| Kind | Pick it for |
|---|---|
| For Steam and SDL games | Steam, emulators, and most games built on SDL. This is the default. |
| For Apple Game Controller games | Apps that use Apple’s own Game Controller support, such as Safari and Apple Arcade games. |
| Generic HID gamepad | Older games and apps that read any plain USB gamepad. |
| For older Unity games | Unity games built with the InControl plug-in. |
| For DualSense games | Games that expect a PlayStation 5 DualSense. |

In Terminal and files: SDLCompatible, GameControllerCompatible, Generic, InControlCompatible, and DualSenseCompatible. See Playing Games for how to switch.
Profile
A profile is a list of rules that changes what each button, stick, or trigger does. A profile can make the A button press the Space bar, turn a stick into a mouse pointer, or give one button a whole macro. Profiles work for games through the virtual gamepad, and for any other app through keys, clicks, and the pointer.
In Terminal: ojd profile. See Profiles.
Connection and Mode
The connection is how a controller reaches the Mac: a cable, a wireless receiver, or Bluetooth. The same controller can look different to the Mac on each connection.
A mode is a setting you pick on the controller itself, with a switch or a button combination, such as XInput or DInput. Some controllers act like a different controller in each mode, so if one doesn’t work, try another. See Connecting Controllers.
Xbox USB Driver
macOS can’t read Xbox controllers plugged in by USB cable on its own. The Xbox USB driver is a small add-on that OJD installs in macOS so it can. You approve it once in System Settings, where macOS lists it under Driver Extensions. Bluetooth Xbox controllers don’t need it.
In Terminal: ojd transport-extension. See Permissions and Security.
The Endpoint, for Your Own Programs
The endpoint is a private door on your Mac where your own programs and scripts can connect to OJD to hear controller events or drive a virtual gamepad. It stays off until you turn it on in the Access area.
- The socket is the door’s address: a file path that only programs on this Mac can open. It exists only while the endpoint is on.
- A token is a named password you make in Access and give to one program or web page. OJD shows it once, so copy it right away. Revoke it to lock that program out again.
- A token’s scope says what it may do: Read hears controller events, and Control drives a virtual gamepad. A token for a web page can’t have Control.
In Terminal: ojd access enable, ojd access grant --token NAME --scope read. See Automating OpenJoystickDriver.