Re: A89: STron89(not quite as long... :)... )


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

Re: A89: STron89(not quite as long... :)... )




I'd like to know that myself .. I installed an auto int 1 handler, but that
didn't seem to get rid the x/x at the bottom right.  Is there another
interrupt with that?

To answer your question, when you read from directly from the keyboard you
are reading from the ports rather than from an address updated by interrupt
routine that reads from the keypad port.  To work it, you must put a bitmask
out the port containing the row of your key (look at the keyboard matrix
doc), then after a short wait read back from the port and the bit set (maybe
the bit not set?) will be the column of the matrix.  I haven't tried this on
the 89 so I might not be completely accurate, but that's the idea.
A key is held down if you test the key using the port again and it's still
pressed.  The way of seeing if it was just pressed (because a simple light
keypress will appear held down for many loops) is to set up a timer, a delay
or to check if the key was released.


>
>also why do the interrupts even need to be disabled...what interrupt is
being
>disabled here???...just to make things more clear how would i (let's say)
>check to see if the up key was being pressed...if read directly from the
>keyboard...(what does it mean to be read directly from the keyboard (as
>opposed to what?)  Does it also tell you if a key is being held down...?
How
>would you differentiate from knowing if a key is pressed or is being held
>down???  THANKS AGAIN...