Bootloader inconsistant
Hi Everybody,
I am trying to test out the boot-loader of the stm32l412 as a part of development for a product my company is making. For reasons unknown to me, the STM32cubeprogrammer (v2.10.0) can only sometimes program my MCU . I made a batch script that looks something like the following, and I run it in power-shell.
~~~~~~~~~~~~~~~ script start
echo off
if NOT .%1 == . goto ok
echo Error: specify Debug or Release
goto done
if NOT .%2 == . goto ok
echo Error: need com port as argument
goto done
:ok
C:\Users\mcocke\Desktop\WorkFiles\ProjectFiles\SomeFolder\STM32CubeProgrammer\bin\STM32_Programmer_CLI.exe -c port=%2 dtr=low rts=low br=115200 P=EVEN db=8 sb=1 -w C:\Users\mcocke\Desktop\WorkFiles\GithubRepos\OtherFolder\STM32L412CBU6\%1\STM32L412CBU6.elf 0x800000000 -V
:done
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ script end
My issue is that sometimes (I think 50% of the time on a good day) the programming works, and the other times I receive "Error: Activating device: KO. Please, verify the boot mode configuration and check the serial port configuration. Reset your device then try again..." from the programmer CLI application. I am not power cycling anything, changing my script, or modifying anything, and yet I am not getting consistent results.
Any help would be appreciated!
Best,
Matthew Cocke
