Closed
Description
The current options in the portable/MemMang
directory cannot provide thread safety for those Arduino libraries that directly call malloc()
family of functions (e.g. STM32SD, String).
I have ported some code here: RoboTech-srl@897009a
Before making a PR, I was wondering if configMEMMANG_HEAP_NB == -1
was a good choice. I thought the number of heap implementations might grow in future versions, so I went negative. What do you think @fpistm ?
I also think that the default _sbrk()
provided by the core must be defined as a "weak" symbol for this to work. See fortebit/fortebit-openiot-stm32-core@169ced0