Hello Brent,
BB> ...a single timer tick is too long.
^^^^^^^^^^^^^^^^^
BB> What else can I use as a timer so that the speed is the same on all
BB> machines?
BF> ...programable timer... I just happen to have
BF> the right book for you here then. Pc Programmer's Guide to Low-Level
BF> Functions and Interrupts, by Marus Johnson...
BF> ...int 08H is called 18.2 times a second...
Thanx for the detailed help, Brent. I was trying not to use that timer
because I wanted greater resolution than 1/18 sec.
I will save the data you posted though.
Here is what I do have for using that timer in a round about way.
It looks in the bios area of memory instead of using an interrupt.
delay equ 1 ;for example
timer: ;Wait CX clock ticks
push ds
mov cx, delay ;X/18 second
mov ax, 40h ;point DS to BIOS
mov ds, ax
_wait: mov ax,ds:[6Ch] ;get low word of tick counter
wait1: cmp ax,ds:[6Ch] ;wait for it to change
je wait1
loop _wait ;count CX changes
pop ds
ret
Kind regards, Barry
---------------
* Origin: EBO-BBS A'dam +31-20-6002828 (2:280/901.42)
|