I've been in embedded/real-time for a long time. I've put-off having to learn the Microsquash programming world for a while. I now an submitting .... In any embedded O/S or kernel, the following is easy...
I've written utilities using VC++ (6.0) on and off, mainly repackaging binaries for CRC's, Hex/S formats etc... I'm running on XP pro.
I need to make a "continuous" calculation, say 10 -> 100 times a second.
The calculation is not compute intensive.
I want to "sleep" the process/task/thread for the appropriate time to achieve the required frequency... I do not want to do busy-waiting in a loop, I have to free up the CPU bandwidth for other stuff...
I know Windows is NOT real-time or deterministic by any stretch of the imagination... It's not required for the simulation I'm doing...
so .... the pattern is simply for now, compute; print; sleep ->
eventually I'm going to pass this compute result to another "process" running on the CPU -> another cosole instance is preferred.
This is a CONSOLE app... There appears to be a POSIX interface that may allow me to do what I need, is there any other API I can use that will allow me to remain in a console APP? or do I have to submit myself to re-learning the windows proc loop to use windows API's for this??? Hmmm, just remembered a book on windows/NT threading I think...
BUT, I come here first for the wizened sages who have gone thru learning window "re-terminology" for all we learned in school (the way back machine here... Windows was still 16 bit when I was in school....)
TIA,
-Dan