@satchmo
In my opinion, create your program and run it at what you consider the ideal fps that your program should run. Maybe it's 20, maybe it's 100. Once you have decided what your program should run at, and have tested it and see that it is as beautiful as you hoped, that will be your cap or your ideal FPS. You will still use a timer, but use it to help manage any machines that may run slower, it's not necessary for the faster ones. Assumingly, the faster ones will already be able to run your program at the rate you consider ideal and therefore should look and run the way you hope; so there wouldn't be any necessary use of a timed flow modification in those situations beyond setting the sync rate to your ideal.
There's a couple of ways to approach it. You can use TIMER() to check if a certain number of ms have passed and then force a jump to your subroutines and a sync. This can be a bit tricky. This method works better if you are trying to slow down a faster processing machine.
You can also figure out a percentage of ideal fps versus the actual fps the machine is running at
ideal/actual = some percent
You can take that percentage and multiply it times your movement increments. So if your ideal fps was 60 and the actual rate the machine was running at was 30, you would have a value of 2 to multiply times your movement increments.
So, in general you can achieve pretty good results if you use a combination of the two methods. Keep track of a timer and let's say, every 16 ms (about 60 fps) in the main loop you jump to your movement routines. Before the jump you've calculated the percentage of movement increase to apply to your objects if the fps is lower than the ideal. If the FPS is higher (though it shouldn't be because you set your program to a capped rate - but if you decided to let it run with the sync rate at 0), you don't want to make any adjustments to the movement by applying a percentage because your timing would be taken care of by the 16 ms check, keeping the program running at a consistant fps.
If the computer that is running your program is just too slow, there's not a lot you're going to be able to do and even though you may get the program to do stuff at the right time, the stuff in between the right time can be choppy.
You can figure out the ms you want to run your program at by dividing 1000 by your ideal frame rate. For example, 60 FPS comes out to
1000/60 = 16.7ms
if timer()-tim > 16
do something
tim=timer()
endif
Enjoy your day.