How to read/write to STM32L071B flash memory using LL/Registers ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-04-21 2:07 AM
Hello, I am trying to find LL functions parallel to those in HAL library that support Flash programming and it looks like there is not support in LL for r/w flash. As HAL library is not an option for me, I am wondering if it is possible <writing directly to registers> achieve this goal, not so easy for me though.
Any help/suggestion in how to go about it would be greatly appreciated
Solved! Go to Solution.
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-04-21 6:27 AM
The RM would be the best reference to use for writing to the FLASH. It is more complicated than RAM, but should be quite manageable. There are even code examples for how to do this in the RM. See "A.3.9 Program a single word to Flash program memory code example". Note that flash needs unlocked first.
Reading flash memory should be a trivial task. There are no special considerations here, read it the same as yo would RAM.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-04-21 6:27 AM
The RM would be the best reference to use for writing to the FLASH. It is more complicated than RAM, but should be quite manageable. There are even code examples for how to do this in the RM. See "A.3.9 Program a single word to Flash program memory code example". Note that flash needs unlocked first.
Reading flash memory should be a trivial task. There are no special considerations here, read it the same as yo would RAM.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-04-22 7:53 PM
Thank you @TDK
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2024-01-05 4:30 AM
Still, LL should be provided.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2024-01-05 4:51 AM
Well, Cube is open source, so you can "translate" the Cube/HAL based examples into register accesses, and then "reverse translate" those to the Cube/LL macros/functions.
JW
