delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/11/09/11:10:36

Date: Sun, 9 Nov 1997 18:08:08 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: ionicis AT geocities DOT com
cc: djgpp AT delorie DOT com
Subject: Re: int 16h/func 00h
In-Reply-To: <3463E3D8.968C53AE@geocities.com>
Message-ID: <Pine.SUN.3.91.971109180425.12355B-100000@is>
MIME-Version: 1.0

On Fri, 7 Nov 1997 ionicis AT geocities DOT com wrote:

> Ok, what EXACTLY does that interrupt function do?  I need to know
> EXACTLY what it does when called.

Then please download the Ralf Brown's Interrupt List 
(ftp://ftp.simtel.net/pub/simtelnet/msdos/info/inter55*.zip) and read 
there.  However, I think this function is not your problem, see below.

> keyboard interrupt functions.  I want the program to prompt the user via
> the first printf(), and then call get_key(), and when the user presses a
> key (because I assume that int6h/00h waits for the user to hit a key,
> then returns the data), and then it tells the user what key was hit.
> For some reason, the first printf() dosen't execute until the user hits
> a key.  When a key is hit, both printf()s execute.  Why is this?  BTW,
> I'm using DJGPP.

This is all explained in the DJGPP FAQ list (v2/faq210b.zip from the same 
place you get DJGPP), section 9.4.  The problem is that `printf' uses 
buffered output, and actual screen writes are delayed to save CPU 
cycles.  The FAQ explains how to get DJGPP to write immediately.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019