try this
Finger crossed, I don't have PBCCode:SYMBOL PORTB=$06 symbol TRISB=$86 POKE TRISB,1 ' PORTB.0 = input, other = output POKE PORTB,0 ' Clear all output main: PEEK PORTB,B0 if BIT0 =1 then goto loop 'enter loop 'forward high 7 'enable pin high 6 low 5 high 4 low 3 high 2 'enable pin goto main loop: PEEK PORTB,B0 if BIT0=0 then GOTO main 'exit the loop 'backup high 7 'enable pin low 6 'stop this side low 5 low 4 'reverse this side high 3 high 2 'enable pin goto loop
Bookmarks