SPIM conflicts with Timer

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Hi, The interrupt in my project which is originally used to enable the timer is conflicting with the SPIM. The issue now with my project is that when I quoted the "CyGlobalIntEnable" and the "TimerISR_StartEx(InterruptHandler1)", only the SPIM has out put, and when these two are not quoted, only the timer has out put. Here is a zip file and some screenshot of my project, Just wondering if anyone would help me solve this issue. thanks! Capture 2.PNGCapture1.PNGCapture3.PNG

0 Likes
1 Solution

"enable the interrupt to timer alone instead of using the global interrupt enabler?"

This is definitively not the cause for your issue. The global interrupt enable is needed to fire any interrupt.

More:

  • Set the timer interrupt priority to the lowest (7) value.
  • Reduce the timer clock, so that you get 500µs period. When that works (and it should) you may increase the clock frequency.
  • Use the Timer_1_ReadStatusRegister() API and not the access to the register itself, this could get optimized-out.

Bob

View solution in original post

12 Replies