I've have a uVision project which is built on STM32F030C8 microcontroller. I'm using STM32F0xx standard peripheral library in my application. Now I need to migrate to a higher version of the controller, as my application demands more peripherals. So I now have hands on the STM32F071C8T6.

Now my question is: What changes do I need to make in my current uVision project files, so that the project can be safely migrated to support the STM32F071 uController?

Things done so far...

  1. Updated the package installer for STM32F071C8T6 device.
  2. Changed the device in "Options for Target" from STM32F030C8 to STM32F071C8T6.

What additional changes should I make?

The standard peripheral library will remain the same in my case right? ie STM32F0xx standard peripheral library.

Also, do I need to make changes in the startup files too?

Please tell me what files need to be changed, so that I can migrate my project logically without any conflicts.


1 Answer 1


These are the things that were required to migrate existing STM Keil project to another controller of the same family or of a different family.

Firstly, the options for target is of use when a new project is being created in Keil. Changing a particular controller in "Options for Target" does no good in an existing project.

Basically one needs to change the startup file which is unique for a controller.

Then if you're using any peripheral library files to communicate with the controller, then you need to make sure that the library file supports that particular controller.

In my case, there was no code/ defines for STM32F071. So i created a new project in STM's CubeMx software and generated the startup and the appropriate peripheral library files and copied that files to my existing library file with a macro #if defined (STM32F071).

Also after some searching i came across STM32F0's library file which had all the setup codes for different F0 microcontrollers; all embedded into one header file, separated by #ifdefs.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.