Device Startup Files

For STM32C5 series the CMSIS Device Startup files are provided in the DFP pack

  • Source/startup_stm32c5nnxx.h : device startup file

Note

Starting from CMSIS-Core 5.6.0 , Arm switched from assembly to C language for the CMSIS Device Startup files, to provide:

Improved readability : easier to understand and modify.

Better maintainability : easier to debug and extend, no more assembly language expertise required.

Enhanced portability : easier to adapt to different toolchains and architectures.

The startup file defines device exceptions and interrupts, and provides their initial (weak) handler functions.

Specifically, following functionalities are provided:

  • The reset handler Reset_Handler which is executed upon CPU reset and typically calls the SystemInit() function. After the system init the control is transferred to the C/C++ run-time library which performs initialization and calls the main function in the user code.

  • The setup values for the Main Stack Pointer (MSP).

  • Exception vectors of the Cortex-M Processor with weak functions that implement default routines.

  • Interrupt vectors that are device specific with weak functions that implement default routines.

  • Default_IRQHandler_Hook function that can be implemented by the user to customize the default behavior of all unimplemented interrupts in a single place at application level.