cancel
Showing results for 
Search instead for 
Did you mean: 

STM32CubeMX code re-generation for SW4STM32 creates duplicated file links in .project

meterman
Associate
Posted on July 26, 2015 at 23:01

When code is regenerated from STM32cubeMX (4.8.0 & 4.9.0) for SW4STM32 toolchain, eclipse file link entries in .project become duplicated at the end of the file instead of replaced or updated. This does not yet cause a problem since eclipse appears to handle it by giving priority to the latter entries but if files have been removed in later configurations, the links in the project will still exists and be compiled. The workaround is to be sure to use version control, look at the changes to the link entries and manuallydelete the old file entries in the generated .project files to see what the differences are.

I have tried this on 2 different processors, the STM32F401RDTx and also with the default configuration for the STM32F429I-DISCO board.

Reproduction:

Start STM32CubeMX app (4.8.0 or 4.9.0)

New Project

Choose the STM32F429I-DISCO

Choose project->Generate Code

ProjectTab - project name is test

ProjectTab - ToolChain / IDE is SW4STM32

Code Generator Tab - Select Copy all used libraries into project folder

Code Generator Tab - Select Generate peripheral initialization as a pair of '.c/.h' files per IP

Code Generator Tab - Select Keep user code when regenerating

Code Generator Tab - Select Delete previously generated files when not re-generated

Choose OK. Close STM32CubeMX. 

Observe and backup the file  /test/test/SW4STM32/test Configuration/.project

Open STM32CubeMX app.

Open the test.ioc project

Choose project->generate code.

Observe additions to .project file.

Windows 7 x64.

#stm32cubemx-eclipse-sw4stm32
3 REPLIES 3
stm32cube-t
Senior III
Posted on August 27, 2015 at 09:13

Dear user,

This is a known issue that will be fixed in the release 4.10 coming out early september.

Best regards
SPLabs
Associate II
Posted on October 24, 2015 at 01:28

It is still a problem.

I'm using STM32F7 discovery, CubeMX version 4.11

I went crazy after upgrade from STM32Cube_FW_F7_V1.1.0 to 1.2.0 it was adding another copy of every single file. I've solved generating the project from scratch and manually adding again my files.

It worked for few times, now when regenerating it keeps adding 2 copies of stm32f7xx_hal_msp.c

It is a nice piece of software but the time you save in configuring the hardware you spend in making it work properly... Please fix it!!!

stm32cube-t
Senior III
Posted on November 02, 2015 at 11:22

Dear user,

The ioc attached is for F7 discovery and used with CubeMX 4.

Can you please try it. We regenerated the code several times and did not witness any duplication.

Thank you

________________

Attachments :

TEST.ioc : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006HzFc&d=%2Fa%2F0X0000000bLr%2FTjgaWeiO28_XY5nhfSUje8NhighsW190ZhDABywB3Os&asPdf=false