Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
05/16/02 20:44
Read: times


 
#23068 - small program, big pain--port3
I have a switch on my board, this guy is connected to P3.5. it is on/off position and bring p3.5 to low and high...
my program is
main:
mov a, #high
jb p3.5, rel
mov a, #low
ljmp rel1
rel:
call high program
ljmp main

rel1:
call low program
ljmp main
the problem is my program always go low, no matter what switch position...

when i change the switch position, I can see the voltage on p3.5 is change from low to high....

but why my program always go to low....

BTW, I have init the port3 as 00111101b, my program doesn't work, if i set port3 as 11111111b, it work...

last thing I will do is changing my CPU...

Thanks

Frank






List of 3 messages in thread
TopicAuthorDate
small program, big pain--port3            01/01/70 00:00      
RE: small program, big pain--port3            01/01/70 00:00      
RE: small program, big pain--port3            01/01/70 00:00      

Back to Subject List