tanero,
your code works as designed.
IF RA.0 only is LOW it will read 254 (%11111110)
IF RA.1 only is LOW it will read 253 (%11111101)
IF both RA.0 and RA.1 are LOW it will read 252 (%11111100)
so none of the IF... conditions is TRUE, that's why it is just LOOPing
You may want to check the port bits individually:
If PortA.0=0 THEN...
If PortA.1=0 THEN...
etc.
regards
Ralph
_______________________________________________
There are only 10 types of people:
Those who understand binary, and those who don't ...
_______________________________________________
Bookmarks