Button matrix using bounce library possible?

i want to use the bounce library instead of keypad.h since it supports fallingEdge() and risingEdge(). I haven't been able to find button matrix examples using the library. is a button matrix using it even possible ? . i am using on-off switches thus the pressed,released functions of keypad will not work. Example (euro truck sim2 uses T for trailer attached and T for trailer detach. To get this to work using keypad.h i would have to go from off to on for attach then back to off and back to on to detach.This breaks the realizism.) with bounce i can simply use rising edge and falling edge to send the signals.

Here's what I use for my projects and libraries: Arduino Helpers: ButtonMatrix< Derived, NumRows, NumCols > Class Template Reference

You can find an example here: Button Matrix Helper Example · Discussion #526 · tttapa/Control-Surface · GitHub

You could use the MoToButtons class of my MobaTools library. It supports edgedetection (pressed,released), shortpress, longpress, click, doubleclick. Up to 32 buttons can be handled in one instance. Because the raw reading of the buttons can be done by a callback function there is no problem to use it with a button matrix.
There is also an example with a 4x4 matrix connected via I2C.
The lib can be installed by means of the library manager.

this could work

You can give it a try :wink: