TIP: Click on subject to list as thread! ANSI
echo: os2
to: Will Honea
from: Fred Springfield
date: 1999-09-10 08:44:09
subject: DOS program `fix`

Will Honea wrote to Leonard Erickson--

WH> Leonard Erickson wrote to All on 09-09-1999
WH> 
WH> LE> I've got a DOS program that I need to run that hogs the CPU.
WH> LE> Setting idle sensitivity to 1 improves things greatly. 
WH> LE> 
WH> LE> But I've got the source, and I'd like to make it more
WH> LE> multi-tassking friendly. It looks like it's in a polling loop when
WH> LE> it's hogging the CPU (basicly it's waiting for me to hit a key). 
WH> LE> 
WH> LE> I seem to recall that there's a DOS INT I can call that'll free up
WH> LE> the rest of the timeslice. IE. change the code like this:
WH> 
WH> Just used this last night.  you want int 0x2f, ax = 0x1680.

Leonard didn't mention which version of OS/2 he is using.  

This was broken in OS/2 v2.1, and works OK in Warp 3.  In Warp 4 it
was also broken, but got fixed around Fixpack 6 or 7, and by FP8 for
sure.  I am currently using FP10, and it is working fine in several DOS
programs which I have written.

If you happen to be writing the DOS programs in MS Quick Basic, look
in Hobbes, or elsewhere, for a file called QBSlice.zip, written by D.
S. Katzer at the U. S. Naval Research Labs.  He describes exactly how to
do it, along with an excellent dissertation of other ways to do it.

Fred Springfield
Plymouth, MN


 þ KWQ/2 1.2i þ If it isn't broken and you try to fix it--it soon will be.

--- ProBoard v2.16 [Reg]
* Origin: RiverWorks * ProBoard Beta Site * V34+ * (1:282/4093)

SOURCE: echoes via The OS/2 BBS

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.