X-Git-Url: https://git.martlubbers.net/?a=blobdiff_plain;f=dsl%2Fxtend%2Fsrc%2Frobots%2Fmissions%2FTaskDSL.xtext;fp=dsl%2Fxtend%2Fsrc%2Frobots%2Fmissions%2FTaskDSL.xtext;h=7fb398a0cee692cb23bfc72d6c9d485c0661d389;hb=f92a71770aa8fc8abe3a60660df2965ec18cb479;hp=641e3c31588df1391bac706c5e62489935a4f266;hpb=095cdf6fc0cbad75c6057a401cbab23c18931a3d;p=des2015.git diff --git a/dsl/xtend/src/robots/missions/TaskDSL.xtext b/dsl/xtend/src/robots/missions/TaskDSL.xtext index 641e3c3..7fb398a 100644 --- a/dsl/xtend/src/robots/missions/TaskDSL.xtext +++ b/dsl/xtend/src/robots/missions/TaskDSL.xtext @@ -17,22 +17,24 @@ StoppingExpression: scond=StoppingCondition; StoppingCondition: - 'Collected at least' colors+=Color+ | + 'flag set' varName=ID | 'Touched on' touch=LeftRight | 'Light on' light=LeftRight | 'Distance dangerous at ' dist=BackFront | 'Color is' color=Color | {StoppingCondition} 'Never'; -Behaviour: 'Behaviour' name=ID +Behaviour: 'Behaviour' name=ID 'take control:' tc=StoppingExpression? - 'action:' actions+=Action+; + 'action:' actions+=Action+ + ; Action: whichMotor=LeftRight 'motor' moveDir=Direction ('with speed' spd=INT 'acceleration' acc=INT)? | 'turn' turnType=Turn ('with speed' spd=INT 'acceleration' acc=INT)? | 'measure' rl=RockLake| - 'wait' time=Time; + 'wait' time=Time | + 'set flag' varName=ID; Turn: turnDir=LeftRight 'exactly' degrees=INT 'degrees'|