[A83] Re: value when no key pressed


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

[A83] Re: value when no key pressed




Port 1 will be 0FFh if no key was pressed. cp does not change register A.
After the in a,(1); a cp 0FFh would be Z then if no key was pressed...I
don't want to confuse you so, please ignore the sentences after this if you
get confused. You could also use 'inc a' instead of cp 0FFh to save space
and time...this would change A though but if 0FFh was in A the 'inc a' would
make it then 0 (overflow)...And since 'inc' sets the Z/NZ flag it would be Z
if it was 0...So if it was Z you'd know it was 0FFh before...

Michael Vincent
Detached Solutions - www.detacheds.com
Radical Software - www.radicalsoft.org
----- Original Message -----
From: "Michael J" <harry3003@hotmail.com>
To: <assembly-83@lists.ticalc.org>
Sent: Friday, February 01, 2002 7:02 PM
Subject: [A83] value when no key pressed


> What value does the TI-83 calculator return in direct input if no key is
> pressed?  And in a program could i use the command cp knothing (knothing
> being the value when no key is pressed) to check whether or not a key is
> pressed?  In Asmguru it tells me that the cp command changes register a,
but
> is this temporary or permanent because when i displayed the contents of a
> after cp it was not changed.
>
> --------------------------------------------------------------------------
--
> Send and receive Hotmail on your mobile device: Click Here[1]
>
>
> --- Links ---
>    1 'http://go.msn.com/bql/hmtag2_etl_EN.asp'
>




References: