Skip to content

Enhance memory management #348

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Oct 16, 2018
Merged

Enhance memory management #348

merged 7 commits into from
Oct 16, 2018

Conversation

fpistm
Copy link
Member

@fpistm fpistm commented Oct 4, 2018

This PR include:

@fpistm fpistm added enhancement New feature or request fix 🩹 Bug fix labels Oct 4, 2018
@fpistm fpistm self-assigned this Oct 4, 2018
@fpistm fpistm added this to the 1.3.1 milestone Oct 4, 2018
@fpistm fpistm force-pushed the memory branch 3 times, most recently from 6fa207e to efacd27 Compare October 10, 2018 13:44
@rayozzie
Copy link

I've tested these fixes on the Nucleo-L432KC, and they work perfectly. It would be helpful to get them released.

Thank you for doing this work!

Signed-off-by: Frederic.Pillon <[email protected]>
This will allow to user to override the default behavior.

Signed-off-by: Frederic.Pillon <[email protected]>
Minimum stack size is defined in linker script:
_Min_Stack_Size = 0x400;; /* required amount of stack */

If more stack is requested, then user have to ensure that heap
and stack can fit in the SRAM.

Fix stm32duino#307

Signed-off-by: Frederic.Pillon <[email protected]>
STM32L432xx SRAM is split into two blocks:
• 48 Kbyte mapped at address 0x2000 0000 (SRAM1)
• 16 Kbyte located at address 0x1000 0000 with hardware parity check (SRAM2).
This memory is also mapped at address 0x2000 C000, offering a contiguous address
space with the SRAM1 (16 Kbyte aliased by bit band

Signed-off-by: Frederic.Pillon <[email protected]>
STM32L476xx SRAM is split into two blocks:
• 96 Kbyte mapped at address 0x2000 0000 (SRAM1)
• 32 Kbyte located at address 0x1000 0000 with hardware parity check (SRAM2).

Only the SRAM1 is managed.
One enhancement could be done to use SRAM1 for the heap
and SRAM2 for the stack. (Refer to MBED)


Signed-off-by: Frederic.Pillon <[email protected]>
Signed-off-by: Frederic.Pillon <[email protected]>
@fpistm fpistm merged commit c6093d7 into stm32duino:master Oct 16, 2018
@fpistm fpistm deleted the memory branch October 16, 2018 07:11
benwaffle pushed a commit to benwaffle/Arduino_Core_STM32 that referenced this pull request Apr 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request fix 🩹 Bug fix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants