cancel
Showing results for 
Search instead for 
Did you mean: 

STM32CubeIDE: Different File Structure

KMew
Senior III

I am using the STM32H7B3I-EVAL, which includes a touch screen that uses the TouchGFX application. I am trying to do its tutorials, which includes modifying the code in the STM32CubeIDE. However, when I do, the file structure is different in my computer's file explorer compared to what is shown in the STM32CubeIDE project explorer.

For example, the TouchGFX folder in my File Explorer is not present in the IDE project explorer.

What causes this and what can be done to fix it?

0693W00000UnLQNQA3.png 

0693W00000UnLQhQAN.png

21 REPLIES 21

Hello Romain,

I'm sorry, but I'm still confused.

I am trying to figure out why my folder structure in the CubeIDE's project explorer does not match the folder structure I have in my file explorer. Every tutorial I've seen online for using TouchGFX or any other sample code has the two matching, but mine does not. When I look through the list, I can't find multiple different files too. For example, in that project explorer picture I sent, there are no header files in any of the folders. So clearly something is wrong and I don't understand what.

RomainR.
ST Employee

@KMew (Community Member)

As your whole project is folded, it is very difficult to answer and help you. 

Sorry I won't be able to help you more about what's happening on your computer !

I share with you a CubeIDE project created with TouchGFX where I aligned the IDE (on the left) view and my explorer view (on the right).

For me both structure are identical and all folder, source file and header are present.

And I do not understand why you do not have the same ?

Good luck

Best regards

Romain,

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.

Hello Romain,

I unfolded the folder in my previous response to do a comparison. I've copy and pasted how mine looks when I create a TouchGFX instance and hit "Generate Code."

This is how it looks, which you can clearly see the differences.

I am confused as to why yours constructs properly and mine does not. Could this be a workspace setting issue? I need to know a solution so I can actually follow tutorials and start learning STM32 programming.

I apologize if this is seeming difficult, but I am at a complete loss.

0693W00000UnWLsQAN.png

RomainR.
ST Employee

Here my last TouchGFX project generation usin last version 4.20.0 (the previous one was generated with TouchGXF 4.15)

I think the folder structure are different between IDE and file explorer because new version of TouchGFX generate a project that is compatible with 3 different IDE (IAR EWARM or ARM-KEIL and CubeIDE GCC)

This is not an issue, it's just a different view of the projectinside STM32CubeIDE folder.

0693W00000UnWUaQAN.png 

Do not be confused you don't have to worry about that, it doesn't change anything on your code.

Try to compile it and take a look into STM32CubeIDE folder it match with CubeIDE file structure.

0693W00000UnWV9QAN.png 

Best regards

Romain,

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.

Hello Romain,

I can compile it without issue. It shows what I intend to show. Yet when I look at the CubeIDE project explorer vs the file explorer, it's still different.

Hello Romain,

I was looking through the TouchGFX Support documentation and I found the following section:

https://support.touchgfx.com/4.20/docs/development/ui-development/working-with-touchgfx/using-ides-with-touchgfx

It does explicitly state:

"Note that not all project files are present in your project at the same time. The tool chain selected in STM32CubeMX is the one that will be generated, by default STM32CubeIDE is selected."

Could this be related at all?

Hello Romain,

I apologize, but I have found more information.

The level I'm looking at (ADC_Display) does not match what's in the project explorer. I went into one of the subfolders (ADC_Display/STM32CubeIDE) and I found a matching file directory! Now, it still poses an issue because this project folder is missing things like the header files and such. Does this information help at all? The .project and .cproject should be in the ADC_Display folder, not ADC_Display/STM32CubeIDE folder, correct?

0693W00000UnWqWQAV.png 

0693W00000UnWqbQAF.png 

RomainR.
ST Employee

Hello @KMew (Community Member)

Here below my answer to your previous questions:

"The level I'm looking at (ADC_Display) does not match what's in the project explorer. "

Again, that's is normal because STM32CubeIDE as a configuration view of it's root folder that is STM32CubeIDE\

"I went into one of the subfolders (ADC_Display/STM32CubeIDE) and I found a matching file directory!" 

Yes and that is what I already explain to you yesterday and just above.

"Now, it still poses an issue because this project folder is missing things like the header files and such. Does this information help at all? The .project and .cproject should be in the ADC_Display folder, not ADC_Display/STM32CubeIDE folder, correct?"

No your project generated has no issue. All sources and header file are located on folder above \STM32CubeIDE, like ..\Core or ..\TouchGFX.

Yes these informations are mandatory and STM32CubeIDE is able to found them because the path of the project are correctly configured (see following picture)

These folder path configuration are also into the .cproject file.

0693W00000UnZNwQAN.pngI confim again there is no issue in your generated project.

Best regards

Romain

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.

Hello Romain,

I apologize for the confusion that I have caused. Yes, I acknowledge that the code works. I was simply trying to find a way to have it show the entire folder generated (including the level above the STM32Cube folder) for ease of navigation and ease of adding a new .c or .h files.

If it's possible to show them in the Project Explorer, then I would be happy.

I do acknowledge that my original question has been answered.

RomainR.
ST Employee

Of course you can add the .c and .h sources you are developping, that's the purpose and it's designed for that. 

You can create a new directory, add files, and simply you can drag and drop it from the explorer to the CubeIDE project it will appears and add its path in the configuration I showed you above.

Don't worry, the important thing is that you can move forward in your project.

Good luck to you.

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.