[A83] Re: Direct Input...


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

[A83] Re: Direct Input...




> The code in the ROM for both the 83 and 86 uses 4.  The relevant portion
of
> the ROM (same on both calcs) is shown below:
> 
>  out (1),a
>  nop \ nop \ nop \ nop
>  in a,(1)
>  ld b,a
>  ld a,$ff
>  out (1),a
> 
> I don't remember ever having to reset the port when reading keys (but
maybe
> I never read more than the arrows using the ports).

Okay, if you only use one group of keys in your entier program, than it
will work, accordingly to the code from ROM you provided.

See, the last two instructions 'reset' the keyboard ("out (1),$FF"), so the
next thing  you write to it will work normaly even if you don't reset the
keyboard :-)

It might be possible that the TIOS goes a little berzerk the next time it
does a read 'by itself' (since it reads more than one group). But maybe it
also resets the keyboard before this code.

	Henk Poley