-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(CompositeDevice): Add persist option #285
feat(CompositeDevice): Add persist option #285
Conversation
* Add CompositeDevice config bool option 'persist' * If persist is true then continue running CompositeDevice when all SourceDevices have been removed * Update clear_state for Gamepad targets to default all inputs to stop all input from continuing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this change! I think this is a great option to include :)
There are just a few small things in this to address and I think we can include this.
… or usb virtual devices to reset their state
Thanks for the feedback @ShadowApex ! I've made the updates for the hidraw and usb targets, I totally missed that their tracked state was being used in that way. I do agree that applying |
Oh, nice! I thought that might cause issues. Let me also do some testing to double check that this will re-center those joysticks. If everything works, we should be able to merge this in. Thanks! |
I have a few questions on usability. It seems this is only implemented as a config option. That makes me think there are a few cases we need to consider. Don't consider any of these blocking necessarily, but I want to discuss and have a plan at a minimum before we merge.
|
…ive sources hashmap
Definitely some more things to think about @pastaq and probably not for me to necessarily answer as a new contributor. It did give me a few more ideas for edge cases to test for though like if you plug in the controller when was connected via wireless, which currently would create a second persistent CompositeDevice though I have a fix in mind for that. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested and works great! Once the merge conflict has been resolved, we should be able to merge this in!
Thanks!
🎉 This PR is included in version 0.47.0 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
This improvement is to handle cases where a SourceDevice is disconnected to maintain the existing TargetDevice