-
Notifications
You must be signed in to change notification settings - Fork 1
/
carrier.rosl
44 lines (44 loc) · 1.3 KB
/
carrier.rosl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
while (true) {
receive(producer, idle) {
case Ok() => {
moveCart( 500 );
setAngleCart( -90 );
strafeCart( -100 );
send(sensor,Ok);
receive(sensor, idle) {
case Red() => {
send(franka, Ok);
send(arm, Done);
moveCart(400);
send(franka, Ok);
receive(franka, idle) {
case Ok() => {
moveCart(-400);
strafeCart( 100 );
setAngleCart( 0 );
moveCart( -500 );
}
}
}
case Green() => {
send(arm, Ok);
send(franka, Done);
moveCart(-340);
send(arm, Ok);
receive(arm, idle) {
case Ok() => {
moveCart( 340 );
strafeCart( 100 );
setAngleCart( -0 );
moveCart( -500 );
}
}
}
}
}
case Done() => {
stop( );
exit( 0 );
}
}
}