Introduction¶
(this documentation is a work in progress as new features and updates are made for the m77 version currently in testing).
What is GremlinEx (GEX)?¶
GremlinEx also known as GEX is a universal game/simpit controller integrator: it allows you to take input from various hardware or network devices, process or combine that input, and send the computed output to a simulator, game or application.
A summary of features can be found here.
Audience¶
The audience for GremlinEx (GEX) is anyone looking to easily integrate and unify multiple hardware input devices from joysticks to control panels and map it to a game without having to use proprietary vendor software.
GremlinEx is simple to use for simple mapping scenarios, yet can also perform very complex mapping tasks with its more advanced options.
GEX includes a rich set of tools for the transformations, manipulation, processing and routing of inputs. GEX supports anything from custom joystick curve editing to conditional output, execution. It supports profile modes and a dynamic state machine to dynamically control the branching and execution of mappings at runtime. GremlinEx can also remote control other GEX instances on the network, playback audio, supports dynamic text to speech, voice recognition, axis merging and axis splitting and scaling, curving and calibration.
GEX is based on years of experience with various game mapping software and specific challenges related to supporting multiple simulation games, each with their own approach, and wanting to provide a unified experience that does all the mapping in one unified application.
A more detailed look at features supported by GremlinEx can be found in the overview section of the documentation.
GEX performance¶
GEX is optimized for low latency at profile runtime. The algorithms and data structures used are all designed to minimize the processing time between an input and the resulting output to be suitable for real-time processing of concurrent inputs. GEX in most cases performs this mapping in under two (2) milliseconds in benchmarks although this can vary with hardware and type. The design goal is under 10 milliseconds.
- targets high speed runtime processing in the millisecond range
- low CPU overhead for most modes (varies with profile complexity)
- built in Python but leverages native C++ libraries for fast execution
- Note that complex profiles and displaying hundreds of inputs concurrently may increase CPU and memory usage by a significant amount. To this end, GEX offers multiple UI filters to reduce the visible input count. This usage is for design time only and does not typically carry over into the execution phase, although it is recommend once the profile is designed to limit the number of inputs displayed in the UI to reduce the overall footprint, and to disable modules that you do not use so they don't consume resources just by being loaded.
What can you do with GEX?¶
- GEX is hardware agnostic and lets you combine inputs from different controllers and unify them with a single profile, removing the need to program these devices separately using vendor specific software.
- GEX provides advanced processing of linear (axis) and momentary (button/key) inputs and lets you combine them for specific behaviors
- Rich set of containers and actions to simplify typical mapping tasks, each with basic and advanced functions. GEX can thus handle simple mapping tasks or very advanced layered/branching for simulation/simpit applications.
- Create a graphical game overlay that responds and displays your inputs on any game or application, for streaming, or instructional purposes or just visual feedback.
- Trigger commands using your own voice using the voice recognition module (experimental)
- Supplement actions with audio cues through the abilty to play multiple sounds at once, including text to speech
- Design a state machine that branches profile execution extremely efficiently
- Use hardware data or or states as input conditions to determine if an action should execute or not
- Perform "setup" actions on profile start, or mode entry, to set buttons, axes or press/release keys just by start/stop or changing modes.
- Works with any game/application that supports joysticks, keyboard or mouse input
- Ability to send axis/buttons/keys to remote GEX clients on the local network with low latency to share hardware devices - this can be exclusive or concurrent
- When used with HID Hide, lets your game or simulator only see the GEX outputs, so it does not get confused with your real hardware.
- When used with Bitfocus Companion, lets you incorporate non tradditional control surfaces with buttons and faders into your simpit, including touch-screen (via OSC)
- The new web overlay lets you use a networked phone or tablet to design and send control inputs to GEX that can then send it to your game/simulator.
- The plugin architecture lets you use simulator APIs for two way communication. GEX includes MSFS support built-in.
Requirements¶
- Windows 11 x64
- GEX includes all necessary dependencies except for optional components like vJoy and VIGEM.
- Python 3.14 and any redistributable libraries are included in the base package and do not need to be installed. Some optional modules may download automatically if not installed from their respective open source projects.
- 1Gb of disk space and 16Gb memory.
- A multi-core processor is highly recommended with four or more cores as GEX is heavily threaded.
Supported protocols¶
- OSC (Open Sound Control) protocol devices
- MIDI protocol for older MIDI controllers (local or networked via MIDI/OX)
- UDP (binary data exchange for local network communication)
Recommended setup¶
- one or more USB connected hardware joystick / panel / throttle that looks to Windows as an HID game controller
- GEX Brige devices (as of m77)
- (prior to m77) - vJOY devices configured (two or three recommended as most titles recognize the first three joysticks - this gives you more axes, hats and buttons you can program).
Example of hardware tested with GEX¶
- Raberry Pi custom HID controller
- Derek Spears Design hardware panels (racing)
- Wooting HE/HE2 keyboard (in joystick and regular modes)
- Steelseries, HyperX and Logitech keyboards
- Azeron
- Octavi IFR1
- Touch/OSC by Hexler (payware)
- OSC/Pilot (payware)
- Open Stage Control OSC surface (open source)
- Arturia and Korg-mini MIDI controllers
- Corsair Elgato StreamDeck and LoupeDeck (various models - button, encoder/touch fader modes, one and two way communication)
- Logitech and Razor gaming mouse
- Thrusmaster, Virpil, VPC, MFG, Logitech and Honeycomb controllers (throttles, pedals, panels, joysticks, yokes) - should work with Moza and WingWing as well
- Rotary USB encoders (keyboard output)
- OBS (Open Broadcaster Software) for streaming with the GEX overlay module
- Windows touch screen functionality via Open Stage Control (network device) for glass surface game control
- HID Maestro and vJoy/VIGEM virtual devices.
Example of tested applications with GEX¶
- Cloud Imperium Games - Star Citizen
- Eagle Dynamics DCS - Digital Combat Simulator
- Microsoft Flight Simulator 2024 (direct via API)
- Egosoft X4 Foundations
- Blender 3D
- OBS (Open Broadcaster Software)
What's new in m77?¶
GEX m77 is the current iteration of GremlinEx in testing/development and incorporates:
- Python 3.14.x support (without JIT compiler support as JIT is, for the moment, incompatible with QT)
- Bridge component that eliminates the need for vJoy (and VIGEM). The bridge runs as a service and embeds all virtual device functionality for GEX, and is managed from within GEX.
- bug fixes from m76
- feature polish from m76 and a more consistent user interface
- new overlay module for dynamic graphical widgets used as an overlay to a game screen
- new Streamdeck bridge module (allows communication without Bitfocus or OSC)
- new web module (allows interaction with GEX from any networked web browser such as a phone or tablet)
- new audio engine with concurrent audio stream playback, fade in/out processing, pitch correct playback speed controls, volume controls
- new AI text to speech for high quality TTS audio cues (up to 300 voices) (runs once to generate, caches generated audio files locally)
- new voice recognition module (GEX will listen to voice commands and trigger actions) based on OpenAI's open source Whisper (runs local)
- new state behaviors, including exclusive mode, grouping and attribute based triggering in map to state action
- new PID (setpoint) controller mode for stepped axis (button to axis or encoder) - allows for dynamic time and deviation based response curve to smooth axis output to a specific value
- new rotary encoder input support with acceleration support (these devices pulse in one direction or the other for axis output)
- updated user interface and streamlined look and feel
- EMA (exponential moving average) filter for chatty or noisy axis input filtering (this is aimed at older potentiometer based controllers or very chatty devices like Wooting or Azeron that spam the axis input queues)
- more polished and responsive user interface with numerous improvements to memory management and workarounds for native issues between QT and Python
- new custom color theme in addition to the existing dark/light modes
- reworked sequence container for advanced macro-type functionality
- reworked legacy macro execution engine to reduce latency
- improved performance of input viewer repeaters
- optimized custom UI components
- reworked condition shortcut branching in the execution engine to increase performance and eliminate redundant evaluations
- optimized API flows to reduce overhead and further reduce TTO (time to output) on processed triggers
- reworked DINPUT input queues and event distribution, more use of direct callbacks and teardowns to optimize response time and reduce Python overhead/leverage caching (prior event handling model could choke on heavy inputs).
- focus on quality of life improvements with container/action and input manipulation in particular
- remote control setup guide.
How can I support the project?¶
The project is a labor of love and started as "I really want to be able to do [missing feature here] and can't find a way to do this". The project has evolved in the last few years to take significant time and resources to support and develop.
Please consider supporting the project by making a secure donation, either one time or recurring, via the sponsor link on the home project on Github.
This project is open source. It has as of this writing, more than 133,000 of lines of code (almost 200,000 if you include comments) - it is a large project. Donations help with the purchase of hardware, maintaining computing resources for testing and development platform purposes. Donations make more time available to research, develop features and support the project on an on-going basis. Thanks to your help, the project has already seen hundreds of updates, many of them daily. It has seen the implementation of nearly all requested features, many of which are not available in other similar tools. It has a rich set of features, many of them not found in payware tools. It is your support and shared passion for this hobby that makes GremlinEx, and its continuing support, possible.
Thank you for considering supporting the project if you have not already, and thank you to those of you who have already supported.
Every bit helps!
Project Home on Github¶
The project's home is on GitHub from where you can download the latest releases and view patch notes.
Support and chat¶
The project has a dedicated Discord server where you can lookup solutions to typical mapping questions, view how-to guides and setup screenshots, ask questions and report any issues. You can also report issues on GitHub if you wish.
General Architecture¶
GremlinEx takes inputs from multiple sources, local and network, performs the transformations and mappings specififed in the profile based on the current profile options, container and action configurations, and sends the output as required.
There should be no expectation that a single input always results in a single output. A single input can produce multiple outputs, and multiple inputs can provide a single output. It's also possible that no output is produced if the input(s) should be ignored based on the particular context.
Differences with Joystick Gremlin¶
GremlinEx started as a fork of the excellent Joystick Gremlin by Lionel Ott years ago. The initial goal of was to port that code to 64 bit and a more recent version of Python. This quickly grew into updating underlying libraries including QT and others, and resolving incompatibilities. Then came new actions and containers, a completely new execution engine and underlying data structures, etc...
Fast forward to today: GremlinEx (GEX) at this point is not Joystick Gremlin nor a new version of Joystick Gremlin. Very little remains from the original fork except for the concept. GEX has been re-architected, redesigned, and is well over 90% new / replacement code. The code that remains is mostly for compatibility with older profiles. GEX offers a new UI experience, while keeping with the spirit of the original.
Efforts were made to retain the ability to load older profiles, provided the containers and actions still exist and can be converted. However in many cases, the new features suplant these older constructs and remapping needs to occur to leverage GEX's features. For example, you would not use merge axis or separate curve actions anymore, you'd find all of this directly baked in the map to vjoy action. You would not use axis to buttons, you'd use the new gated axis action.
Available reworked and new containers are listed here and available mapping actions are found here.
GremlinEx is squarely focused on runtime performance, and low latency.
GEX has a state machine that largely replaces modes and the need for conditions, using a state machine profile design instead.
GEX is heavily networked: it supports remote control of multiple clients and can listen to protocols like OSC. It supports network protocols to accept inputs from other devices on the network, and send data to other devices on the network for two-way communication/updates.
GremlinEx even has a KVM (keyboard video mouse) mode to take over a remote GEX client for game control purposes as if the controls were connected locally to the remote machine.
While most Joystick Gremlin profiles should load as-is, some may not depending on the version of the profile and features used, especially if the features were deprecated in GremlinEx and replaced. This said, simpler profiles should work as-is. A lot of care was applied to ensuring older profiles can load "as is" with the necessary conversions happening automatically - however this only goes so far.
Also note that once a profile has been touched by GremlinEx, it may not work at all with any other prior version, including Joystick Gremlin because of changes to the profile file.
GremlinEx also has several UI (user interface) enhancements aimed at improving the understanding of "what is my hardware doing now", for example, visual repeaters on buttons and axes, and automatic input switching for that time when you don't remember what button is what and you need to go to that input fast.
GremlinEx lets you re-order your devices internally so the ones most often used can show up first in the user interface.
GremlinEx is Windows theme aware and supports a modern UI.
GEX has a new sound processing engine, and features to play back audio at different speeds while maintaining the pitch, and supports overlays and voice recognition to name a few.
GEXhas a new API that makes it easier for custom plugins to be written and interface with inputs and outputs.
Test versions¶
GremlinEx uses an open development philosphy. As such, test releases are frequently available that introduce not only fixes but desired features as well. Some of the versions are more robust than others, however test versions are more likely to have issues, especially with new features.
To this end, GremlinEx offers in the configuration an option to "Version" profile folders so that configurations and profiles are safe from mishaps, such as a new profile version making it incompatible with a prior version of GremlinEx.
It is a best practice regardless ot make a copy of the data folder (default is %USERPROFILE%\Joystick Gremlin Ex) to safeguard any files and configurations, just in case.
Required additional tools¶
Please see the resources section for a list of required and optional tools.
Optional WASM module¶
The Microsoft Flight Simulator SimConnect module in GremlinEx requires the installation of the WASM module in the MSFS community folder. This module is what provides GremlinEx with the ability to execute calculator code in MSFS and thus read/write variables and simulator controls not otherwise exposed by the SimConnect SDK (as of this writing).
Running from source¶
While GremlinEx releases are provided as self-contained Python packages, you can run GremlinEx directly from source code, especially if you would like to contribute or just see how GremlinEx does what it does. The recommended environment is Visual Studio Code. When running in this mode, it is up to you to setup the environment and pre-requisites manually. The GremlinEx project on GitHub includes a Python requirements file listing dependencies. This is an advanced topic and requires a strong familiarity with Python development, working with Python and Python libraries, installing and configuring these environments, interfacing with C++, using the QT graphical environment, and working with low level hardware and network protocols. Also of note is the dependencies will vary with new releases as the project matures.
OSC configuration¶
OSC (Open Sound Control) is a very important feature support in GremlinEx that allows it to communicate hardware panels like Elgato Streamdeck via Bitfocus Companion. The feature also provides support for glass surfaces (touch screens) via tools like Open Stage Control. While supported in the box, it does require some ports to be specified.
For Elgato Stream Deck specifically, GremlinEx also supports a direct Stream Deck plugin bridge that keeps Stream Deck software running (no Companion required for those keys).
Joystick axes and buttons can be drawn on a chromakey window for OBS, or as an on-screen HUD, without Touch OSC. See the overlay guide.
Please see the OSC configuration section for OSC specific setup to enable this feature.
Virus False positives¶
Unfortunately, some older anti-virus and anti-malware programs may flag GremlinEx (and any Python packaged applications) incorrectly, known as a false-positive. See more on the topic and options in this section of the documentation. It should be noted that most malware and anti-virus tools correctly handle the false-positive.
Running GremlinEx for the first time¶
The first time you run GremlinEx, as it is written (mostly) in Python, the Python environment will most likely be running first a first run optimization and cache creation process. This happens for every new version of GremlinEx, but only the first time a module is used/loaded. This process is automatic and part of the normal Python environment. You may thus experience an increase in load times and decrease in performance when first running a new version, especially at design time. This however should not persist on a restart once the caches are created and the optimization done by the Python environment has completed. This is less noticeable on systems with very fast storage solutions as Python creates a number of files during this process, however it can still be noticeable.
It is thus recommended to run the software once, and then restart.
UAC (user access control)¶
Windows UAC may prevent GremlinEx from starting with Windows (if the option is selected) unless the process is given higher permissions. Typically this will manifest itself as a load error, DLL not found error or some other I/O error, even if the program runs fine when started normally. This is not a GremlinEx issue but a UAC security issue.
Resources and help¶
Please join our GremlinEx Discord server!
History¶
GremlinEx is based on a fork from the 2019 Joystick Gremlin by Whitemagic. GremlinEx builds on that excellent software and its concepts, and incorporates notable modifications and enhancements:
- x64 bit support and current Python environments/libraries
- remote control of GremlinEx instances
- Built-in state machine with user defined states, including support for boolean state expressions and state triggered mappings
- Built-in support for the OSC protocol and MIDI devices.
- Streamdeck, Loupedeck and other panel two way control. To simplify and greatly enhance capabilities, highly recommended via Bitfocus Companion) to simplify the setup with GremlinEx
- Support for custom glass surface controller support (touch screen use-case)
- Built in-support for Microsoft Flight Simulator 2020 and 2024 control via the SimConnect SDK including a custom WASM module for calculator expressions and access to custom sim variables
- Advanced containers and actions included.
- High performance runtime execution graph engine (starting with m73)
- Advanced latched keyboard and mouse inputs
- Support for extended keys including F13 to F24 and media keys
- Selectable voice and playback speed for text to speech prompts
- Modern user interface with dark UI theme support
- Overlay designer for chromakey or on-screen joystick visualization without Touch OSC
- Elimination of vJoy/VIGEM requirement through the GEX Bridge module that duplicates the functionality and manages all virtual devices from within GEX.
GremlinEx is in active development and thus may include bugs and issues refered to as dragons. Rather than releasing new features and fixes sporadically, I have adopted an open development model where pre-releases are posted to the dev branch for you to use as the features and fixes are implemented. Some are more bleeding edge than others.
I am a firm believer that open development outweighs the drawbacks, it encourages feedback and input and participation from the community. I appreciate the patience as not everything will work in every pre-release patch as expected, that is part of the process.
Thank you for looking at GremlinEx.
