From 4f811d0e4c1a21bbfd23992b76c29971384928ec Mon Sep 17 00:00:00 2001 From: Paul Sokolovsky Date: Fri, 15 Apr 2016 00:08:39 +0300 Subject: [PATCH] esp8266: Enable input() builtin. --- esp8266/Makefile | 1 + esp8266/mpconfigport.h | 1 + esp8266/qstrdefsport.h | 1 + 3 files changed, 3 insertions(+) diff --git a/esp8266/Makefile b/esp8266/Makefile index f36e283b1f..81fa53e8d7 100644 --- a/esp8266/Makefile +++ b/esp8266/Makefile @@ -83,6 +83,7 @@ SRC_C = \ STM_SRC_C = $(addprefix stmhal/,\ pybstdio.c \ + input.c \ ) EXTMOD_SRC_C = $(addprefix extmod/,\ diff --git a/esp8266/mpconfigport.h b/esp8266/mpconfigport.h index 577b373981..e97856d672 100644 --- a/esp8266/mpconfigport.h +++ b/esp8266/mpconfigport.h @@ -105,6 +105,7 @@ typedef uint32_t sys_prot_t; // for modlwip // extra built in names to add to the global namespace #define MICROPY_PORT_BUILTINS \ + { MP_OBJ_NEW_QSTR(MP_QSTR_input), (mp_obj_t)&mp_builtin_input_obj }, \ { MP_OBJ_NEW_QSTR(MP_QSTR_open), (mp_obj_t)&mp_builtin_open_obj }, // extra built in modules to add to the list of known ones diff --git a/esp8266/qstrdefsport.h b/esp8266/qstrdefsport.h index dc9efe06fd..7b1d813cbb 100644 --- a/esp8266/qstrdefsport.h +++ b/esp8266/qstrdefsport.h @@ -27,6 +27,7 @@ // qstrs specific to this port Q(help) +Q(input) // pyb module Q(pyb)