Download Verification Failed when programming stm32L152
Hardware used:STM32L152 Custom board
I've been using a STM32U585 Discovery kit for a few days and have succesfully run several programs on it. However today I suddenly got this error in STM32CubeIDE when trying to run a new program:
---------------------------------------------------------------------------------------------------------------
Error: Data mismatch found at address 0x0800899C (byte = 0x31 instead of 0x33)
Error: Download verification failed
---------------------------------------------------------------------------------------------------------------
Trying to upload different programs gave the same result, but with the mismatch at different addresses.
First time the code programmed successfully in the memory. After whenever I tried to program it using stmcube ide or stmcube programmer, it gives the verification failed error in the stmcube programmer and failed to erase memory in stmcube ide.
I have no option bytes enabled. I can erase the memory using stmcube programmer but stmcube ide gives the error and does not allow to program the mcu.
Please help me to find the solution of this issue.



