diff options
Diffstat (limited to 'stm/main.c')
-rw-r--r-- | stm/main.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/stm/main.c b/stm/main.c index 8279a9b7f4..44be4d348c 100644 --- a/stm/main.c +++ b/stm/main.c @@ -24,6 +24,7 @@ #include "lexerfatfs.h" #include "parse.h" #include "obj.h" +#include "objmodule.h" #include "parsehelper.h" #include "compile.h" #include "runtime0.h" @@ -272,9 +273,8 @@ soft_reset: rt_store_name(MP_QSTR_help, rt_make_function_n(0, pyb_help)); rt_store_name(MP_QSTR_open, rt_make_function_n(2, pyb_io_open)); - // we pre-import the pyb module - // probably shouldn't do this, so we are compatible with CPython - rt_store_name(MP_QSTR_pyb, (mp_obj_t)&pyb_module); + // load the pyb module + mp_module_register(MP_QSTR_pyb, (mp_obj_t)&pyb_module); // check if user switch held (initiates reset of filesystem) bool reset_filesystem = false; |