EXTI interrupt latency on STM32

General discussions and questions abound development of code with MicroPython that is not hardware specific.
Target audience: MicroPython Users.
Post Reply
PeterG
Posts: 7
Joined: Sun Oct 28, 2018 7:10 pm

EXTI interrupt latency on STM32

Post by PeterG » Thu Dec 06, 2018 7:00 pm

Hello,

Can anyone give me an idea of the interrupt latency on a STM32L4xx running at 80 MHz with micropython? I am having to measure the number of pulses of 11 at once every 100 msec, where the pulse rates range from 10 KHz to 90 KHz. Is there a better way to do this?

I though of measuring the pulse period using input capture but the period is not constant.

Any suggestions greatly appreciated.

PeterG

User avatar
dhylands
Posts: 3821
Joined: Mon Jan 06, 2014 6:08 pm
Location: Peachland, BC, Canada
Contact:

Re: EXTI interrupt latency on STM32

Post by dhylands » Thu Dec 06, 2018 8:52 pm

I'm not sure why the period would need to be constant for input capture? input capture is just a way for the timer to record when something happens and the interrupt latency becomes less of an issue, because the timer value is captured by the event.

I have no idea what the latency would be without measuring it.

I did some instrumentation of the timer irq here (on a pyboard running at 168 MHz):
viewtopic.php?f=2&t=829&start=10#p4781

That had an upper bound of about 200 kHz, so trying to do 90 kHz on an 80 MHz CPU might be pushing things, but it would depend on how frequently that happens.

Post Reply