-
-
Notifications
You must be signed in to change notification settings - Fork 193
Improve Logitech G535 support #266
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
Conversation
src/devices/logitech_g535.c
Outdated
| if (num != 0 && num != 1 && num != 2 && num != 5 && num != 10 && num != 15 && num != 30) { | ||
| return HSC_OUT_OF_BOUNDS; | ||
| } |
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.
Don't know if there is a cleaner way to check if num is one of the accepted values in C, normally I'd check if num is in an array of the accepted values but that looks very complicated to do in C 😂
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.
I Will improve that today. It needs an error message with the correct values and a good way would be to round the user supplied value to multiple of 5 for num > 3 and then to use that. So that the user does not have to look up the correct values before that (except of maximum)
|
When will this be merged? |
Waiting for the second round of reviews, no ETA |
Will merge it today, after I made a small improvement in the out of bounds check |
Building upon #234, this will improve the Logitech G535 support by adding battery status and inactive time.