summaryrefslogtreecommitdiff
path: root/stmhal/main.c
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2014-03-22 15:06:29 +0000
committerDamien George <damien.p.george@gmail.com>2014-03-22 15:06:29 +0000
commitd311655655b72fcb898a8d35bfe926a9adb1bebd (patch)
tree118d15c618a96fe414a1a8c3bb6b3584fed03975 /stmhal/main.c
parentad7b84a7b9a1beb960d216995dd608b794440183 (diff)
stmhal: Add time module with sleep function.
Diffstat (limited to 'stmhal/main.c')
-rw-r--r--stmhal/main.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/stmhal/main.c b/stmhal/main.c
index 22f7be23e..2b4daa370 100644
--- a/stmhal/main.c
+++ b/stmhal/main.c
@@ -23,6 +23,7 @@
#include "pyexec.h"
#include "pybmodule.h"
#include "osmodule.h"
+#include "timemodule.h"
#include "usart.h"
#include "led.h"
#include "exti.h"
@@ -276,9 +277,10 @@ soft_reset:
// probably shouldn't do this, so we are compatible with CPython
rt_store_name(MP_QSTR_pyb, (mp_obj_t)&pyb_module);
- // pre-import the os module
+ // pre-import the os and time modules
// TODO don't do this! (need a way of registering builtin modules...)
rt_store_name(MP_QSTR_os, (mp_obj_t)&os_module);
+ rt_store_name(MP_QSTR_time, (mp_obj_t)&time_module);
// check if user switch held (initiates reset of filesystem)
bool reset_filesystem = false;