I see that you can also try change this with X-windows: $ xinput list-props 16 Device 'JOYMAP Mouse': Device Enabled (151): 1 Coordinate Transformation Matrix (153): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000 Device Accel Profile (282): 0 Device Accel Constant Deceleration (283): 1.000000 Device Accel Adaptive Deceleration (284): 1.000000 Device Accel Velocity Scaling (285): 10.000000 Device Product ID (271): 255, 2 Device Node (272): "/dev/input/event19"...
I see that you can also try change this with X-windows: $ xinput list-props 16 Device 'JOYMAP Mouse': Device Enabled (151): 1 Coordinate Transformation Matrix (153): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000 Device Accel Profile (282): 0 Device Accel Constant Deceleration (283): 1.000000 Device Accel Adaptive Deceleration (284): 1.000000 Device Accel Velocity Scaling (285): 10.000000 Device Product ID (271): 255, 2 Device Node (272): "/dev/input/event19"...
Hi Michael, I checked the code again, speed=1 is the slowest reporting rate possible. However, we can make it slower by adding delays between reporting events. I tested with the following: # Get input from the script button vendor=0x00ff product=0x0000 src=0 target=mouse axis=8 speed=1 button vendor=0x00ff product=0x0000 src=1 target=mouse axis=8 flags=invert speed=1 button vendor=0x00ff product=0x0000 src=0 target=mouse axis=8 flags=release speed=1 button vendor=0x00ff product=0x0000 src=1 target=mouse...
Using a ch products pro throttle: button vendor=0x068e product=0x00f1 src=0 target=mouse axis=8 flags=invert speed=1 button vendor=0x068e product=0x00f1 src=0 target=mouse axis=8 flags=invert,release speed=1 button vendor=0x068e product=0x00f1 src=2 target=mouse axis=8 speed=1 button vendor=0x068e product=0x00f1 src=2 target=mouse axis=8 flags=release speed=1 these lines work for direction but the speed is still too fast when I click the hat. when i spin my mouse wheel slowly it clicks and generates...
Hi Michael, Sorry for the late reply. The wheel is programmed as follows: button vendor=0x044f product=0x0402 src=6 target=mouse axis=8 button vendor=0x044f product=0x0402 src=8 target=mouse axis=8 flags=invert button vendor=0x044f product=0x0402 src=6 target=mouse axis=8 flags=release button vendor=0x044f product=0x0402 src=8 target=mouse axis=8 flags=invert,release #assign a joystick number for script purposes script vendor=0x044f product=0x0402 device=0 #Thrustmaster Warthog Joystick script vendor=0x044f...
Make sure that events are shifted if any shift button is pressed, don't always reset on release
Allow a shift button per devices.
Thank you! This looks like a good change!
Allow a shift button per devices.
How do I map a button to the mouse scroll wheel? I have some games that only allow you select different hotbar slots via the mouse scroll wheel. Minecraft only allows you change from hotbar slot 1 to slot 2 by either the scroll wheel or by pressing 2. Half-life 2 only allows weapon selection via the scroll wheel. Oh do you have a donation link somewhere? Having this continue to exist is really important to me for my current and future gaming needs.
Fix OR parsing
Thanks for catching that! New version pushed and uploaded. Feel free to push more patches my way, especially when I mess up. :-) Kind regards Alexandre
Add new mins and maxes to known keys
Your code works fine except you forgot to add the new config keys in known_keys in mapparser.c. Thank you very much.
I've had a look at the patch, thanks again for that. I'm going to make a few changes though. The original code allowed device values to be passed through unaltered. In other words, if min and max weren't specified, then we would get the value from the device directly. If min and max are specified, then the output would be rescaled based on that range. I've changed the config a bit (backward compatible though) and the documentation to make that clearer. The patched you supplied changes that behaviour,...
Separate input and output maximums
Update documentation for output mapping
Apply patch from patlefort. Thanks!
Hi! Thank you for the feedback! Sorry for the late reply, I've been somewhat busy. Thank you for the patch! It is great to see a contribution in this form, I'll look at it shortly. Kind regards Alexandre
Here's a patch that fixes a few issues: * Set min and max axis values to the virtual device from map config. This enable SDL to detect axis as "hats" when the range is -1 to 1. * Set the default minimum to -32768 instead, which fix the issue I was having above. * Fix formula to rescale axis value between -32767 and 32767. * Round and clamp value when rescaling value when we have a deadzone. * Change dev.absfuzz[i] to dev.absfuzz[j] in register_devices.
Here's a patch that fixes a few issues: * Set min and max axis values to the virtual device from map config. This enable SDL to detect axis as "hats" when the range is -1 to 1. * Set the default minimum to -32768 instead, which fix the issue I was having above. * Fix formula to rescale axis value between -32767 and 32767. * Round and clamp value when rescaling value when we have a deadzone. * Change dev.absfuzz[i] to dev.absfuzz[j] in register_devices.
Hi, thanks for the tool. I packaged it in the AUR. I am having an issue: axes are being reset to -1 instead of 0. After some debugging, I can see the value 0 being written to the device in the set_joy_axis function, but somehow programs will report -1. In fact, anything 0 or below gets dropped by 1. Some program will think that my dpad is always pressed. My controllers dpad are axes that report -1, 0 or 1 and programs like the game controller setting panel in KDE will report -32768, 0 or 32767. My...
Fixes for force feedback
Fix device numbe reporting status of force feedback
Handle small max values
Add an option not to lock joysticks
Increase number of buttons and axes supported
Fix compile
Hi Nichael, Sorry to hear that it is not working for you. It has been a while since I encountered an error like that, I believe it is due to missing headers, usually kernel headers. (See for example https://github.com/Zygo/bees/issues/140). You can try search for packages: glibc-headers, linux-headers, kernel-headers. I'm not using Linux Mint so I don't know exactly which package it is. However, I do note that it is failing to compile a 32 bit library (which I use for wine) which may not be necessary...
keep getting this error: make cc -Wall -Werror -g -c -o loadmap.o loadmap.c cc -Wall -Werror -g -c -o dictionary.o dictionary.c cc -Wall -Werror -g -c -o mapparser.o mapparser.c cc -Wall -Werror -g -c -o programparser.o programparser.c cc -Wall -Werror -g -c -o validkeys.o validkeys.c cc -Wall -Werror -g -c -o events.o events.c cc -Wall -Werror -g -c -o vm.o vm.c cc -Wall -Werror -g -c -o devices.o devices.c cc -Wall -Werror -g -c -o config.o config.c cc -Wall -Werror -g -c -o daemon.o daemon.c cc...
Forward force feedback to device
Fix parsing issues
Correctly handle instances of vendor / product if some are skipped
Update documents
Add controller support (D-PAD) to input_info
Script side of force feedback
Move to stdint
Block devices with axes that don't have buttons
Home
Home
Fix instance with shift
Update documents for controller instance
Add instance with shift
Fix blocker code
Handle multiple controllers better
Cleanup joymap_blocker
Always write the PID file to make kill always work
Add a library to limit joystick access to only joymap devices
Make skipping axes optional
Fix removal of device due to incorrect vendor and product
Only report declared axes
Fix multiple devices with same vendor and product id
Don't register code device if there is no code
Add kill command line argument
Home
More documentation fixes
Fix handling of shift in flags, when it is on its own
Increase number of axes to accomodate second hat
Add a link to the UI project by Rens
Documentation fixes
Home
Fix auto calibrate
Fix man page
Hi James, This bug should be fixed in joymap-0.5.0. joymap-0.5.0 also adds a few other options; * Ability to specify a joystick by event device number instead of vendor and product. * Daemonize option, to run the program in the background. * Handles removal and insertion of devices at runtime (no need to have the devices plugged in before you start). * You can now provide a search path for configuration files in the JOYMAP_PATH environment variable so config files don't have to use absolute paths...
Hi! joymap-0.5.0 now supports use f the "id" keyword for mapping the joysticks. The Id corresponds to the event device associated with the device. For example, if event6 is listed as a handler for the device in /proc/bus/input/devices, then you can specify id=6 in the mapping file. If you specify the id, then you should not specify the vendor and product id. joymap-0.5.0 supports plugging in and out of devices, but if you use the id, then you may find a new event kernel device has been allocated...
Update document
Honour the event id
Tabs to spaces
Calibrate calues based on input reporting on axes values, if requested
Update documentation
Update makefile to cleanup correctly
Support loading files relative to map file, and based on path
Fix tabbing
Move config away from loadmap to single handler
Handle locking of devices correctly
Replace tabs with spaces
Handle devices plugged in after launch, and display input events for programming
Fix shift button
Change max events for modern kernels
Fix mouse wheel events
Fix button/key releases for axis mapping
Fixes, because I wasn't testing :-(
Adjust mouse speed for new assumptions about axes
Add min, max, deadzone and also the trinary flag
Move install_event_handlers back again. No idea why I moved it in the first place
Recompile program.pdf
Pull in osxjoymap changes