2023-03-15 05:29 AM
I am using the GUI version and the command line tool to work with a device, but one of these tools has a bug. Checking which bank is use to boot from I get clearly contradictory results. See screenshot. Which tool tells me the bank used to boot from?
CLI: 2.13.0
GUI: 2.12.0 (update not possible; that will be yet another bug report...)
Solved! Go to Solution.
2023-03-16 07:41 AM
Hello @ADiet.1,
To know where the MCU is booting from, you can check the Program Counter (PC) under MCU Core tab in GUI or by using the following CLI :
>STM32_Programmer_CLI -c port=SWD -coreReg PC
As for the bug you're seeing, could you please clarify your request further ? Steps to reproduce and sharing logs can go a long way.
Thanks,
Aziz
2023-03-16 07:41 AM
Hello @ADiet.1,
To know where the MCU is booting from, you can check the Program Counter (PC) under MCU Core tab in GUI or by using the following CLI :
>STM32_Programmer_CLI -c port=SWD -coreReg PC
As for the bug you're seeing, could you please clarify your request further ? Steps to reproduce and sharing logs can go a long way.
Thanks,
Aziz
2023-03-16 11:35 PM
Oh sorry, I posted the wrong screenshot. I changed the screenshot which shows the output of the CLI and the GUI together. As you can see it shows contradictory results.
Also, what is a "program counter"?
2023-03-17 12:13 AM
The Program Counter is an MCU register that points to the machine code instruction it is currently executing.
It will give a hint as to what's going on internally.
2023-03-21 06:32 AM
Hello @ADiet.1,
Sorry for the late reply, I missed the "contradictory results" part at first. Could you specify what are the contradictory results ?
Are you referring to the BFB2 value ?
Aziz
2023-03-23 01:49 AM
Hello @ADiet.1,
From my side for the same Option Bytes configuration.
Using 2.12.0 :
Using 2.13.0 :
There must be a reason behind us having different results. So to debug the situation further, I need to know if :
- You aren't modifying Options Bytes via GUI without hitting apply.
- You aren't modifying Option Bytes via your application (this shouldn't be an issue when using the same connection mode, but just to be sure).
If you can reproduce this with the flash erased. Could you share a screen recording where you :
1- Blank check the flash, you can use :
>STM32_Programmer_CLI -c port=SWD -blankcheck
2- Display your Option Bytes configuration (v2.13.0) :
>STM32_Programmer_CLI -c port=SWD -ob displ
3- Connect and show your option bytes configuration via GUI (v2.12.0).
I know this is too much to ask, but since I can't reproduce your issue from my side, this is the only way to confirm it.
Thanks,
Aziz