Try
Disable Debug
define LOADER_USED 1
define OSC 20
trisa = %00000000
trisb = %00000000
trisc = %00000000
porta = %00000000
portb = %00000000
portc = %00000000
'Variables and Constants
counter var word 'For-Loop variable
servo var byte 'Servo output pin
'servo = portb.5
Enable Debug
'Servo movement module
spin_CCW:
counter = 0
for counter = 1 to 100
pulsout portb.5, 150
pause 20
next
spin_CW:
counter = 0
for counter = 1 to 100
pulsout portb.5, 1500
pause 20
next
goto spin_ccw
end




Bookmarks