Skip to content

Feature/t500rs driver only - #219

Draft
cazzoo wants to merge 3 commits into
Kimplul:masterfrom
cazzoo:feature/t500rs-driver-only
Draft

Feature/t500rs driver only#219
cazzoo wants to merge 3 commits into
Kimplul:masterfrom
cazzoo:feature/t500rs-driver-only

Conversation

@cazzoo

@cazzoo cazzoo commented Sep 9, 2026

Copy link
Copy Markdown

No description provided.

@Kimplul

Kimplul commented Sep 9, 2026

Copy link
Copy Markdown
Owner

Heyo, what's your plan with this draft? Looks like the changes are more or less the same as in #218 but I guess the commit history is more squashed as suggested in #218 (comment). If you tried to follow the suggestions in #218 (comment), this PR kind of misses the mark a bit. For example, ddc0305 could've/should've been a preparatory PR, since it's more generic and touches other things than just the T500.

It was kind of implied, but maybe not explicitly stated, but size of this PR is kind of the main issue here. The last few PRs had hundreds of comments and I can see that at least some of them aren't reflected in this version (which is understandable, there's a huge amount of context to keep track of).

GitHub has a new feature, stacked PRs, that you can use to create a series of PRs that each depend on eachother. That way, you can split the total work into smaller bits that can be reviewed separately, and each thread is more focused. For example, for this PR something like

  1. Defer gain/autocenter (generic changes, required for the T500 to work)
  2. T500RS with just the constant effects supported, including docs for just the constant effect (most games just use constant effects so this is already an excellent addition to this driver!)
  3. Periodic, ramp effects (+ docs for them)
  4. Passive effects (spring, damper) (+ docs for them)

or something along those lines.

This is a pretty good overview of what a good PR consists of. Note that it suggests keeping PRs under 400 lines of code, compared to the 2900 in this one :) Although, please don't take the 400 lines as a hard limit, I would imagine that the first T500 commit has to be a bit bigger since there's some boilerplate etc. that needs to exist.

cazzoo and others added 3 commits September 10, 2026 00:27
Add a model driver for the T500RS wheel base under src/tmt500rs,
implementing the full effect set (constant, spring, damper, friction,
periodic incl. square/ramp, incline) with slot-based effect upload,
workqueue-driven packet dispatch, range/gain/autocenter handling and
defensive state reset at probe.

Wire the T500RS product ID (0xb65e) into the core probe dispatch and
device table, and build the new object into the module. No other core
changes: gain and autocenter requests can arrive from input event
context (which may run with IRQs disabled) and from sysfs, both of
which cannot perform the blocking HID output this wheel requires, so
the driver itself defers them to a dedicated control worker with its
own DMA-safe buffer, mirroring its expiry/synth worker pattern.

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
Document the T500RS report/effect format observed from captures,
rename the existing effects doc to make its wheel family explicit,
and note T500RS support in the README and contributing guide.
@cazzoo
cazzoo force-pushed the feature/t500rs-driver-only branch from d75c624 to e0eef1e Compare September 9, 2026 22:29
@cazzoo

cazzoo commented Sep 9, 2026

Copy link
Copy Markdown
Author

Hi @Kimplul,

I am indeed in the works to split in chunks the driver.
I just moved the gain/autocenter defer onto a dedicated PR that I intent to open at first.
Then, for this one I was intending to have only 1 for the whole driver, but if I need to split it as well in small chunks, I can do it.

I will thy that "PR stack" feature github provides, hopefully it will make it clearer to review. Will cancel the previous ones

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants