Mail Archives: djgpp/1998/09/14/14:30:49
On Fri, 11 Sep 1998, Tal Lavi wrote:
> After about ten key presses that works fine, the keyboard buffer seems
> to be full, and it's beeping me whenever I press a key. Does anyone know
> how to fix it(clean the buffer or something)?
Why do you chain to the original handler? Do you really need that?
If you do, you need to somehow make sure some other code in your
program reads the keyboard using the BIOS functions. Otherwise, the
BIOS will put the keystrokes into its buffer, and when that fills, it
will beep on you.
> Does anyone knows what "outportb(0x20,0x20)" is for?
When the PIC (the Programmable Interrupt Controller) sees one of the
IRQ lines triggered, it disables that IRQ line until you send the EIO
(End Of Interrupt) command, which is what the above does. In other
words, if you don't send the EOI, you will never see that interrupt
again.
> And yet another strange thing I noticed, I can use int 9 OR int 8! for
> some strange reason, both of them seem to work! how can that be?
Bugs always seem mysterious at first... ;-).
- Raw text -