cancel
Showing results for 
Search instead for 
Did you mean: 

CubeMX project generation problem

redecker
Associate II
Posted on December 01, 2014 at 18:18

I want to generate TrueSTUDIO projects with CubeMX (4.5.0), because that project format fits my needs (arm-gcc, suitable startup code and linker script). However, I get an error message at the end of the code generation process:

''The Code is successfully generated under <PathToMyProject> but TrueSTUDIO 4.3.1project generation have a problem.''

The generated code includes all headers and source files as expected, but no linker script and no TrueSTUDIO project file.

What can be the reason for this error?
This discussion is locked. Please start a new topic to ask your question.
3 REPLIES 3
redecker
Associate II
Posted on December 08, 2014 at 10:05

After looking at the output when starting from command line, the last exception pretty clearly points out what's wrong:

java.net.MalformedURLException: no protocol: /home/username/builds/STM32CubeMxInstall/db/plugins/projectmanager\devices\stm32boards.db

    at java.net.URL.<init>(URL.java:586)

    at java.net.URL.<init>(URL.java:483)

    at java.net.URL.<init>(URL.java:432)

    at com.sun.org.apache.xerces.internal.impl.XMLEntityManager.setupCurrentEntity(XMLEntityManager.java:619)

    at com.sun.org.apache.xerces.internal.impl.XMLVersionDetector.determineDocVersion(XMLVersionDetector.java:189)

    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:812)

    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:777)

    at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)

    at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:181)

    at stm32Families.Families.getStartupFile(Families.java:94)

    at convertor.Convertor.getStartUp(Convertor.java:156)

    at com.st.microxplorer.plugins.projectmanager.model.ToolchainGenerator.getStartUp(ToolchainGenerator.java:99)

    at com.st.microxplorer.plugins.projectmanager.model.ConfigFileManager.writeUsedFiles(ConfigFileManager.java:497)

    at com.st.microxplorer.plugins.projectmanager.engine.ProjectBuilder.createProject(ProjectBuilder.java:359)

    at com.st.microxplorer.plugins.projectmanager.engine.GenerateProjectThread.run(GenerateProjectThread.java:36)

So CubeMX is trying to access a path with backslashes:

<InstallationDirectory>/db/plugins/projectmanager\devices\stm32boards.db

which doesn't work on the virtual windows machine I'm using it on. It also doesn't work on linux (it's a java application after all so I just tried it on ubuntu 14.04. It runs, but can't generate the project)

stm32cube-t
Senior III
Posted on December 11, 2014 at 16:05

Please use the following workaround: in TrueStudio, open the ''Properties'' interface and verify the compilation settings, then press ''Apply''.

Best regards

redecker
Associate II
Posted on December 11, 2014 at 17:39

Do I need to have TrueStudio installed for CubeMX to work correctly? As I understand it, your reply implies that I would have to load something in TrueStudio before I can apply any compilation settings.

In fact, I don't have or use any of the officially supported development environments. I select TrueStudio output in order to have a working set of source and header files for use with arm-gcc, which is (afaik) the toolchain behind TrueStudio.

The files that *are* generated by CubeMX before the error message is emitted include all necessary files, but the linker script is missing. The TrueStudio project file is missing as well, but I don't need it.