I have a dispatcher timer which has to act like a heartbeat every 500ms and write on a register on an anybus. I have set it with maximal priority:
m_HeartBeatTimer = new DispatcherTimer(DispatcherPriority.Render);
the problem is that when program is running sometimes the interval can enormously get longer up to 19 seconds:
[20/06/2017 17:00:01.182] HeartBeat 1 79
[20/06/2017 17:00:20.669] HeartBeat 0 80
of course there are other timers and other operations but shouldn't the timer be insensitive of those ones?
Is there any way to make it respect the correct timing? thank you