I’m using CLI and photon_043. I need to write a custom IRQ handler for TIM3 (and other timers in the future). I see TIM3_irq() in stm32f2xx/core_hal_stm32f2xx.c, and how tone_hal.c uses HAL_TIM3_Handler. I’m trying to do the same thing from my code and I get:
How can I get the ISR to call my handler function?
I’d prefer to replace the HAL’s IRQ handlers with my own custom function for efficiency, would it be possible to declare the IRQ handler functions as weak so a sketch or library can override them if needed?
@Pixelmatix, I had the same challenge with the SparkIntervalTimer library. In the upcoming firmware release (IDE, CLI, DEV) there is an API call to hook into system ISR jump table. If you compile locally, I believe the “latest” branch has the updates. The new function is attachSystemInterrupt().
can you post your code, I’m trying use the attachsysteminterrupt function also. Can you post the code you used? Do we have to use the NVIC or that configured under attachsysteminterrupt, I couldn’t find anything about that. Thanks!