2024-09-23 01:51 AM
Hello,
When I builed the project, I had seen the Hal drivers files links in the end file *.HEX.
How can I change the project configuration not to put this links in file because it use flash memory unnecessarily ?
Thanks
Solved! Go to Solution.
2024-09-23 06:43 AM
If you don't define USE_FULL_ASSERT these filenames are just for debug information. They do not occupy room in the flash.
2024-09-23 07:45 AM
If Debug level is different of "None" then these roots filenames are in rom flash.
The only solution is the "None" choice to have any root filename.
2024-09-23 07:51 AM
What do you mean by, "Debug level" ?
2024-09-23 07:53 AM
Yes "debug level".
I looked this on STM32G0 and stm32G4. not on STM32F0.
2024-09-23 07:57 AM
Ah - this:
I'll bet that 'None' causes USE_FULL_ASSERT to be not defined.
2024-09-23 08:09 AM - edited 2024-09-23 08:09 AM
@Fredolive wrote:How can I change the project configuration not to put this links in file because it use flash memory unnecessarily ?
Note that it's just putting the file names in as string literals - it's not linking any code.
2024-09-23 08:39 AM
Yes, it is rigth. But it used rom flash to anything.
2024-09-23 08:49 AM
You can get rid of it by not defining USE_FULL_ASSERT .
Or you could change your assert_param definition to not use __FILE__ and, thus, not require that the filenames be stored.
2024-09-23 11:46 PM
Hello,
Thanks for your help.
Now, it is Ok, and I haven't the roots names in my Hex File.
Best Regards
2024-09-24 02:48 AM
Excellent.
Now please mark the solution:
https://community.st.com/t5/community-guidelines/help-others-to-solve-their-issues/ta-p/575256