Increase stack size (Back-port #2393 to 4.x)
This commit is contained in:
parent
d4bb108e3b
commit
241988b3d1
@ -1 +1 @@
|
||||
Subproject commit b9280af5142fc41639229544678e23b5cca07c3a
|
||||
Subproject commit cf7eabc4fa079a1443f548aed8ee2966af9b5fc1
|
@ -1 +1 @@
|
||||
Subproject commit 154b74de020764597ba49f0d1e8cc18d55b3643b
|
||||
Subproject commit f042c596105d1cfd3a1a2ca2c6035b188fc5f6e6
|
@ -1 +1 @@
|
||||
Subproject commit 617bb0787f2c61283d248632a62b27be80f64b29
|
||||
Subproject commit 5534662902a223ac8562e6f999d6359e4c17dab1
|
@ -1 +1 @@
|
||||
Subproject commit 409e90902ac49720c4add985e8e1a1660bbe63a0
|
||||
Subproject commit 01e89a8437c78b62d4d655c745ded57e26dc747a
|
@ -1 +1 @@
|
||||
Subproject commit 89faee0eb08a6855e14f117c514fecf2dd90769d
|
||||
Subproject commit a23b80569f23ef109667dd8c595d319e8a30d620
|
@ -1 +1 @@
|
||||
Subproject commit 70865ac6e09f821b26ec727e2df300a6d9ebf6b3
|
||||
Subproject commit 8b7611a2cc076a2ac1b368c70227519f69f1e3e9
|
@ -1 +1 @@
|
||||
Subproject commit bd7ddc67dc86f7ad0115f58ab80d5605739c6482
|
||||
Subproject commit 53146ab2e82c318c3c37bd76bac34035a597b311
|
@ -1 +1 @@
|
||||
Subproject commit ddc74844983b35b027bd45091c7b8bb3c8d7a2d1
|
||||
Subproject commit f69fc9b47fa25ba1414eb3d5c82f05013280c0d2
|
@ -1 +1 @@
|
||||
Subproject commit c0bdd8b10383725ee9293f5d88fb8d47eb1272bd
|
||||
Subproject commit ff99d55115f81899902c2c4a84fdfbea9ae83823
|
@ -1 +1 @@
|
||||
Subproject commit 893c5ec6a9aeef38284985074c2058e87754ad3d
|
||||
Subproject commit 2e5aedf18eb417a4120d4998ac1f387a4f600730
|
@ -1 +1 @@
|
||||
Subproject commit f1171f94083ba64d153ff3f90eeb07500331d6e1
|
||||
Subproject commit ea5e445edd4441cacd207aa2d2bfd724b813a253
|
@ -1 +1 @@
|
||||
Subproject commit 6d1ae72916cf240ea86185c45f844d59f56d8ec3
|
||||
Subproject commit c1d8e1d645cbc83d857e12cf4ba67549b988a4e7
|
@ -33,6 +33,9 @@
|
||||
// Explanation of how a user got into safe mode.
|
||||
#define BOARD_USER_SAFE_MODE_ACTION "pressing both buttons at start up"
|
||||
|
||||
// Increase stack size slightly due to CPX library import nesting
|
||||
#define CIRCUITPY_DEFAULT_STACK_SIZE (4632) // Must be divisible by 8 or will HardFault.
|
||||
|
||||
#define DEFAULT_I2C_BUS_SCL (&pin_PB03)
|
||||
#define DEFAULT_I2C_BUS_SDA (&pin_PB02)
|
||||
|
||||
|
@ -33,6 +33,9 @@
|
||||
// Explanation of how a user got into safe mode.
|
||||
#define BOARD_USER_SAFE_MODE_ACTION "pressing both buttons at start up"
|
||||
|
||||
// Increase stack size slightly due to CPX library import nesting
|
||||
#define CIRCUITPY_DEFAULT_STACK_SIZE (4632) // Must be divisible by 8 or will HardFault.
|
||||
|
||||
#define DEFAULT_I2C_BUS_SCL (&pin_PB03)
|
||||
#define DEFAULT_I2C_BUS_SDA (&pin_PB02)
|
||||
|
||||
|
@ -34,7 +34,6 @@
|
||||
#define CIRCUITPY_MCU_FAMILY samd21
|
||||
#define MICROPY_PY_SYS_PLATFORM "Atmel SAMD21"
|
||||
#define SPI_FLASH_MAX_BAUDRATE 8000000
|
||||
#define CIRCUITPY_DEFAULT_STACK_SIZE 4096
|
||||
#define MICROPY_PY_BUILTINS_NOTIMPLEMENTED (0)
|
||||
#define MICROPY_PY_COLLECTIONS_ORDEREDDICT (0)
|
||||
#define MICROPY_PY_FUNCTION_ATTRS (0)
|
||||
@ -69,6 +68,7 @@
|
||||
#define MICROPY_PY_UJSON (1)
|
||||
#define MICROPY_PY_REVERSE_SPECIAL_METHODS (1)
|
||||
// MICROPY_PY_UERRNO_LIST - Use the default
|
||||
|
||||
#endif
|
||||
|
||||
// Turning off audioio, audiobusio, and touchio as necessary
|
||||
@ -78,6 +78,19 @@
|
||||
|
||||
#include "py/circuitpy_mpconfig.h"
|
||||
|
||||
|
||||
#ifdef SAMD21
|
||||
#ifndef CIRCUITPY_DEFAULT_STACK_SIZE
|
||||
#define CIRCUITPY_DEFAULT_STACK_SIZE 4096
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef SAMD51
|
||||
#ifndef CIRCUITPY_DEFAULT_STACK_SIZE
|
||||
#define CIRCUITPY_DEFAULT_STACK_SIZE (24*1024)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#define MICROPY_PORT_ROOT_POINTERS \
|
||||
CIRCUITPY_COMMON_ROOT_POINTERS \
|
||||
mp_obj_t playing_audio[AUDIO_DMA_CHANNEL_COUNT];
|
||||
|
@ -61,10 +61,11 @@ for region in regions:
|
||||
space = M_PATTERN.sub(M_REPLACE, space)
|
||||
regions[region] = eval(space)
|
||||
|
||||
ram_region = regions["RAM"]
|
||||
free_flash = regions["FLASH"] - text - data
|
||||
free_ram = regions["RAM"] - data - bss
|
||||
print(free_flash, "bytes free in flash out of", regions["FLASH"], "bytes (", regions["FLASH"] / 1024, "kb ).")
|
||||
print(free_ram, "bytes free in ram for stack out of", regions["RAM"], "bytes (", regions["RAM"] / 1024, "kb ).")
|
||||
print("{} bytes free in ram for stack and heap out of {} bytes ({}kB).".format(free_ram, ram_region, ram_region / 1024))
|
||||
print()
|
||||
|
||||
# Check that we have free flash space. GCC doesn't fail when the text + data
|
||||
|
Loading…
Reference in New Issue
Block a user