home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.os2.programmer
- Path: sparky!uunet!snorkelwacker.mit.edu!bloom-picayune.mit.edu!athena.mit.edu!shabby
- From: shabby@Athena.MIT.EDU (Chris Shabsin)
- Subject: Re: What is wrong with this post(Idle dos box/giveup time slice)?
- In-Reply-To: mg@elan's message of 26 Aug 92 09:18:19 GMT
- Message-ID: <SHABBY.92Sep4031932@w20-575-48.mit.edu>
- Sender: news@athena.mit.edu (News system)
- Nntp-Posting-Host: w20-575-48.mit.edu
- Organization: Massachusetts Institute of Technology
- References: <mg.714119080@elan> <mg.714820699@elan>
- Date: Fri, 4 Sep 1992 07:19:39 GMT
- Lines: 18
-
- Well, kbhit() just checks a register somewhere, it does NOT wait for
- the key to be hit. (You obviously know this...) Basically, I assume
- that OS/2 doesn't detect this to be idle because you're just checking
- a memory location, as near as it can tell... (unless you want it to
- have hard-coded memory locations for things such as keyboard buffer in
- the idle-testing code). When you call the interrupt to wait for a
- key, this TELLS it what you are doing, explicitly. You should be
- doing it that way, anyway.
-
- These are all guesses of mine, but I am pretty sure it's how it works.
- --
- -Chris Shabsin
- -shabby@athena.mit.edu
- -member, SIPB, PWLCSBHNM, MITMB, VWA, MITCC, PWN
- -founder, Gations, Inc.
- -"You got the power, you got the might, get ready for battle, beat
- that Black Knight!"
- -Black Knight pinball game...
-