Implemented measure motor
[des2015.git] / dsl / xtend / src / robots / missions / TaskDSL.xtext
index 65351f9..afefa5d 100644 (file)
@@ -20,7 +20,7 @@ StoppingCondition:
        'Collected at least' colors+=Color+ |
        'Touched on' touch=LeftRight |
        'Light on' light=LeftRight |
-       'No object in sight on ' dist=BackFront |
+       'Distance dangerous at ' dist=BackFront |
        'Color is' color=Color;
 
 Behaviour: 'Behaviour' name=ID 
@@ -30,7 +30,7 @@ Behaviour: 'Behaviour' name=ID
 Action:
        whichMotor=LeftRight 'motor' moveDir=Direction ('with speed' spd=INT 'acceleration' acc=INT)? |
        'turn' turnDir=LeftRight degrees=INT ('with speed' spd=INT 'acceleration' acc=INT)? |
-       'measure' measureWhat=RockLake |
+       {Action} 'measure'|
        'wait' time=Time;
 
 Time: time=INT 'ms' | {Time} 'forever';
@@ -40,11 +40,9 @@ enum RockLakeE: ROCK='rock' | LAKE='lake';
 Direction: d=DirectionE;
 enum DirectionE: BACKWARDS = 'backward' | FORWARDS = 'forward';
 Operator: d=OperatorE;
-enum OperatorE: AND = 'and' | OR = 'or';
+enum OperatorE: AND = '&&' | OR = '||';
 BackFront: d=BackFrontE;
 enum BackFrontE: BACK = 'back' | FRONT = 'front';
-Comparison: d=ComparisonE;
-enum ComparisonE: GE='>' | LE='<';
 LeftRight: d=LeftRightE;
 enum LeftRightE: LEFT='left' | RIGHT='right';
 Color: d=ColorE;