8000 try to address sys module, compile ok · sparkfun/circuitpython@8640d37 · GitHub
[go: up one dir, main page]

Skip to content

Commit 8640d37

Browse files
committed
try to address sys module, compile ok
1 parent 6333cff commit 8640d37

File tree

2 files changed

+8
-6
lines changed

2 files changed

+8
-6
lines changed

ports/nrf/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ SRC_C += \
116116
lib/utils/context_manager_helpers.c \
117117
lib/utils/pyexec.c \
118118
lib/utils/stdout_helpers.c \
119+
lib/utils/sys_stdio_mphal.c \
119120
lib/libc/string0.c \
120121
lib/mp-readline/readline.c \
121122

ports/nrf/mpconfigport.h

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -100,13 +100,13 @@
100100
#define MICROPY_PY_BUILTINS_SLICE_ATTRS (0)
101101
#define MICROPY_PY_SYS_EXIT (1)
102102
#define MICROPY_PY_SYS_MAXSIZE (1)
103-
#define MICROPY_PY_SYS_STDFILES (0)
104-
#define MICROPY_PY_SYS_STDIO_BUFFER (0)
103+
#define MICROPY_PY_SYS_STDFILES (1)
104+
#define MICROPY_PY_SYS_STDIO_BUFFER (1)
105105
#define MICROPY_PY_COLLECTIONS_ORDEREDDICT (0)
106106
#define MICROPY_PY_MATH_SPECIAL_FUNCTIONS (0)
107107
#define MICROPY_PY_CMATH (0)
108-
#define MICROPY_PY_IO (0)
109-
#define MICROPY_PY_IO_FILEIO (0)
108+
#define MICROPY_PY_IO (1)
109+
#define MICROPY_PY_IO_FILEIO (1)
110110
#define MICROPY_PY_UERRNO (0)
111111
#define MICROPY_PY_UBINASCII (1)
112112
#define MICROPY_PY_URANDOM (0)
@@ -161,6 +161,9 @@ typedef int mp_int_t; // must be pointer size
161161
typedef unsigned int mp_uint_t; // must be pointer size
162162
typedef long mp_off_t;
163163

164+
#define MP_PLAT_PRINT_STRN(str, len) mp_hal_stdout_tx_strn_cooked(str, len)
165+
#define mp_type_fileio mp_type_vfs_fat_fileio
166+
164167
// extra built in modules to add to the list of known ones
165168

166169
extern const struct _mp_obj_module_t microcontroller_module;
@@ -223,8 +226,6 @@ extern const struct _mp_obj_module_t mp_module_ubluepy;
223226
const char *readline_hist[8]; \
224227
mp_obj_t gamepad_singleton; \
225228

226-
#define MP_PLAT_PRINT_STRN(str, len) mp_hal_stdout_tx_strn_cooked(str, len)
227-
228229
// We need to provide a declaration/definition of alloca()
229230
#include <alloca.h>
230231

0 commit comments

Comments
 (0)
0