Add *_RIGHT
configuration for PMW33XX driver
#19243
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR allows to define different CS pin(s) for each half when using PMW33XX, in a similar way that it is done for matrix or encoder pins.
This is just a monkeypatch to extend the flexibility slightly while a completely flexible solution isn't available.
@freznel10 asked for a QoL solution on Discord, to avoid recompiling each half changing pins manually. As far as he has tested, everything seems to work fine. (i dont have the hw so i cant make any test)
The changes reduce to splitting some data structures which were common before into one for each side, and some defines to replace the old variable name with the correct data structure on each side.
Code was made with backwards compatibility in mind, thus everything defaults to be the same as left side if no configuration was provided, this should mean that nothing breaks.
While editing the docs i also noticed they stated
cable select
instead ofchip select
, and the default values weren't really listed, so i changed that tooTypes of Changes
Issues Fixed or Closed by This PR
Checklist