Last active
April 16, 2022 03:20
-
-
Save damascenodiego/7fcac91e44033a655f8c89ba2aebfd9a to your computer and use it in GitHub Desktop.
Code to test the force feedback feature in steering wheel controllers (tested wth the Logitech G29)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import evdev | |
from evdev import ecodes, InputDevice | |
device = evdev.list_devices()[0] | |
evtdev = InputDevice(device) | |
val = 65535 # val \in [0,65535] | |
evtdev.write(ecodes.EV_FF, ecodes.FF_AUTOCENTER, val) |
Sorry, @soulslicer ... I haven't tried to use these features.
However, if you take a look at the evdev documentation, there are methods you can call to explore all features supported by your joystick/steering wheel.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Do you have a similar script to control rumble, or to control feedback to the foot pedal?