I am also using program loops for delays/timing, when doing something in assembler (this is what I used for stepper driver for my EQ3 - very accurate, crystal controlled timing, as the execution lime for each instructions is known.. and processor (old one, Motorola KJ705) I am using does not have adequate timer).
However, those above-mentioned Delphi delays are funny... instead of milliseconds (what they are supposed to be), they are delaying things by seconds (or more.. I didn't figure out what is happening there). Even sleep(ms) is not quite accurate and it's longer (something to with multitasking in Windows?) but at least it is consistent and short enough to produce acceptable delays for stepper motor pulses duration.
Last edited by bojan; 22-10-2010 at 03:54 PM.
|