I know how this is done for USB gamepad but I cannot get it to work using a keyboard. I have a teensy 2.0 set up as a USB keyboard that is set up like a SNES controller so there is not a dedicated escape button.
Right now I have
# input_enable_hotkey_btn = enter
# input_exit_emulator = tab