1 2 Previous Next 26 Replies Latest reply on Jul 15, 2020 7:18 PM by AjBa_3976296

    SysTimers component

              Often I need to time events or execute periodic code from my main loop, but don't want to use additional hardware or use blocking code like CyDelay(). The Cortex M0 and M3 in the PSoC 4 and PSoC 5LP have a nice little built in timer called SysTick. You can set the interrupt period with a wide range of values and it is very useful as a general purpose timer. The SysTimers component attached this post makes use of this timer to run up to 16 parallel non-blocking timers. It is simple to use and can be configured to have a very small (1 line) ISR so not to take up too many CPU cycles. I have attached a workspace that includes the library, and examples for both PSoC4 and PSoC 5LP. Enjoy, Mark   
        1 2 Previous Next