Requires BUTTON defined in hwconfig, so far tested on DragonBoard 410c.
This requires recently added implementation of machine.Pin from micropython-lib.