can it be done?
i have the following code. But in order to work i must send always data to serin.I want when the program to be executed all until a new B0 comes.
INCLUDE "MODEDEFS.BAS"
B0 VAR WORD
B1 VAR WORD
Pause 500
SerOut2 PORTC.6,84,["Hi!",13,10]
start:
SerIn2 PORTC.7,84,[DEC B0,DEC B1]
IF(B0==1) Then
Low PORTC.1
High PORTC.2
EndIF
IF(B0==0) Then
Low PORTC.1
Low PORTC.2
EndIF
IF(B0==2) Then
Low PORTC.2
High PORTC.1
EndIF
IF (B1==3) Then
Low PORTC.2
High PORTC.1
Pause 10
Low PORTC.2
Low PORTC.2
Pause 10
EndIF
IF (B1==4) Then
Low PORTC.2
High PORTC.1
Pause 500
Low PORTC.2
Low PORTC.2
Pause 1000
EndIF
GoTo start
End
Bookmarks