Subversion Repositories svnkaklik

Rev

Details | Last modification | View Log

Rev Author Line No. Line
282 kaklik 1
program Orbis;
2
 
3
var line, Rychlost, Zataceni;
4
 
5
#define L 1
6
#define S 2
7
#define R 3
8
 
9
line:=2;
10
 
11
Rychlost:=15;		# omezeni rychlosti (hlavne pro ladici ucely)
12
Zataceni:=0.75;
13
 
14
while true
15
do
16
  if LEYE=0 and CEYE = 1 and REYE=0 then 
17
    LMOT:=Rychlost;RMOT:=Rychlost;
18
    line:=2;
19
    continue;
20
  end;
21
 
22
  if REYE = 0 then		# Cara pod levim sensorem
23
    LMOT:=0;RMOT:=Rychlost*Zataceni;			# jed rovne
24
    line:=1;		# zaznamenej, kdes videl caru
25
    continue;
26
  end;
27
 
28
  if LEYE = 0  then
29
    LMOT:=Rychlost*Zataceni;RMOT:=0;
30
    line:=3;
31
    continue;
32
  end;
33
 
34
end;