2020-07-28 02:24 AM
Hi,
I am currently trying to develop the Audio device on STM32F0 to stream audio data from USB to IS2 signal, although It worked without any issues on STM32F4 discovery board, when I am trying to apply same logic for Nucleo32 It does not seem to work at all. Windows displays the board like so:
I will try to describe my problem in more details; after successful compilation, while debugging, program stops on HardFault_Handler(); . Code part that seems to be error cause is in usbd_audio.c file in Middlewares section of the project.
I tried to add more heap memory to solve this issue but changing it in the project does not seem to affect STM32F042K6TX_FLASH.ld and when I change it manually it gives an compilation error.
The code is generated through STM32CubeMX, I have not done anything to it. Still I will attach them if someone would like to look through it.
Am I on good track? Did anyone had that issue before? Please share your thoughts.
Solved! Go to Solution.
2020-07-29 09:30 AM
Part claims to have 6KB of RAM, and you're accessing ~15KB deep into it.
You're buffer can't be 15360 bytes deep.
2020-07-29 09:30 AM
Can't have a 15KB buffer in a 6KB part, reevaluate
2020-07-29 10:35 AM
That's right, this MCU have no enough RAM.
2020-07-29 01:16 PM
Oh thank you all for your time. Problem has been resolved.
2020-08-06 07:22 AM
Hello @MWask.1 ,
Please share the way that solved your problem, it may be helpful for other community users.
Then, please select the post of user which is "Best Answer" or mark your post as answered the question,
Best Regards,
Imen
2020-08-12 05:02 AM
Hi @Imen DAHMEN ,
This uC can not be used as Audio device. The reason is not enough RAM as @Community member and @prain stated. To resolve the problem I switched to different STM32 with enough memory for the task.