Yes of course if you are thinking in terms of accurate 1/50sec timings, then my routine isn't at all accurate in that respect, but does a reasonable job of incrementing counts for display purposes like mr navigator seemed to want (or what I thought he wanted).polka wrote:Wouldn't this scheme only work if SuperBasic is the only job running ? Otherwise, I guess that other jobs may be stealing 1/50sec time slices ? same question for PAUSE 1 : normally it pauses the computer (actually the SuperBasic job) for at least one 1/50sec cycle, but actually may it not pause for longer ?
Would it be possible (to your opinion) to add a little counting code sequence linked directly into the Qdos scheduler, which for sure ticks every 1/50sec ? If so, I think it would be the best timer practical...
Paul
George Gwilt's timing routines in the Quanta mag in June/July 2011 (page 27) showed how simply that could be done with a small piece of assembler code (just 10 lines) linked into the polled list, incrementing a counter held in a spare system variable long word at offset $DC. Most of that 10 lines of code is actually linking in the routine, the timer facility itself (called every 1/50 second) is just an instruction to increment the value and an RTS instruction.
Dilwyn