A Python module to get the pressed key
pip3 install pygetkey
pip3 install git+https://github.com/donno2048/getkey
import getkey
getkey.get_key() # Wait for a key to be pressed and return it
getkey.get_last_key() # Don't wait for a key to be pressed and return the last pressed key (mainly for "async" loops)