I am a begineer to C Programming.
Is there a command to give processor independent accurate timing.
Let me explain.
I want to write the following program:
1) Print x to the screen
2) Wait for 5secs
3) Print x to the screen
4) Jump to 1)
I want the program to wait 5secs between printing "x" no matter what PC processor I use.
Hence, I can not have:
1 Printf("x");
2 If (x=0;x<200000;x++);
3 Go to 1
I must have something like:
1 Printf("x");
2) Get time now;
3) Let timstart=Get time now
4) Let timstart=Get time now + 5seconds
4) Get Time
5) IF GET Time < timstart go to 4 else go to 1
Thanks for you help