Graphical program used to map keyboard buttons and mouse controls to a gamepad. Useful for playing games with no gamepad support.
Graphical program used to map keyboard buttons and mouse controls to a gamepad. Useful for playing games with no gamepad support.
flatpak run io.github.antimicrox.antimicrox instead of just antimicrox
alias antimicrox='flatpak run io.github.antimicrox.antimicrox'~/.bashrc
## D-Bus
AntiMicroX provides a D-Bus service, io.github.antimicrox. You can control some
aspects of AntiMicroX using D-Bus, such as selecting the current control set.
For example, to select set 0 for input device 0 with dbus-send:
```
dbus-send --print-reply --dest=io.github.antimicrox /InputDevice/0 io.github.antimicrox.InputDevice.setActiveSetNumber int32:0
```
### Objects
AntiMicroX provides InputDevice objects with paths `/InputDevice/`, where
`` is the device index.
To find a device of interest, enumerate those objects and use `getSDLName` and
`getDescription` to identify the device.
### Interfaces
InputDevice objects support the [io.github.antimicrox.InputDevice](other/io.github.antimicrox.inputdevice.xml) interface.
#### Method: io.github.antimicrox.InputDevice.getSDLName()
`getSDLName()` provides the human-readable name of the device, such as "Microsoft Xbox 360 Controller" or "HORIPAD FPS for Nintendo Switch".
#### Method: io.github.antimicrox.InputDevice.getDescription()
`getDescription()` provides a detailed description of the device:
```
Index: 1
UniqueID: 030081b85e0400008e020000100100001118654
GUID: 030081b85e0400008e02000010010000
VendorID: 1118
ProductID: 654
Serial:
Product Version: 272
Name: Xbox 360 Controller
Game Controller: Yes
# of RawAxes: 6
# of Axes: 6
# of RawButtons: 21
# of Buttons: 21
# of Hats: 0
Accelerometer: 0
Gyroscope: 0
```
This includes:
* The controller's `UniqueID` assigned by AntiMicroX
* The controller's `GUID` assigned by SDL
* The controller's USB `VendorID`, `ProductID`, `Serial`, `ProductVersion`, and
`Name`
* Whether the device is a `Game Controller`
* The controller's input features: `# of RawAxes`, `# of Axes`,
`# of RawButtons`, `# of Buttons`, `# of Hats`, `Accelerometer`, and
`Gysroscope`
#### Method: io.github.antimicrox.InputDevice.getActiveSetNumber()
`getActiveSetNumber()` returns the current set number for this device.
API set indices are 0-based, but they are displayed in the UI with 1-based
labels.
#### Method: io.github.antimicrox.InputDevice.getActiveSetName()
`getActiveSetName()` returns the name of the current set for this device.
This is empty if the set was not given a name. In that case, AntiMicroX
displays a default name: `Set ` with a 1-based index.
#### Method: io.github.antimicrox.InputDevice.setActiveSetNumber()
`setActiveSetNumber()` changes the active set for this device to the set
specified, as a 0-based index.
### Test
Use [D-Spy](https://gitlab.gnome.org/GNOME/d-spy) to inspect and test the D-Bus
interface.
## Wiki
[Look here](https://github.com/AntiMicroX/antimicrox/wiki)
## Testing Under Linux
If you are having problems with antimicrox detecting a controller or
detecting all axes and buttons, you should test the controller outside of
antimicrox to check if the problem is with antimicrox or not. The two endorsed
programs for testing gamepads outside of antimicrox are **sdl-jstest**
(**sdl2-jstest**) and **evtest**. SDL2 utilizes evdev on Linux so performing
testing with older programs that use joydev won't be as helpful since some
devices behave a bit differently between the two systems. Another method also exists,
which can be found [here](https://github.com/juliagoda/SDL_JoystickButtonNames).
## AntiMicroX Profiles
If you would like to send the profile you are using for your application or find something
for yourself, [here](https://github.com/AntiMicroX/antimicrox-profiles) is the forked repository. If you want to report a bug, ask
a question or share a suggestion, you can do that on the antimicrox page or on the
[antimicrox-profiles](https://github.com/AntiMicroX/antimicrox-profiles) page.
## Support
There are several ways to get help with AntiMicroX. The easiest way is to upvote (with ) issues you thing are the most important ones.
### Contributing
Any contributions into codebase are welcome. You can find contribution guide [here](./CONTRIBUTING.md).
Some issues are may have bounties which are meant to attract contributors.
### Translation
Translation process is handled via [Weblate](https://weblate.org/). If you want to help just click this [link](https://hosted.weblate.org/engage/antimicrox).
Translation status
More information about translating can be found [here](https://github.com/AntiMicroX/antimicrox/wiki/Translating-AntiMicroX).No open issues yet, or sync has not completed.