Skip to content

Commit 23ee9d9

Browse files
committed
codal_port: Use mp_sched_keyboard_interrupt, impl dummy mp_hal_time_ns.
To build with latest MicroPython. Signed-off-by: Damien George <damien@micropython.org>
1 parent 92d5e10 commit 23ee9d9

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

src/codal_port/drv_system.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,5 +47,5 @@ void microbit_hal_timer_callback(void) {
4747
}
4848

4949
void microbit_hal_serial_interrupt_callback(void) {
50-
mp_keyboard_interrupt();
50+
mp_sched_keyboard_interrupt();
5151
}

src/codal_port/mphalport.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,11 @@
3333
void mp_sched_schedule_exception(mp_obj_t exc);
3434
void mp_hal_set_interrupt_char(int c);
3535

36+
static inline uint64_t mp_hal_time_ns(void) {
37+
// Not currently implemented.
38+
return 0;
39+
}
40+
3641
// MicroPython low-level C API for pins
3742
#include "modmicrobit.h"
3843
#define mp_hal_pin_obj_t uint8_t

0 commit comments

Comments
 (0)