• Sure, MCP23017 has a really nice event / interrupt features...

    Configure an interrupt, connect it to a pin and watch that pin for the press off a button. On event, scan the keyboard, set a different interrupt and watch for the release of the button. This way you preserve the most cycles.

    Simpler - but spending cycles - is to scan the keyboard every 20..100 ms. A simple scan will not distinguish nor prevent multi button presses. The existing module makes MCP23017 pin usage quite transparent.

About

Avatar for allObjects @allObjects started