-
Notifications
You must be signed in to change notification settings - Fork 0
/
ex_02.ceu
44 lines (43 loc) · 816 Bytes
/
ex_02.ceu
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
input int PIN02, PIN03;
output int PIN13;
var int dt = 1000;
par/or do
loop do
emit PIN13 => _HIGH;
await (dt)ms;
emit PIN13 => _LOW;
await (dt)ms;
end
with
loop do
var int on = await PIN02
until on and (dt > 200);
dt = dt - 100;
await 50ms;
end
with
loop do
var int on = await PIN03
until on;
dt = dt + 100;
await 50ms;
end
with
loop do
par/or do
par/and do
await PIN02;
with
await PIN03;
end
break;
with
par/or do
await PIN02;
with
await PIN03;
end
await 500ms;
end
end
end