Checking for button presses in the background makes it much easier to write interactive programs, as we no longer have to worry about missing them. It would be nice to have a similar functionality for touch inputs, so that buttons and touch pads would truly be interchangeable, and could be handled by similar code.
Perhaps we could add a TouchPads class to the keypad module, which would only be compiled if touchio is enabled, and which would do the same as keypad.Keys, but with touch pads instead of buttons?
Checking for button presses in the background makes it much easier to write interactive programs, as we no longer have to worry about missing them. It would be nice to have a similar functionality for touch inputs, so that buttons and touch pads would truly be interchangeable, and could be handled by similar code.
Perhaps we could add a
TouchPadsclass to thekeypadmodule, which would only be compiled iftouchiois enabled, and which would do the same askeypad.Keys, but with touch pads instead of buttons?