Closed Tetrahedrite closed 3 weeks ago
Hello @Tetrahedrite,
Thank you for this report. We will get back to you as soon as we analyze it further. This may take some time. Thank you for your comprehension.
With Regards,
ST Internal Reference: 188784
Hello @Tetrahedrite,
After check your sequence, it seems not inline with a real state, if you fully used HAL interface. As at reset, the write protection is not enabled, this mean that the writeoperation is enabled at reset.
This mean, that if you called the hal sram init, a the end with the status ready, the SRAM is ready to be written.
If you call the function HAL_SRAM_WriteOperation_Enable, a return code is set to error, as currently the write operation is already enabled.
If you call the functin HAL_SRAM_WritreOperation_Disable, at that stage the write protection will be enabled and so calling a function HAL_SRAM_Write_xxx will generate a return code error, as state is not ready, but protected.
So could describe more your usecase, by using HAL.
thx and Regards
Hello @Tetrahedrite,
Please allow me to close this thread as there is no activity. Thank you for your understanding.
With regards,
Fixes SRAM HAL code always set
State
toHAL_SRAM_STATE_READY
evenWriteOperation
is not set.How does it make problem before?
If you initialize SRAM with
WriteOperation
disabled, It setState
toHAL_SRAM_STATE_READY
. Then try to write SRAM falls intoHardFault_Handler
. Even you can't enableWriteOperation
viaHAL_SRAM_WriteOperation_Enable
function because the function testsState == HAL_SRAM_STATE_PROTECTED
.IMPORTANT INFORMATION
Contributor License Agreement (CLA)