79653193

Date: 2025-06-04 16:57:41
Score: 0.5
Natty:
Report link

Ok, so the reason is the name mangling of C++.

As my interrupt handlers use C++, I needed to rename the stm32wlxx_it.c (generated by Stm32CubeMx) file to stm32wlxx_it.cpp. This invokes the C++ compiler, but also mangles the names of the functions. Doing nm stm32wlxx_it.orevealed that the actual name of function in the object file is _Z17USART1_IRQHandlerv.

When you declare the function in stm32wlxx_it.h it is no longer mangled : if you create the project as C++ project in STM32CubeMx, it will automatically add extern "C" around the declarations.

Reasons:
  • Blacklisted phrase (0.5): I need
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (0.5):
Posted by: Strooom