Skip to main content
jd kim
Associate II
July 27, 2019
Question

GPIO interrupt keep systick interrupt from occuring?

  • July 27, 2019
  • 4 replies
  • 1243 views

Hi, Im senior engineer using stm32, maybe, not newbee.

I know that Higher interrupt priority can occur when mcu still process lower interrupt.

Higher interrupt , i mean, lower priority value in nvic register.

but just now, I found gpio interrupt can disturb systick interrupt, which is obviously higher then gpio.

I know that there is no pull up/down resister, so even simple interrupt can occur numerous times with my fingers. but It can disturb systick interrupt from occuring? theoretically I can't understand. what's going on?

This topic has been closed for replies.

4 replies

Tesla DeLorean
Guru
July 27, 2019

Interrupts can also have different preemption levels.

You should be able to use an internal pull up/down resistor.

Failure to clear the interrupt sources will also result in an interrupt storm, where no lower priority execution will occur.​

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
jd kim
jd kimAuthor
Associate II
July 27, 2019

that's not the point. point is why systick interrupt not occur.

I know internal pullup/down can be solution of this by regressing interrupt

why gpio interrupt occur infinitely , while systick is not, even it has higher priority

Tesla DeLorean
Guru
July 27, 2019

>>that's not the point. point is why systick interrupt not occur.

Yeah, and you're not reading the top line of the response properly.

Because the CM3/4 has an NVIC which considers priority AND preemption level. If you haven't set up the NVIC correctly it is going to block in your interrupt code and not leave to service others. Check the grouping setting you have selected that allocates bits to each request.

If you are using SysTick for timing loops or timeouts in interrupt/callback context you'd do better using a free running TIM to measure time.

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
jd kim
jd kimAuthor
Associate II
July 27, 2019

Oh , I'm sorry. I'll check. I didn't know preemption and interrupt are different.

thank you

​

BTW, I'm using Systick counting value made by cubemx code. I thought I can make timeout code but It's not proper to use callback or interrupt because of priority.

​

well, It's not a case you said obviously. isn't it proper that way i use by? is there any dependent component about systick clocks comparing with other timers?

​

​