On 13 Feb 2002 23:49:10 -0800, [EMAIL PROTECTED] wrote:

>>   I hope I have no more bad surprises such as the keyboard
>> (I had to use a uncommon and not-very-standard solution, but
>> it seems to work everywhere), but if there are new surprises,
>> I'll fight with them and defeat them. (^=
>Hum... how have you finally solved the keyboard problem?
>I hope you will finish the entire translation soon, I really want to play this game!

  The game only calls the key entry routine when it needs a new
key. In fact, it only call it when need to enter any key (most
times, when needing to type only a number, it uses directly the
keyboard columns lines...).
  Well, so, following the advice of Adriano Cunha, I used the
same process he uses on Uzix. I call a non-documented BIOS
routine that read the key matrix again and put it on the
keybuffer (which I had cleaned before calling this routine,
to avoid trash) as a ASCII number. I verify then if it is
a "normal ASCII" (number or letter) and if yes, return the
ASCII. If not, I let the game proceed with its own procedure
(there is not differente between the keyboard typer for the
extended keys). This is needed because the game associates
special values for some control keys (PE: Home becomes 0xF0.
I don't know why, but I thought it was better do not change it).

  This is how the mistery was solved. In fact, the big trouble
was in finding a BIOS procedure that was able to ready the
keyboard with the IRQ disabled... and more: a procedure that
should be in the same place on every computer. These procedures
are 0d12h, which reads the keyboard and fill a keymatrix structure
and 0d4eh, which translates this structure into a ASCII number
on the keybuffer.

  I don't know the specifics about these, unless the fact their
addresses are unchanged from machine to machine and they work.
For more info, consult the MSX BIOS. ((((^=


  []'s

  Daniel Caetano
  [EMAIL PROTECTED]

..."A necessidade de criatividade e' o que contribui para a 
mudanca. A criatividade mantem o criador vivo." (Frank Herbert)
http://soulmatrix.dynodns.net/ - This OS/2 system uptime is 1 days 15:58 hours.


--
For info, see http://www.stack.nl/~wynke/MSX/listinfo.html

Reply via email to