ArduinoMenu
ArduinoMenu copied to clipboard
The encoder’s “wicked inheritance” messes up the menu’s navigation mode!
Hello… My encoder has other uses besides navigating through the options provided in the menu. In this way, when entering the navigation mode, the menu code´s input streamer “remembers” the steps given to the encoder outside the navigation mode. Then, as we engage in the menu’s navigation mode, the cursor moves erratically through the menu options. Evidently, this causes confusion and unnecessary delays because the cursor does not move into a new step until the screen has been refreshed to acknowledge the previous one.
Like I already mentioned, my app uses the encoder in many ways and sometimes we yank the encoder as if our life depended on it. Then, as we poll the menu's code, the cursor drives us nuts before settling down on whatever option was pre-selected by the encoder’s previous usage.
Is there a wat to avoid this from happening? That is, will it be possible to rotate the encoder outside the menu code and that these stimuli are not transferred to the cursor once we poll the menu’s navigation mode?
Best regards, Neftalí Loya Garibay
Hi! See codeCtrl example, and take ownership of the encoder then issue menu commands when appropriate.