Rev 294 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | Download
program example_program;var i;var ble;var last;LMOT := 30;RMOT := -30;ble:=0;while ble<25 do ble:=ble+1; end;LMOT := 30;RMOT := 30;ble:=0;while ble<125 do ble:=ble+1; end;while truedoif LEYE = 1 and REYE = 1 and RFTOUCH = 0 and LFTOUCH = 0 and RRTOUCH = 0 and LRTOUCH = 0 thenif last=1 thenRMOT := 30;LMOT := -30;elseLMOT := 30;RMOT := -30;end;end;if LEYE = 0 thenLMOT := -30;RMOT := -30;continue;end;if REYE = 0 thenRMOT := -30;LMOT := 30;continue;end;if LRTOUCH = 1 thenRMOT := -30;LMOT := -30;last := 1;end;if RRTOUCH = 1 thenLMOT :=-30;RMOT :=-30;last := 0;end;if RFTOUCH = 1 and LFTOUCH =1 thenLMOT :=30;RMOT := 30;end;if RRTOUCH = 1 and LRTOUCH =1 thenLMOT := -30;RMOT := -30;end;end;