Rob,
I would read the entire PortB, and then do a CASE senario based on the values at the Port so that if two buttons are pressed at the same time you can detect it.
For example:
<table border="1" padding="3" spacing="3"><tr><td>
B0 var byte
TRISB = %11111111 'MAKE PORT B INPUT
B0 = PORTB
START:
SELECT CASE B0
CASE 0
' NO SWITCHED PRESSED
CASE 1
' SWITCH ONE PRESSED
CASE 2
' SWITCH TWO PRESSED
CASE 3
' SWITCH'S ONE AND TWO
CASE N
' WHAT EVER
END SELECT
GOTO START
<br></td></tr></table>
Bookmarks