summaryrefslogtreecommitdiffstatshomepage
path: root/zephyr/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'zephyr/main.c')
-rw-r--r--zephyr/main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/zephyr/main.c b/zephyr/main.c
index 2c7f3fc477..d812f96092 100644
--- a/zephyr/main.c
+++ b/zephyr/main.c
@@ -64,8 +64,8 @@ int real_main(void) {
int stack_dummy;
stack_top = (char*)&stack_dummy;
mp_stack_set_top(stack_top);
- // Should be set to stack size in prj.mdef minus fuzz factor
- mp_stack_set_limit(3584);
+ // Make MicroPython's stack limit somewhat smaller than full stack available
+ mp_stack_set_limit(CONFIG_MAIN_STACK_SIZE - 512);
soft_reset:
#if MICROPY_ENABLE_GC