2024-05-15 03:45 PM - edited 2024-05-16 07:09 AM
I am having 2 major issues after upgrading STM32CubeIDE.
1) I get 2 error messages about segments having RWX permissions.
ld.exe: warning: QCMA00-1_0_0.elf has a LOAD segment with RWX permissions
I saw the release notes about changing the
.preinit_array :
to
.preinit_array (READONLY) :
and did that. Still get the error messages. Do I need to change multiple segments to READONLY? If so, which ones?
Second, I now cannot debug. I get an error message that MI command failed to execute. I enabled the log file and looked through it and what bothered me is the following lines:
[4.375] spawnCubeProgrammer(): ------ Switching to STM32CubeProgrammer -----
[4.375] file_utils_spawn(): Spawning "D:\STMicro\STM32Cube\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.win32_2.1.201.202404072231\tools\bin\STM32_Programmer_CLI.exe --connect port=SWD speed=fast mode=UR reset=hwRst --download C:\Users\ROBERT~1\AppData\Local\Temp\ST-LINK_GDB_server_a10576.srec --verify --log C:\Users\ROBERT~1\AppData\Local\Temp\STM32CubeProgrammer_a10576.log"
[4.494] file_utils_spawn(): Return code -1073741511
[4.494] spawnCubeProgrammer(): Encountered Error when opening D:\STMicro\STM32Cube\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.win32_2.1.201.202404072231\tools\bin\STM32_Programmer_CLI.exe
[4.494] spawnCubeProgrammer(): ------ Switching context -----
[4.494] WriteFlashDone(): Error in STM32CubeProgrammer
This is multiple places in the log file. Now, I had this working a couple weeks ago with no issues. I had to spin the board and just got back to this. I have edited nothing, I just updated STM32CubeIDE and tried to run the same project that worked a couple weeks back. I even tried installing STM32CubeIDE on a virgin OS installation and got all the same errors. I have attached my debugger log file. I am at a loss righ now. Thanks
2024-05-16 07:09 AM - edited 2024-05-16 07:45 AM
Note, I reverted to 14.1 and everything runs smooth as silk. Release 15.x is just plain broken for me. I'd still like to know why release 15 is so broken and steps to fix it on my system.
2024-05-20 07:15 AM
Hi Robert,
Regarding your 2nd issue, after upgrading STM32CubeIDE, did you re-opened the same workspace? If this is the case, can you try to create a new workspace and import your project in the new workspace? I noted that sometime, a new version of the IDE is not 100% compatible with the workspace settings of a previous version.
A simple and not disruptive way to try this is by renaming the .metadata folder. For example:
1. exit STM32CubeIDE
1. suppose that your host PC runs Windows and your workspace is in C:\MyWorkspaceRootFolder
2. rename the folder C:\MyWorkspaceRootFolder\.metadada (for example to C:\MyWorkspaceRootFolder\.metadada_old_cubeide)
3. re-start STM32CubeIDE. You will note that the IDE will create another new .metatada folder.
4. import your project and check if you are able to start a debug session.
5. if the issue persist, then delete the new .metadata folder and revert the name of .metadada_old_cubeide
Hope this can help.
Best regards,
Stefano
2024-05-21 12:39 PM
Thank you for the suggestions. I have to get a project out and don't really have time to load and unload the program versions right now but when I wrap up this project, I will give this a try.