-
Notifications
You must be signed in to change notification settings - Fork 22
Home
Welcome to the hid-tmff2 wiki!
hid-tmff
Driver for older Thrustmaster wheels, has existed in the Kernel for a long time and I have nothing to with it.
hid-thrustmaster
Driver for initializing newer Thrustmaster wheels, initially added in version 5.13. Essentially hid-tminit
, with some modifications to better fit into the kernel.
hid-tminit
Driver for initializing newer Thrustmaster wheels, currently maintained over at https://github.com/scarburato/hid-tminit. All newer Thrustmaster wheels initially identify themselves as Thrustmaster FFB Wheel
, and it is up to the hid-tminit
driver to boot the wheel into its correct designation, after which the corresponding driver can take over. No FFB takes place while this driver is active.
hid-tmt300rs
'Actual' driver for T300RS wheels, responsible for handling FFB. At the moment only tested with the typical T300RS wheel and base, but support for running the wheel in PS4
and 'Advanced mode' with F1 attachments are more or less done, see branches ps4
and adv
respectively.
hid-tmff2
Name of this projects, initially I intended to write hid-tmff
but for newer wheels, but so far only the T300 RS falls under this umbrella. Not a driver in itself, that is.
I don't know exactly which wheels are 'newer' and which are 'older', but at least T150/T300/T500 are in the 'newer' category.
Note that the T150 already has a driver (https://github.com/scarburato/t150_driver) and the T500 is under development (https://github.com/cazzoo/hid-tmff2). Contact these projects if you'd like to help with these wheels.
Use ffbwrap
from ffbtools
: https://github.com/berarma/ffbtools
The documentation gives good examples, but tl;dr; For steam, insert the following into a game's launch options:
ffbwrap --logger=/home/$USER/game.log /dev/input/by-id/usb-Thrustmaster_Thrustmaster_T300RS_Racing_wheel-event-joystick -- %command%
This will create a file called game.log
(with additional timestamp) in your home directory. Preferably change the name to suit the game, but you do you.
Note that most fixes presented in the documentation are more or less obsolete by now, but the tool is still very useful for logging purposes.
I'd recommend wireshark
: https://www.wireshark.org/
Usb capture setup is fairly straightforward: https://wiki.wireshark.org/CaptureSetup/USB#linux
Here's what I typically do when starting capturing:
- Run
sudo modprobe usbmon
. This will load a kernel module that allows Wireshark to read the USB packets. - Open
wireshark
with root privileges. There are some ways to allowwireshark
to access the packets with regular user privileges, I just haven't bothered with it. - Select
usbmon0
from the view that opens up by default. - The screen will quickly fill up with noise from other devices connected to the computer, so you will have to filter out the noise.
- Run
lsusb
in a terminal. Look for the T300 in the list, you should see something likeBus 001 Device 006: ID 044f:b66e ThrustMaster, Inc. Thrustmaster T300RS Racing wheel
- From the previous command, the
Bus
andDevice
fields can be used to filter out only packets from/to the device. To see all packets coming from the wheel, add in a filterusb.src ~ "1\.6\..*"
, where1
is in this case from theBus
field and6
from theDevice
field. To see all packets coming from the device, useusb.dst
. - This data is probably also filled with a lot of cruft. Data to/from endpoint
2
is button state info, which is probably unnecessary. To see FFB data being sent to the device, use endpoint 1, i.e.usb.dst == "1.6.1"
.~
is a Perl-compliant regex operator, whereas==
just matches the string directly. To see both data coming from the device and going to it, useusb.dst == "..." || usb.src == "..."
. - There is also endpoint
0
,usb.src == "1.6.0"
but it doesn't seem to be used for much.
- Run
- Use the three buttons in the top left of the screen to start, stop and restart captures.
- Do whatever you want with the device, packets should automatically be captured. When you want to save your capture to a file, stop the recording and go to
File > Export Specified Packets
and make sureDisplayed
is selected. This will apply the filter you've been using, and will only include the packets that are visible in Wireshark, i.e. it applies the filter you've specified.
Note that every time you unplug and replug your wheel, its Device
field will probably change.
Should probably not be too often that you need this info, but essentially use wireshark
like in the previous example, but spin up a Windows virtual machine and install the Thrustmaster drivers on to it, and pass the device to the virtual machine. I prefer to use qemu
with virt-manager
as a frontend. With the wheel working under Windows, install fedit.exe
(https://gimx.fr/download/b882e209a0ac023d03abbf560dfc3f25fe6367ca/fedit.zip) and methodically go through all effects the device supports and compare the USB packets the driver sends out. You should be able to build up a table of what each value in the USB packet means, see force-effects.txt
for an example of what I found out about the T300.