summaryrefslogtreecommitdiffstatshomepage
path: root/esp8266/modmachine.c
diff options
context:
space:
mode:
authorPaul Sokolovsky <pfalcon@users.sourceforge.net>2016-04-25 19:28:12 +0300
committerPaul Sokolovsky <pfalcon@users.sourceforge.net>2016-04-25 19:31:17 +0300
commit6d103b65482d8dc1d688fcfd59b3400ebfbe0f0f (patch)
treedc407b8c1aaeb9ac5d85f1110be7c487972cf275 /esp8266/modmachine.c
parent104aa26271d38fc6204fcee6d65044716e4dae31 (diff)
downloadmicropython-6d103b65482d8dc1d688fcfd59b3400ebfbe0f0f.tar.gz
micropython-6d103b65482d8dc1d688fcfd59b3400ebfbe0f0f.zip
py: Move call_function_*_protected() functions to py/ for reuse.
They almost certainly needed by any C code which calls Python callbacks.
Diffstat (limited to 'esp8266/modmachine.c')
-rw-r--r--esp8266/modmachine.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/esp8266/modmachine.c b/esp8266/modmachine.c
index c75f6e528d..c3c9494ac8 100644
--- a/esp8266/modmachine.c
+++ b/esp8266/modmachine.c
@@ -31,7 +31,6 @@
#include "py/runtime.h"
#include "extmod/machine_mem.h"
#include "extmod/machine_i2c.h"
-#include "utils.h"
#include "modpyb.h"
#include "modpybrtc.h"
@@ -137,7 +136,7 @@ STATIC mp_obj_t esp_timer_make_new(const mp_obj_type_t *type, mp_uint_t n_args,
STATIC void esp_timer_cb(void *arg) {
esp_timer_obj_t *self = arg;
- call_function_1_protected(self->callback, self);
+ mp_call_function_1_protected(self->callback, self);
}
STATIC mp_obj_t esp_timer_init_helper(esp_timer_obj_t *self, mp_uint_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) {