Hi, I am using Keil uVision V5.37.0.0. free version with uC STM32G041C8T6 and ULINK-ME programmer/debugger. Flash memory starts at 0x08000_00000. I'm developing my own application setup without using CubeMX/CMSIS/HAL except only a few basic header files and the startup file. If I declare an interupt handler like TIM2_IRQHandler() then when entering a breakpoint at the start of the main() function and view the Memory1 window showing from address 0x0800_0040 (NVIC interrupts) then all listed 4-byte pointers point to the same addres. Also does address 0x8000_007C which shoud hold a pointer to the TIM2_IRQHandler() interrupt handler.However if i use the older Keil uVision V5.25.3.0 with the STM32F103ZE uC then when stopping at main() the NVIC interrupts jump table is filled with different pointers.How can I make the NVIC interrupt table to be automatically filled? I tried the .ini file and the scatter file but something tells me it should be handled in the startup file?
Hi, let me asnwer myself. After stumbling many hours trying everything I found the (classic) solution for this (classic) problem. The older working application version is developed using programming language C as my new application is developed using programming language C++. I had to enclose my C++ function prototypes between [#ifdef __cplusplus extern "C" { #endif] and [#ifdef __cplusplus} #endif] ofcourse without the square brackets for clarity. All works fine now! Thanks for listening anyway.
Glad to hear it! Thank you for coming back and sharing your solution with us :)