English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

I have tried the "hlt" instruction-hasn't worked. I have tried int 15h with ax =83 and 86-neither has worked. I have tried reading the system time but I only get seconds precision. I need millisecond precision. I need something that will work on most computers. Preferably, the solution works for intel processors. Source code or a very good description of the solution would be very nice. Thank you for answering.

2007-01-31 07:13:23 · 2 answers · asked by Bridgeofstraws 2 in Computers & Internet Programming & Design

2 answers

You could write a routine that times a particular instruction against the system clock (Like how many times can I do x in 1 second) and calculate how many times you need to perform x to create the delay that you want.

2007-01-31 07:21:51 · answer #1 · answered by Amanda H 6 · 1 0

You need to obtain a time reference, whether it be the system clock or a separate timer. You can not create an assembly language program that will give identical timing on all machines without some way of it finding out how fast it is going.

Even with a specific set of hardware you are asking someone for a good deal of work, I couldn't be bothered anyway, but even if I could be bothered I wouldn't look at it for under $500.

2007-01-31 08:01:30 · answer #2 · answered by Chris H 6 · 0 0

fedest.com, questions and answers