Damien George
2459162599
lib/utils/interrupt_char: Invalidate interrupt char at start up.
...
Otherwise mp_interrupt_char will have a value of zero on start up (because
it's in the BSS) and a KeyboardInterrupt may be raised during start up.
For example this can occur if there is a UART attached to the REPL which
sends spurious null bytes when the device turns on.
2019-05-01 12:41:07 +10:00
Damien George
ab954ed513
lib/utils/interrupt_char: Remove support for KBD_EXCEPTION disabled.
...
If a port is using interrupt_char.c then it must enable
MICROPY_KBD_EXCEPTION. This is the case for all official ports.
2017-06-02 12:03:57 +10:00
Damien George
6e74d24f30
py: Add micropython.schedule() function and associated runtime code.
2017-03-20 15:20:26 +11:00
Damien George
d89cafd5c3
lib/utils/interrupt_char: Use core-provided mp_kbd_exception if enabled.
...
Ultimately all ports that use lib/utils/interrupt_char would enable
MICROPY_KBD_EXCEPTION, so this is an interim solution.
2016-12-15 13:35:54 +11:00
Paul Sokolovsky
6ab2c5e6cc
lib/interrupt_char: Factor out typical Ctrl+C handling from esp8266 port.
...
Utility functions for keyboard interrupt handling, to be reused across
(baremetal) ports.
2016-09-29 10:15:38 -07:00