cancel
Showing results for 
Search instead for 
Did you mean: 

Taking microsecond timer without interrupt

oli
Associate II
Posted on January 08, 2015 at 13:29

Hello

I'm looking for a solution to get the time between to input signals in microsecond resolution.

But I do not want to use an interrupt counting up all microseconds.

Is there a convenient solution / method?

#stm32f4
2 REPLIES 2
AvaTar
Lead
Posted on January 08, 2015 at 13:59

Busy-polling the signal pin, and on change, fetching the counter values from a properly configured timer.

This solution will eat up all available MCU cycles while running (which is usually unacceptable on real-life systems).

Posted on January 08, 2015 at 14:56

[DEAD LINK /public/STe2ecommunities/mcu/Lists/cortex_mx_stm32/Flat.aspx?RootFolder=/public/STe2ecommunities/mcu/Lists/cortex_mx_stm32/Taking%20time%20in%20microsecond%20without%20using%20interrupts&FolderCTID=0x01200200770978C69A1141439FE559EB459D7580009C4E14902C3CDE46A77F0FFD06506F5B&TopicsView=https://my.st.com/public/STe2ecommunities/mcu/Lists/cortex_mx_stm32/AllItems.aspx&currentviews=9]cross-post

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