STM32CubeMX v2.25 Bug Report ''SW4STM32Project generation have a problem''
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-04-09 1:05 AM
I have a pretty simple project and at some point I got this error when generating code:
The Code is successfully generated under ...
but SW4STM32Project generation have a problem
In the console I have this error:
2018-04-09 09:37:48,072 [INFO] UtilMem:74 - End SaveConfig() Used Memory: 203881040 Bytes (775421952)
2018-04-09 09:37:48,098 [INFO] ProjectBuilder:299 - [PM] Start Project Generation Thread2018-04-09 09:37:48,211 [INFO] BlockDiagram:1141 - set Specific Code input for plugin: ADC2018-04-09 09:37:48,211 [INFO] BlockDiagram:1141 - set Specific Code input for plugin: SPI2018-04-09 09:37:48,211 [INFO] BlockDiagram:1141 - set Specific Code input for plugin: NVIC2018-04-09 09:37:48,212 [INFO] BlockDiagram:1141 - set Specific Code input for plugin: SYS2018-04-09 09:37:48,212 [INFO] BlockDiagram:1141 - set Specific Code input for plugin: I2C2018-04-09 09:37:48,942 [INFO] CodeGenerator:499 - code generatio: config db path: /opt/STM32CubeMX//db/2018-04-09 09:37:49,068 [INFO] CodeEngine:181 - oldGeneratedFile, /temp/Src/license.tmp_save2018-04-09 09:37:49,594 [INFO] CodeEngine:199 - Generated code: /temp/Src/license.tmp2018-04-09 09:37:49,783 [INFO] CodeEngine:181 - oldGeneratedFile, /temp/Src/gpio.tmp_save2018-04-09 09:37:49,958 [INFO] CodeEngine:199 - Generated code: /temp/Src/gpio.tmpCommand lineDebug : prepare data for ADCCommand line testCommand lineDebug : prepare data for I2CCommand line testCommand lineDebug : prepare data for SPICommand line testCommand lineDebug : prepare data for SYSCommand line testDebug : prepare data for NVICCommand line test2018-04-09 09:37:50,266 [INFO] CodeEngine:181 - oldGeneratedFile, /temp/Src/stm32l0xx_it.c_save2018-04-09 09:37:50,371 [INFO] CodeEngine:199 - Generated code: /temp/Src/stm32l0xx_it.c2018-04-09 09:37:50,378 [INFO] CodeEngine:181 - oldGeneratedFile, /temp/Inc/stm32l0xx_it.h_save2018-04-09 09:37:50,451 [INFO] CodeEngine:199 - Generated code: /temp/Inc/stm32l0xx_it.h2018-04-09 09:37:50,474 [INFO] CodeEngine:181 - oldGeneratedFile, /temp/Src/stm32l0xx_hal_msp.c_save2018-04-09 09:37:50,624 [INFO] CodeEngine:199 - Generated code: /temp/Src/stm32l0xx_hal_msp.c2018-04-09 09:37:50,627 [INFO] CodeEngine:181 - oldGeneratedFile, /temp/Src/system.tmp_save2018-04-09 09:37:50,698 [INFO] CodeEngine:199 - Generated code: /temp/Src/system.tmp2018-04-09 09:37:50,705 [INFO] CodeEngine:181 - oldGeneratedFile, /temp/Inc/stm32l0xx_hal_conf.h_save2018-04-09 09:37:50,851 [INFO] CodeEngine:199 - Generated code: /temp/Inc/stm32l0xx_hal_conf.h2018-04-09 09:37:50,869 [INFO] CodeEngine:181 - oldGeneratedFile, /temp/Inc/main.h_save2018-04-09 09:37:51,005 [INFO] CodeEngine:199 - Generated code: /temp/Inc/main.h2018-04-09 09:37:51,009 [INFO] CodeEngine:181 - oldGeneratedFile, /temp/Src/main.c_save2018-04-09 09:37:51,129 [INFO] CodeEngine:199 - Generated code: /temp/Src/main.c2018-04-09 09:37:51,345 [INFO] ProjectBuilder:1260 - Time for Copy HAL[1] : 35mS.2018-04-09 09:37:51,359 [INFO] ProjectBuilder:1723 - Project Generator version: 2.27.02018-04-09 09:37:51,379 [INFO] ConfigFileManager:451 - The Die is : DIE4172018-04-09 09:37:52,838 [INFO] ToolchainGenerator:125 - stack trace : java.io.FileNotFoundException: /temp/custom.xml (Datei oder Verzeichnis nicht gefunden) at java.io.FileInputStream.open0(Native Method) at java.io.FileInputStream.open(FileInputStream.java:195) at java.io.FileInputStream.<init>(FileInputStream.java:138) at java.io.FileInputStream.<init>(FileInputStream.java:93) at generators.SysWbgenerator.setDebugOptions(SysWbgenerator.java:2329) at convertor.Convertor.generateSW4STM32Project(Convertor.java:1466) at convertor.Convertor.generateSw4STM32Files(Convertor.java:1311) at convertor.Convertor.generate(Convertor.java:659) at convertor.Convertor.convert(Convertor.java:559) at convertor.Convertor.updateProject(Convertor.java:412) at com.st.microxplorer.plugins.projectmanager.model.ToolchainGenerator.update(ToolchainGenerator.java:119) at com.st.microxplorer.plugins.projectmanager.engine.ProjectBuilder.createToolChainFolders(ProjectBuilder.java:1776) at com.st.microxplorer.plugins.projectmanager.engine.ProjectBuilder.createProject(ProjectBuilder.java:595) at com.st.microxplorer.plugins.projectmanager.engine.GenerateProjectThread.run(GenerateProjectThread.java:41)2018-04-09 09:37:52,839 [INFO] ToolchainGenerator:126 - [Project Generator] Problem in the update of the project
2018-04-09 09:37:52,839 [INFO] ProjectBuilder:1785 - Time for Generating toolchain IDE Files: 1484mS.2018-04-09 09:37:52,839 [ERROR] ProjectBuilder:1791 - Error in Project Generation2018-04-09 09:37:52,839 [ERROR] ProjectBuilder:611 - Error in Project GenerationWhat's wrong here?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-04-23 1:56 AM
Hi Thomas,
Could you please attach the .ioc it will be helpful for debug
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-04-23 2:14 AM
Hi, can I send it to you directly as I don't want to make this file public? Thanks, Thomas
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-04-26 1:31 AM
GHARBI.Nawres
‌ how can I send it to you via eMail?- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-04-30 4:18 AM
you can attach it here or send it by private message
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-05-02 2:10 AM
I have no issue generating with the sent ioc, did you modify your FW ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-05-08 4:29 PM
Hello,
I recently had a similar issue as you. My stack trace is below, with a change to the project name and project directory. (In case the people to be see this post)
So I ended up not tracking the project.xml file that the Cube seems to require to be able to generate the project. So if you have a similar issue as I did (I believe you do), then you can follow the following steps to fix it.
- First ensure that the Cube program is closed. Note: If the Cube program is left open, then it will still fail after step 2, the program requires to be closed.
- Delete all files from the working directory except the .ioc file.( WARNING: Ensure you have a backup of the directory before performing this step)
- Generate the project
- Go to the repo, and undo all changes (Ensure that the xml file is left alone in the project directory)
- It is okay to leave the Cube program open. Note: It is also okay to leave newly generated C/H files in the folder.
- After undoing all the changes that was done, have the Cube regenerate the project.
- Now, you should have an updated project with the updated processor configuration.
Or if you happen to still have a copy of that .xml file, just place it back to the original location.
stack trace : java.io.FileNotFoundException: C:\ProjectDir\ProjectName.xml (The system cannot find the file specified)
at java.io.FileInputStream.open0(Native Method) at java.io.FileInputStream.open(Unknown Source) at java.io.FileInputStream.<init>(Unknown Source) at java.io.FileInputStream.<init>(Unknown Source) at generators.SysWbgenerator.setDebugOptions(SysWbgenerator.java:2329) at convertor.Convertor.generateSW4STM32Project(Convertor.java:1466) at convertor.Convertor.generateSw4STM32Files(Convertor.java:1311) at convertor.Convertor.generate(Convertor.java:659) at convertor.Convertor.convert(Convertor.java:559) at convertor.Convertor.updateProject(Convertor.java:412) at com.st.microxplorer.plugins.projectmanager.model.ToolchainGenerator.update(ToolchainGenerator.java:119) at com.st.microxplorer.plugins.projectmanager.engine.ProjectBuilder.createToolChainFolders(ProjectBuilder.java:1776) at com.st.microxplorer.plugins.projectmanager.engine.ProjectBuilder.createProject(ProjectBuilder.java:595) at com.st.microxplorer.plugins.projectmanager.engine.GenerateProjectThread.run(GenerateProjectThread.java:41)- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-05-14 10:15 AM
Hello Robert M, I am having the same issue, I am trying to re-create your steps. What do you mean by step 4? Would appreciate your assistance.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-05-14 10:29 AM
could you detail the steps you did to reproduce the issue please ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2018-05-14 10:50 AM
I was using Git to keep track of all changes to the project, so I just told git to undo all changes dealing with the source code.
Hopefully this will make more sense
- First ensure that the Cube program is closed.Note:If the Cube program is left open, then it will still fail after step 2, the program requires to be closed.
- Make a copy of the project directory with the IOC file, and we will call this copy 'OldP' (WARNING:Ensure you have a backup of the directory before performing this step so you will not lose anything important if this doesn't help)
- Delete all the files in the original project directory except for the IOC file.
- Open the IOC file and generate the project
- Now delete all the files expect for the IOC file and the xml file.
- Copy all the files from the 'OldP' except for the IOC file to your project directory.
- Open Cube and now you should be able to generate the project again. (Since we now have that missing xml file that Cube seems to need to be able to generate the project a updated project in an existing project directory)
Let me know if this helps.
