-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
[enhancement] Expose FSM_ROTARY_ENCODER macros for flexible rotary encoder support (with variant example) #8060
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
base: develop
Are you sure you want to change the base?
Conversation
|
interesting, so this rotary encoder type one is not only for T-Lora Pager. might be worth looking at #7986, it drastically improves the usability and responsiveness of this rotary encoder implementation, could use some feedback on whether it works on this variant as well. if so, FSM_ROTARY_ENCODER_CHECK_INTERVAL would not be necessary anymore as my version gets rid of periodic polling completely. besides this point, it doesnt seem like these 2 PRs will conflict. i reverted renaming the class in my PR, and i would imagine removing the T_LORA_PAGER define checks and adding the FSM_ROTARY_ENCODER define to tlora-pager variant for your PR would help going forward. |
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.
please remove the T_LORA_PAGER defines as well as suggested by @WillyJL
Hi @WillyJL, T_LORA_PAGER macro for rotary encoder is removed, I also added FSM_ROTARY_ENCODER to variant.h of tlora_pager. |
Summary
This PR exposes macros for flexible rotary encoder support and provides a DIY configuration example.
Main contributions:
Expose FSM_ROTARY_ENCODER related macros
FSM_ROTARY_ENCODER
FSM_ROTARY_ENCODER_DEBOUNCE
(debounce time in ms)FSM_ROTARY_ENCODER_CHECK_INTERVAL
(scan interval / loop iterations)These macros were previously only available via the
T_LORA_PAGER
build.By exposing them, rotary encoder functionality can now be reused on other boards, and behavior can be tuned as needed.
DIY configuration example
Hardware details of the DIY setup (NovaLoRa):
This configuration is specific to my DIY hardware but serves as a reference for other DIY projects integrating rotary encoders.
Testing: Confirmed on the DIY setup with no regressions on other supported boards.
Notes: Happy to split this PR if maintainers prefer macro exposure separate from the example.
Attestations