2023-02-01 09:32 AM
2023-02-01 10:24 AM
I've done the opposite...
Maybe first make a skeleton project with CubeMX which generates the IAR EWARM project file, possibly with the right target STM32 and package, and cloctree etc... depending on how much you need.
Then generate the code . Open IAR and check the project compile.
Add your source files in the skeleton project folders, then on IAR, add them.
Remember to select the target, the compile options, the compiler search directories and the compiler default passing named arguments. These are the things not to forget.
Also make sure there are no #pragma compiler specific. Think also memory mapping, stack size, etc...
If things are not too complex, you'll get a build with few errors and warnings to cleanup.
Mileage varies, depending on the project complexities...
2023-02-01 10:24 AM
I've done the opposite...
Maybe first make a skeleton project with CubeMX which generates the IAR EWARM project file, possibly with the right target STM32 and package, and cloctree etc... depending on how much you need.
Then generate the code . Open IAR and check the project compile.
Add your source files in the skeleton project folders, then on IAR, add them.
Remember to select the target, the compile options, the compiler search directories and the compiler default passing named arguments. These are the things not to forget.
Also make sure there are no #pragma compiler specific. Think also memory mapping, stack size, etc...
If things are not too complex, you'll get a build with few errors and warnings to cleanup.
Mileage varies, depending on the project complexities...