summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorPaul Sokolovsky <pfalcon@users.sourceforge.net>2016-05-31 21:46:02 +0300
committerPaul Sokolovsky <pfalcon@users.sourceforge.net>2016-05-31 21:46:02 +0300
commit15eb1ce52d27ee6ef18c9364f3274662bce1158e (patch)
treeb929bd98819986041502f431ef9f2ed60fb3aa59
parent33168081f48634d45902f0a31a27d4527c88a522 (diff)
downloadmicropython-15eb1ce52d27ee6ef18c9364f3274662bce1158e.tar.gz
micropython-15eb1ce52d27ee6ef18c9364f3274662bce1158e.zip
esp8266: Enable MICROPY_PY_IO_FILEIO to get compliant text/binary streams.
-rw-r--r--esp8266/mpconfigport.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/esp8266/mpconfigport.h b/esp8266/mpconfigport.h
index df78444883..544edc408f 100644
--- a/esp8266/mpconfigport.h
+++ b/esp8266/mpconfigport.h
@@ -42,6 +42,7 @@
#define MICROPY_PY_MATH (1)
#define MICROPY_PY_CMATH (0)
#define MICROPY_PY_IO (1)
+#define MICROPY_PY_IO_FILEIO (1)
#define MICROPY_PY_STRUCT (1)
#define MICROPY_PY_SYS (1)
#define MICROPY_PY_SYS_MAXSIZE (1)
@@ -114,6 +115,9 @@ typedef uint32_t sys_prot_t; // for modlwip
#define MP_PLAT_PRINT_STRN(str, len) mp_hal_stdout_tx_strn_cooked(str, len)
+#define mp_type_fileio fatfs_type_fileio
+#define mp_type_textio fatfs_type_textio
+
// extra built in names to add to the global namespace
#define MICROPY_PORT_BUILTINS \
{ MP_OBJ_NEW_QSTR(MP_QSTR_help), (mp_obj_t)&mp_builtin_help_obj }, \