cancel
Showing results for 
Search instead for 
Did you mean: 

Is STM32CubeIDE compatible with SPL Library?

WAi.11
Associate II

Hi Every I am new to this platform.

my question is as the topic stated above. My situation is that I have my completed project on Keil Vision 5 which works well, but for some reason I need to migrate the whole firmware to STM32CubeIDE.

I googled about the problem and there is no much information about it, while the only seem-valid message i got is: SPL seems not to be supported by STM32CubeIDE.

is rewriting all libraries the only way for me to complete the migration? If so, is there any hints or shortcut for me to do so? Or I really have to rewrite the whole thing?

P.S. I tried moving the files to STM32CubeIDE from Keil and the following picture shows my result

0693W000001ceJmQAI.png

And I figured out that the way to configure GPIO is kind of different that it not quite easy to directly modify it.

I am using STM32F103RCT6

See if there is someone who can answer me so that I dont have to further waste my time to figure out how to do the migration, and rewrite the whole thing instead.

7 REPLIES 7

Would need to be a pretty compelling reason, SPL isn't compatible with the new HAL methodology. The SPL is pretty robust so doesn't need much support/maintenance.

Don't they have some SPL to HAL LL converter? https://www.st.com/en/development-tools/spl2ll-converter.html

Pretty low confidence in such things, if you must do it use this as an opportunity to refactor.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
WAi.11
Associate II

Yea I saw the SPL to LL converter but there is no converter for HAL.

Does it mean that there is no method other than rewriting the whole firmware, if I have to migrate the firmware from Keil to STM32CubeIDE?

And is STM32CubeIDE literally not compatible with SPL?

Thanks for your advice anyway!

Yea I saw the SPL to LL converter but there is no converter for HAL.

Does it mean that there is no method other than rewriting the whole firmware, if I have to migrate the firmware from Keil to STM32CubeIDE?

And is STM32CubeIDE literally not compatible with SPL?

Thanks for your advice anyway

Is there an option to use no code generation in CubeIDE?

If yes, then your existing code is *compatible* - simply use it as any piece of code independent on Cube/HAL/LL. Treat SPL as your own code. You'll need to migrate things which are toolchain dependent, though, i.e. use the gcc startup/linkerfile instead of Keil's.

I don't use CubeIDE.

JW

TDK
Guru

STM32CubeIDE can compile whatever code you want. It's just an IDE with some fancy features. The IDE part doesn't require you to use HAL or LL or SPL or anything. It's not going to be as easy to set up, but you can do it.

If you feel a post has answered your question, please click "Accept as Solution".
berendi
Principal

The C compiler should be compatible save for a few quirks, the assembler is not.

Create a new STM32 project, select your MCU, and choose empty project at the final dialog of the project wizard. A handful of C sources files will be created, move them out of the way. Keep the startup*.s and STM32*_FLASH.ld files.

Then you can drop your existing C source files (*.c and *.h only) into the project directory. Right-click on the project root, select Refresh then Index - Rebuild. Set the include paths in the Project - Properties - C/C++ Build - Settings - [ All configurations ] - Tool settings - MCU GCC Compiler - Include paths tab.

If there are still problems, look for compiler-specific constructs in your code, and replace them with their gcc equivalents.

Thanks for the advice

I am kind of a beginner and have never heard of gcc. I will give it a shot definitely.