Giter Site home page Giter Site logo

whitemagic / joystickgremlin Goto Github PK

View Code? Open in Web Editor NEW
305.0 305.0 43.0 12.92 MB

A tool for configuring and managing joystick devices.

Home Page: http://whitemagic.github.io/JoystickGremlin/

License: GNU General Public License v3.0

HTML 5.35% Python 87.44% Batchfile 0.02% QML 7.17% JavaScript 0.02%

joystickgremlin's People

Contributors

amadeus avatar bryceschmitt avatar dixonte avatar drakehinst avatar jmriego avatar moondragon85 avatar whitemagic avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

joystickgremlin's Issues

Improve Bezier spline widget

Improve the usability of the Bezier response curve widget

  • ability to mirror the two quadrants
  • enforce C1 continuity at control points

Not an issue, but a suggestion: Axis splitting

First and foremost, thanks for such an awesome piece of software. It's powerful, turned my Hotas X into a very decent joystick.

My suggestion: is it possible to add an axis splitting function just like Universal Joystick Remapper? Honestly, that's the only missing feature for Joystick Gremlin.

Thanks again for the great job. Cheers, mate.

Multiple identical devices causes UI issues

When multiple devices of the same type are attached the UI can be confused when actions are added to one device. Sometimes the action shows up on one of the other devices as well and the generation of XML code breaks completely.

Crash due to invalid device

When a device enumerated by SDL is invalid the program crashes, due to the lack of checking if the device opened is valid.

Functionality to create a cheatsheet

Using the name / description from #14 associated with each input item the program should be able to generate a cheat sheet, which shows what is performed by input items based on their mode.

Make keep alive vjoy axis reset smarter

The vjoy device needs to periodically receive inputs otherwise it becomes unresponsive. Up until R6 this was done by calling the reset() function on the used vjoy devices. In R7 this was augmented by overriding the axis values to be 0 as the default behaviour set some to 0 and others to -1.

Neither of these behaviours are ideal as the desired default position of an axis can vary widely. To remedy this the keep alive functionality should consider what the last reported position of the axis is and resend this to keep the device alive without modifying its state.

Crash on running a profile

When I map my Saitek X45 with default Windows 7 drivers to vJoy and try to run the profile, I get the error:

Uncaught exception:
Traceback (most recent call last):
File "joystick_gremlin.py", line 271, in activate
File "gremlin\code_runner.py", line 55, in start
File "gremlin\util.py", line 569, in load_module
File "importlib_in'rt_.py", line 109, in import_module
File "", line 2254, in_gcd_import
File "", line 2237, in _find_and_load
File "", line 2226, in _find_and_load_unlocked
File "", line 1200, in _load_unlocked
File "", line 1129, in_exec
File "", line 1467, in exec_module
File "", line 1572, in get_code
File "", line 1532, in source_to_code
File "", line 321, in _call_with_frames_removed
File "C:\Users\mjarek\Joystick Gremlin\gremlin_code.py", line 40
SyntaxErron (unicode error) 'utf-8' codec can't decode byte 0xb3 in position 0:
invalid start byte

Most likely this is caused by the name assigned by the Windows Driver, it is: „6-osiowy 26-przyciskowy joystick z przełącznikiem ustawień”

Template system for easier config sharing

Implement a system which allows rebinding existing configurations onto new devices, it should allow the following:

  • use plan XML profiles
  • present a view which shows actions by mode
  • allow users to press / move / etc the desired input once an action has been selected to bind this
  • store the final result as a new profile

Feedback missing for New, Save, Save as actions

There is no feedback or warning when loading a profile or creating a new one when changes have been made to the current profile which haven't been saved yet. The UI should show the usual "are you sure" type of dialog in these cases.

Add remap to keyboard

Currently the remap action can remap to vJoy inputs, however, doing the same to keyboard keys or key combination would be a logical use for the same system.

Detect and load profiles based on active application

Implement the ability for Joystick Gremlin to load a desired profile when a specific application has focus and deactivate the profile once the application loses focus. Similar to how mouse and keyboard software loads profiles based on what program is running.

Device identification / assignment UI

Add a UI which allows the user to assign devices to a configuration. The main use for this would be to allow users to swap or correct incorrect device assignments in the case of duplicate devices existing on a system.

In the case where there are duplicate devices present in a system the only way to disambiguate them is via their windows id. This id, however, can change arbitrarily. In the best case the ids won't match anymore but they could just as well simply be swapped. As such being able to manually correct such issues would mean that XML files don't have to be fixed manually.

A potential way of presenting this in the UI is to have a dialog on the actual device tabs where one can click on a button which then will wait for the user to move the desired device and then based on this information update the windows id mappings.

Improved macro system

The current macro system allows the creation of very simple key stroke sequences to be recorded and played back, however, there are several limitations, including:

  • only handles US keyboard layouts
  • limited to keyboard inputs
  • only simple sequences

To improve this the following things should be added:

  • ability to deal with arbitrary keyboard layouts
  • additionally send mouse button and joystick inputs
  • allow simple logic to be part of a macro

Enhanced action conditions

Extend the type of conditions that can be used with actions. Currently actions assigned to a button can customized the following:

  • trigger on button press
  • trigger on button release
  • require a modifier to be held

Extend this system to allow a variety of modifiers to be used to wrap actions. Such modifiers include:

  • double tap
  • tempo
  • chain
  • smart toggle

The goal is that physical inputs can add actions as always to simple execute that action, but in addition additional modifiers should allow a single action or a set of actions to be wrapped. As such a double click modifier would take a single action that instead of being execute on a click would be execute on a double click.

This seems to apply mainly to button and key presses, though hats should be able to use this as well while axis might not be suitable for this.

Profile auto load dialog issues

The dialog where profiles are configured to load when a specific application is running is not working properly. When a new executable is added and one subsequently selects a profile for said executable the assignment is not made correctly.

Add process list to automatic profile loading

Add a process list viewer that allows selecting the application to add a profile for from the active processes. This should make it easier to pick the correct application without having to find the correct executable on the hard drive.

Remember the position and size of the main window

Currently Gremlin simply starts wherever windows decides to place it with the default dimensions. A nicer behaviour would be for it to place itself in the last position the user positioned it as well as remembering the size used.

Add text-to-speech interface for audio feedback

Interface with Windows SAPI to use it's TTS capabilities in order to allow for audio feedback to the user.

  • write an abstraction module for nicer interfacing with SAPI as opposed to raw COM object usage
  • write an action module that allows the user to add text to be spoken to any input item like all other actions

Recently used profile list

Implement facilities to show the last N used profiles in the File menu to make switching between profiles quicker.

Cubic Bezier spline response curve

Implement cubic Bezier splines as an option for response curve configuration. These splines allow for more control of the shape then normal cubic splines.

Virtual joystick rotation

Implement the ability to essentially define a basis transform that results in a angled forward motion of the stick to result in a pure forward motion being sent. This should mimic the effect of having a stick at an angle when this is not physically possible on the stick in question.

Better integration of custom modules

Custom modules currently are very hard to move from one setup to another due to device information being hard coded inside of them. This limits the ability to share and adapt complex configurations between users that have different devices.

One possible addition is the ability to specify variable names which can be used in custom modules and bound via the UI which then would allow rebinding them conveniently without having to modify a thing in the actual custom module. A similar thing could be done for various buttons, axis, etc. used in scripts in a way that exposes all the input and output values of custom modules but keeps their logic locked away. Essentially, allowing users to configure the values of inputs read and written to without having to open any custom modules.

Joystick Gremlin won't start with more than 2 vJoy devices installed

Tried adding one vJoy device for each one of my real devices, since I believe vJoy1 is already used by default by tobii eyetracking software (but I don't know if I'm even able to configure how that interfaces itself to vJoy, might be hardcoded), but Joystick Gremlin wouldn't start as it did with only the single default vJoy device installed. Well it started but closed itself silently in a blink before even opening the app window.

So I started reducing the number of vJoy devices I was using (4). It is now starting again, with 2 vJoy devices installed, but I can only see the vJoy#2 tab and not vJoy#1 tab in Joystick Gremlin.

Windows 10 64b
Joystick Gremlin v7
vJoy 2.18

Thrustmaster t.16000
Thrustmaster TWCS
Logitech g13 - logitech game software running
Tobii 4C - eyetracker app running (which is not the one that uses vJoy, that should be a plugin app), device disconnected

Add the ability to name input item actions

It should be possible to add a name or description to each input item, i.e. axis, button, hat, or key. This would make the profiles self documenting.

This description or name should be present both in the XML profile as well as the generated code, such that the code can do something with it if needed.

More informative error when vjoy / sdl joystick mapping cannot be done

Joystick Gremlin needs to be able to map vJoy devices and SDL devices without ambiguity in order to handle multiple vJoy devices. When this mapping fails Gremlin is essentially in a "undefined behaviour" state and as such terminates. The error shown when this occurs is not very helpful and should be improved to tell the user how to fix this.

All that is required for this mapping to work is that each vJoy device is slightly different from each other based on the number of axes, buttons and hats available on the vJoy device. As such having three devices with 100, 101, and 102 buttons is sufficient for the mapping to succeed.

Display action description on the InputItemButtons

The description associated with each physical input is currently only shown when the particular input is selected. Displaying this on the list of inputs between the name and associated actions would make use of the space and also make it much easier to get a quick idea of the layout of a profile.

Action for hats to map directions to individual buttons

Create an action plugin which reproduces the hats2buttons module but can be simply added to a hat input and then configure each hat direction to map to the desired vjoy button without having to deal with a custom module.

Auto-repeat of virtual device data

Implement a mode which emits virtual joystick values periodically in response to physical device usage. This would allow mapping the virtual device rather then the physical device in cases where both devices generate data and the physical device is preferred over the virtual one.

Mode inheritance system

Implement a system that allows modes to inherit from each other. The system should allow for single inheritance only, i.e. tree structure and overriding a parent's input replaces the complete action rather then triggering the child's and parent's actions.

  • single inheritance
  • overriding is complete

Initialize vjoy state properly

Ensure that each vjoy input is initialized to a sane value, i.e. buttons are not pressed, hats are centered, and axis are at 0. If this is not done random initial inputs will be sent until each of the inputs is used at least once.

Axis calibration

Provide a dialog to record calibration of various input axis as well as using the calibration data to correct raw inputs.

Conflict with Thrustmaster Target

Going to keep it simple to not take much of your time: every time I try to use TARGET and joystick Gremlin at the same time, I lose the inputs on my TARGET profile. If I try to start the TARGET profile after Gremlin, the Joystick Gremlin crash.

Add ability to play sound files

In addition to the TTS action adding another one capable of playing back sound files would allow greater freedom to customize user feedback and even potentially use things that people have built for Voice Attack.

Axis calibration can produce values outside [-1, 1]

When the calibration does not cover the full range of motion the output produced by the calibration function may be outside the valid range of [-1, 1]. To fix this, the raw values need to be clamped to the axis limits before applying the calibration function.

Save can overwrite existing profiles

When creating a new profile after an existing one had been loaded pressing save will overwrite the previously loaded profile rather then opening the "Save as" dialog.

Closing option dialog closes gremlin

When the "Start minimized" option is enabled Gremlin closes completely when the options dialog is closed, when only the dialog should be closed.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.