SquareDance.BS2

From RoboWiki
Revision as of 12:46, 15 February 2011 by Balogh (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
' {$STAMP BS2}
' {$PBASIC 2.5}

Counter VAR Byte

DEBUG "Program Running!"

Main:

  GOSUB Forward
  GOSUB Right
  GOTO Main

END

Forward:
  FOR counter = 1 TO 50
    PULSOUT 13, 850
    PULSOUT 12, 650
    PAUSE 20
  NEXT
  PAUSE 200
  RETURN


Right:
  FOR counter = 1 TO 22
    PULSOUT 13, 850
    PULSOUT 12, 850
    PAUSE 20
    NEXT
    PAUSE 200
  RETURN