Using a Portenta H7 hardware timer

Hello everyone,

Has anyone had any luck with using a hardware timer from the STM32 on the Portenta Board?

Correct me if I am wrong, but I believe the Arduino "timer" library only has support for their own on-board MCU (ex. ATmega328) for their other line(s) of Arduino products via setting register values. And, the Mbed OS software layer seems to only support 'soft' timers. Therefore, I am working on using the STM32 HAL drivers instead (getting closer to the hardware :slight_smile: )...

I've been able to include the header for the STM32 HAL and ran a basic "blinky" program using these drivers. Furthermore, I am sure I will have more control over the timer peripheral using ST's software stack so I guess this is the best way to have a timer going for this board. However, given that the Arduino library is a lot less complex (and probably the Mbed layer as well), I am wondering if anyone else has gotten a timer going with either of these less complex tools or if there is something I haven't heard of that is a much better method.

Also, quick note, I tried to use the STM32Arduino "TimerInterrupt" library but it looks like I got the opposite situation... (Supports ST MCUs w/o the Arduino Core).

Any thoughts or pointers (*no pun intended) would be helpful to me!

Meanwhile, I will go ahead and set-up the TIM3 with ST's HAL....

Thank you!

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.