cancel
Showing results for 
Search instead for 
Did you mean: 

Migrating code between STM32F4 MCUs using STM32CubeMX: exporting vs importing approach - what is preferred and when ?

eBirdman
Senior
Posted on July 08, 2018 at 03:39

Hello, there are two approaches outlined in the UM1718 user manual using STM32CubeMX to migrate a project to another MCU of the same family:

1. CH. 7.9  Importing a project to another MCU in the CubeMX by creating a new project with targeted MCU and then modify / tune up all the components before generating a project and then manually update all user code spread over the project files.

2. Ch. 11 By exporting: Open the available project in CubeMX, change it to a compatible MCU from the list, make necessary changes and then generate update to the project.

The end result of both is the same yet the sequence is different.  Board/chip related generated code in the project is changed the same way in both approaches and user code should be changed accordingly if pins / clocks have been changed after the project has been generated.

What approach is recommended for what scenarios?  Consider the migration of the Cube HAL example code and another more involved demo example. What would be recommended and why?

#export #porting #migration #import #stm32cubemx
0 REPLIES 0