orchestrator.pr 2.55 KB
Newer Older
1
/* CIF PROCESS (297, 59), (150, 75) */
Maxime Perrotin's avatar
Maxime Perrotin committed
2
PROCESS orchestrator
3
/* CIF COMMENT (407, 195), (71, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
4
5
6
7
8
9
10
COMMENT 'Hello';
    /* CIF TEXT (0, 94), (398, 312) */
    dcl seq tastE_Peek_id_list := { 1,2,3,4,5};

dcl a myEnum;

dcl fixed fixedIntList := { 1,2,3};
11
12
13
14

dcl anInt T_UInt32 :=0;

timer myTimer;
Maxime Perrotin's avatar
Maxime Perrotin committed
15
    /* CIF ENDTEXT */
16
    /* CIF START (743, 150), (80, 36) */
Maxime Perrotin's avatar
Maxime Perrotin committed
17
    START;
18
        /* CIF NEXTSTATE (749, 201), (68, 34) */
Maxime Perrotin's avatar
Maxime Perrotin committed
19
        NEXTSTATE Wait;
20
    /* CIF STATE (1034, 125), (93, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
21
    STATE timeout;
22
        /* CIF INPUT (1019, 180), (122, 35) */
23
        INPUT Paramless_TC;
24
            /* CIF PROCEDURECALL (981, 230), (200, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
25
            CALL SET_timer(1000, mytimer);
26
            /* CIF NEXTSTATE (1046, 280), (70, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
27
28
            NEXTSTATE next;
    ENDSTATE;
29
30
31
32
33
34
35
36
37
38
    /* CIF STATE (992, 345), (70, 35) */
    STATE next;
        /* CIF INPUT (965, 400), (122, 35) */
        INPUT pulse(a);
            /* CIF PROCEDURECALL (939, 450), (173, 35) */
            CALL reset_timer(mytimer);
            /* CIF NEXTSTATE (991, 500), (70, 35) */
            NEXTSTATE wait;
    ENDSTATE;
    /* CIF STATE (749, 201), (68, 34) */
Maxime Perrotin's avatar
Maxime Perrotin committed
39
    STATE Wait;
40
        /* CIF INPUT (496, 255), (87, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
41
        INPUT pulse(a);
42
            /* CIF TASK (469, 305), (139, 40) */
43
44
            TASK seq := {0,1,0,1,0},
anint := 478;
45
46
47
            /* CIF PROCEDURECALL (433, 360), (212, 35) */
            CALL writeln('Input param', anint);
            /* CIF PROCEDURECALL (442, 410), (193, 35) */
Marco Lattuada's avatar
Marco Lattuada committed
48
            CALL ExternalProc(anint, anint);
49
50
51
            /* CIF PROCEDURECALL (427, 460), (224, 35) */
            CALL writeln('Output param', anint);
            /* CIF OUTPUT (482, 510), (114, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
52
            OUTPUT telemetry(a);
53
            /* CIF OUTPUT (478, 560), (123, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
54
            OUTPUT peek_list(seq);
55
            /* CIF OUTPUT (467, 610), (145, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
56
            OUTPUT peek_fixed(fixed);
57
            /* CIF NEXTSTATE (504, 660), (70, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
58
            NEXTSTATE next;
59
        /* CIF INPUT (706, 255), (122, 35) */
60
        INPUT Paramless_TC;
61
            /* CIF PROCEDURECALL (664, 305), (205, 35) */
62
            CALL writeln('Got Paramless TC');
63
            /* CIF PROCEDURECALL (667, 355), (200, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
64
            CALL SET_timer(1000, mytimer);
65
            /* CIF OUTPUT (705, 405), (125, 35) */
66
            OUTPUT Paramless_TM;
67
            /* CIF NEXTSTATE (732, 455), (70, 35) */
68
            NEXTSTATE wait;
69
        /* CIF INPUT (880, 255), (90, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
70
        INPUT mytimer;
71
            /* CIF NEXTSTATE (880, 305), (90, 35) */
Maxime Perrotin's avatar
Maxime Perrotin committed
72
            NEXTSTATE Timeout;
Maxime Perrotin's avatar
Maxime Perrotin committed
73
    ENDSTATE;
Marco Lattuada's avatar
Marco Lattuada committed
74
ENDPROCESS orchestrator;