cancel
Showing results for 
Search instead for 
Did you mean: 

Re-arrange the generated code files in STM32CUBEIDE

Mathan Raja
Associate III

Hi,

I want to rearrange the generated files of peripherals and protocols(like usart.c, tim.c, adc.c) from the core folder to the driver's folder and rename the core folder to the Application.

Is it possible in stm32cubeIDE?

Thanks

Mathan

3 REPLIES 3
Peter BENSCH
ST Employee

Well, the STM32CubeIDE is based on Eclipse, so you have quite a lot of freedom.

However, you have to bear in mind that a whole range of tools are gathered under its umbrella, which have their own idea of structure. When you create a project with the STM32CubeIDE, e.g. the STM32CubeMX tool creates all the C files, H files, etc.

If you now reorganise everything, STM32CubeMX will not find its files again if you change the .ioc and then regenerate it, and will create the entire project anew - whereby no source text that you have inserted will be taken over. You may then be able to find your (first) files again, but it is guaranteed not to be much fun to insert the changes into the first file variants.

Is there a specific reason to change the file structure?

Regards

/Peter

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
Mathan Raja
Associate III

Well, there is no specific reason. Thanks

Peter BENSCH
ST Employee

OK, if the problem is solved, please mark this thread as answered by selecting Accept as Solution, as also explained here. This will help other users find that answer faster.

Regards
/Peter

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.