qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 0 of 1] Fix for DOS keyboard problems


From: malc
Subject: Re: [Qemu-devel] [PATCH 0 of 1] Fix for DOS keyboard problems
Date: Mon, 24 Aug 2009 12:21:38 +0400 (MSD)

On Mon, 24 Aug 2009, Stefan Ring wrote:

> On Sun, Aug 23, 2009 at 11:55 PM, Jamie Lokier<address@hidden> wrote:
> > Let's see if I understand your explanation.
> >
> >   1. Cursor key is pressed.  The key press is represented as two scan codes.
> >   2. IRQ 1 is entered.
> >   3. Borland's code reads port 60h - gets the first scan code.
> >   4. BIOS's code reads port 60h - gets the second scan code.
> >   5. Return from IRQ 1.
> >
> >   6. Cursor key is released.  The key release is represented as two
> >      scan codes.
> >   7. IRQ 1 is entered.
> >   8. Borland's code reads port 60h - gets the first scan code.
> >   9. BIOS's code reads port 60h - gets the second scan code.
> >  10. Return from IRQ 1.
> >
> > So both Borland's code and the BIOS are *missing* scan codes.
> >
> > How does that result in Borland seeing *multiple* cursor key
> > press/release sequences?
> 
> Actually I wondered about the same thing while I wrote my previous
> answer... I'm not exactly sure, but it seems to happen like this: the
> cursor keys generate two scan codes - E0h and the real scan code in
> this order. Somehow the second IRQ seems to happen although its value
> has already been consumed by the first interrupt handler activation,
> and during the second invocation the handler will just get repetitions
> of the last value read. Apparently the scan code for the cursor keys
> is interpreted as cursor movement regardless if E0h appeared earlier
> or not.

[..snip..]

There's other DOS application that exhibits erroneous keyboard
beahviour and i was curious whether your hack "fixes" it too (alas
it doesn't) - Command and Conquer, the demo can be found at:

http://www.dosgamesarchive.com/download/command-and-conquer/

Keyboard is dysfunctional in both the setup and the game. What i'm
wondering now if this is a indeed pckbd or BIOS problem, but Bochs
where the former can be verified refuses to work on my machines,
perhaps someone could give it a try and report here?

-- 
mailto:address@hidden

reply via email to

[Prev in Thread] Current Thread [Next in Thread]