Code:
RF VAR word : c VAR byte : b VAR byte : output_TX VAR PORTD.5
output output_tx
Main: RF=$7f2 : Output_TX = 0 : For c = 1 To 4 : PulsOut Output_TX, 35
For b = 0 To 11
If RF.0[b] = 0 Then
PauseUs 330 : PulsOut Output_TX, 66 '660uS pulse
Else
PauseUs 660 : PulsOut Output_TX, 33 '330uS pulse
EndIf
Next b : Pause 40 : Next C : Sleep 2 : GoTo Main
Might help to put the variable that you are NEXTing in your NEXT statements...and set the pin that you are using to an output before you use it.
(The high colonic master strikes again!)
Bookmarks