CubeMXImporter
CubeMXImporter copied to clipboard
New CMSIS Directory Structure
According to the book (and the script), there are changes to the directory structure that is not compatible anymore. The book and the script used the following directory structure:
Project Root
|_ Inc
|_ Src
|_ Drivers
|_ CMSIS
|_ Include
|_ Device
|_ STM32XX_HAL_Driver
The new directory structure for CubeMX is as follows:
Project Root
|_ startup
|_ Core
|_ Inc
|_ Src
|_ Drivers
|_ CMSIS
|_ Device
|_ ST
|_ STM32xxF4xx
|_ Source
|_ Templates
|_ Include
|_ Include
|_ STM32xx_HAL_Driver
|_ Src
|_ Inc
|_ Legacy
I've seen this structure with Nucleo F411RE. I'm not sure if it's a universal directory structure change, or is only applicable for this board. If it's a universal change, I modified the script to make sure it runs properly.
If the directory structure has changed universally, is it okay for me to submit a pull request for this?
I am using stmCubeMX v5.0.1 --
The new structure you are talking about is generated when you select advance application structure while generating the code.
Indicated below -
When you generate the code with basic application structure selected then you will get directory structure indicated in script or book.
@Rahulelectobuddy , that makes sense. I've used both CubeMx 5 and STM32CubeIDE and in both of them, the Application Structure is greyed out (like you have on the screenshot) and I'm not sure how to turn it on. Can you help? Thanks.
@tiazahmd, you can change application structure to advance or basic without changing any setting (default). Try creating a new project and then changing structure.
For an already existing project, if the option to change application structure is greyed out simply "Save As..." under the same project name/directory (effectively overwriting the project with itself). The option to change application structure will then become available again.