This can be achieved in two ways:
- Spawn a thread that runs your logic. Be aware that it can be more difficult to work with than it looks.
- Use one loop, but only perform tasks at the wanted intervals.
I found this article helpful, although it is focused around game loops, which may not be what you are looking for:
http://www.koonsolo.com/news/dewitters-gameloop/ (http://www.koonsolo.com/news/dewitters-gameloop/)
Sorry for not responding. Thank you.
In the end I went for this approach
if(DisplayClock.GetElapsedTime().asMilliseconds() >= 2.85714)
{
draw stuff...
}
(2.85714 millis means about 35 frames per second)