cancel
Showing results for 
Search instead for 
Did you mean: 

stm32f3 PWM Input latency

j-fischer-gundlach
Associate II
Posted on August 10, 2013 at 09:28

Hello together,

i´m just asking in case someone had the same issue and knows the answer - of course i don´t want u to read the manuals for me...

So, i´m using the PWM input feature on Timer2 and in general it works. I just have a big latency from about allmost a second. I started from the peripeheral example from the FW library. I don´t use the dividing calculations in the ISR and uncommented them. I only do a substraction, so there are no time intensive calculations left.

maybe someone knows the problem?

greetings,

Justus

Backround:

i take a serial incoming pulse signal wich contains 7 channels for Servos. The signal´s end is marked by a long LOW time wich i use to reset the channelCounter. I simply shift one of the channelValues directly into the compare register of timer1 wich is doing a hardware PWM.

There´s only the Input ISR active.
1 REPLY 1
Posted on August 12, 2013 at 00:40

I guess one potential problem with PWM input capture is the desire to see multiple edges, or it's resetting of the counter. A 1 second latency seems rather high, does this correlate with the presence of other signals, or the periodicity of the counter update? What if you use other input capture modes to just snap-shot the free running timer rather than the PWM mode resetting it?

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..