Is it possible to create RAM section for stm32l151rd? (It has only 1 Ram area)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-04-17 5:20 AM
Hello,
I know that it is possible for mcu which has several ram areas such as RAM_D1, RAM_D2 like STM32H7. STM32l1 has only one RAM. Because I can not divide RAM for some important data. But I saw an STM32L1 example created on KEIL and divided some adresses of this 1 RAM. Is it possible?
Thanks in advance.
- Labels:
-
RAM
-
STM32L1 Series
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-04-17 5:42 AM
The linker script allows you to describe and decompose they memory anyway you want.
​
I​f you want to divide one 16KB RAM section into two 8KB ones, you can do that. You can create holes in memory the linker is unaware of, and won't use.
Up vote any posts that you find helpful, it shows what's working..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-04-17 5:50 AM
Thank you for your answer! Do I need to use mpu so that the holes I create are not used by the linker?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-04-17 6:37 AM
> Do I need to use mpu so that the holes I create are not used by the linker?
No
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-04-17 11:53 AM
You can specify in the code which sections the data should go into. Then the linker script allows you to specify where to place the sections in memory.
The linker puts the data in the sections, and places the sections where you specify. If there's a place where you don't put anything, it's a hole.
