Hi wysota, I need to have my application perform some specific activity at a frequent interval ( < 100 ms). I need this activity to have high precision. I was wondering if something like QTimer might have some amount of slop in it if it is at all based on an event loop. I will likely be using this on a thread that does not have an event loop, and hence I can not hook up to a QTimer timeout() signal. According to the Qt documentation, QTimer will not timeout before the specified time, but can arrive very late.
QTimer does not seem to be a good candidate. I recall getting higher fidellity timing under Linux using the timer_create() API and putting into place a SIGEV_SIGNAL
handler.
However, Qt does not have direct support for Linux signals proper. A solution I have read on this subject involved having the signal handler inform the Qt application proper via a socket.
What do you recommend for a thread that may not be running and event loop to achieve high precision timing. I would like the solution to be cross platform if possible.
Bookmarks