summaryrefslogtreecommitdiff
path: root/py/mpthread.h
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2016-04-25 11:21:48 +0000
committerDamien George <damien.p.george@gmail.com>2016-06-28 11:28:49 +0100
commit801d1b3803e4c8070a8bea6ee4f563a799d010b7 (patch)
tree5049f0f416ed64256e9ee6892afa209f1091bb71 /py/mpthread.h
parent2dacd604c51d27f08076e76abd91de43bc2481f3 (diff)
py/modthread: Implement lock object, for creating a mutex.
Diffstat (limited to 'py/mpthread.h')
-rw-r--r--py/mpthread.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/py/mpthread.h b/py/mpthread.h
index bbf27da50..498380a5e 100644
--- a/py/mpthread.h
+++ b/py/mpthread.h
@@ -39,6 +39,9 @@
mp_state_thread_t *mp_thread_get_state(void);
void mp_thread_set_state(void *state);
void mp_thread_create(void *(*entry)(void*), void *arg, size_t stack_size);
+void mp_thread_mutex_init(mp_thread_mutex_t *mutex);
+int mp_thread_mutex_lock(mp_thread_mutex_t *mutex, int wait);
+void mp_thread_mutex_unlock(mp_thread_mutex_t *mutex);
#endif // MICROPY_PY_THREAD