Project

General

Profile

Statistics
| Branch: | Tag: | Revision:

lustrec-tests / regression_tests / lustre_files / success / kind_fmcad08 / large / all files / microwave40.lus @ b8dc00eb

History | View | Annotate | Download (40.1 KB)

1
--@ ensures OK;
2
node top(KP_START: bool; 
3
      KP_CLEAR: bool; 
4
      KP_0: bool; 
5
      KP_1: bool; 
6
      KP_2: bool; 
7
      KP_3: bool; 
8
      KP_4: bool; 
9
      KP_5: bool; 
10
      KP_6: bool; 
11
      KP_7: bool; 
12
      KP_8: bool; 
13
      KP_9: bool; 
14
      DOOR_CLOSED: bool
15
) returns (OK:bool);
16

    
17
   
18
var
19
   LEFT_DIGIT: int; 
20
      SETUP: bool; 
21
      COOKING: bool; 
22
      SUSPENDED: bool; 
23
      START_PRESSED: bool; 
24
      CLEAR_PRESSED: bool; 
25
      MIDDLE_DIGIT: int; 
26
      RIGHT_DIGIT: int; 
27
      enable: bool; 
28
      STEPS_TO_COOK: int;
29
      
30
   rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_clock: bool; 
31
   KP_01: bool; 
32
   KP_11: bool; 
33
   KP_21: bool; 
34
   KP_31: bool; 
35
   KP_41: bool; 
36
   KP_51: bool; 
37
   KP_61: bool; 
38
   KP_71: bool; 
39
   KP_81: bool; 
40
   KP_91: bool; 
41
   rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_init_step: bool; 
42
   microwave_microwave_KEYPAD_PROCESSING_DISPLAY_LEFT_DIGIT_DIGIT_TO_DISPLAY: int; 
43
   microwave_microwave_KEYPAD_PROCESSING_DISPLAY_MIDDLE_DIGIT_DIGIT_TO_DISPLAY: int; 
44
   microwave_microwave_KEYPAD_PROCESSING_DISPLAY_RIGHT_DIGIT_DIGIT_TO_DISPLAY: int; 
45
   rlt__Arrow5: int; 
46
   rlt__Arrow4: int; 
47
   rlt__Arrow3: int; 
48
   rlt__Arrow2: int; 
49
   rlt__Arrow1: int; 
50
   rlt__Arrow: int; 
51
   chart_microwave_mode_logic_start: int; 
52
   chart_microwave_mode_logic_clear_off: int; 
53
   chart_microwave_mode_logic_door_closed: int; 
54
   chart_microwave_mode_logic____wakeup___: bool; 
55
   rlt_eval_microwave_mode_logic_ON_rlt_fired_1: bool; 
56
   rlt_eval_microwave_mode_logic_ON_rlt_state_1_states___root: int; 
57
   rlt_eval_microwave_mode_logic_ON_rlt_state_2_states___root: int; 
58
   rlt_eval_microwave_mode_logic_ON_rlt_fired_2: bool; 
59
   rlt_eval_microwave_mode_logic_ON_rlt_complete_1: bool; 
60
   rlt_eval_microwave_mode_logic_ON_rlt_state_3_states___root: int; 
61
   rlt_eval_microwave_mode_logic_ON_rlt_state_3_outports_mode: int; 
62
   rlt_eval_microwave_mode_logic_ON_rlt_state_4_states___root: int; 
63
   rlt_eval_microwave_mode_logic_ON_rlt_state_4_outports_mode: int; 
64
   rlt_eval_microwave_mode_logic_ON_rlt_fired_4: bool; 
65
   rlt_eval_microwave_mode_logic_ON_rlt_complete_2: bool; 
66
   rlt_eval_microwave_mode_logic_ON_rlt_state_6_states___root: int; 
67
   rlt_eval_microwave_mode_logic_ON_rlt_state_6_outports_steps_remaining: int; 
68
   rlt_eval_microwave_mode_logic_ON_rlt_state_7_states___root: int; 
69
   rlt_eval_microwave_mode_logic_ON_rlt_fired_5: bool; 
70
   rlt_eval_microwave_mode_logic_ON_rlt_state_8_outports_mode: int; 
71
   rlt_eval_microwave_mode_logic_ON_rlt_state_9_states___root: int; 
72
   rlt_eval_microwave_mode_logic_ON_rlt_state_10_states___root: int; 
73
   rlt_eval_microwave_mode_logic_ON_rlt_fired_6: bool; 
74
   rlt_eval_microwave_mode_logic_ON_rlt_state_11_states___root: int; 
75
   rlt_eval_microwave_mode_logic_ON_rlt_state_11_outports_mode: int; 
76
   rlt_enter_microwave_mode_logic_ON_rlt_state_1_states___root: int; 
77
   rlt_enter_microwave_mode_logic_ON_rlt_fired_0: bool; 
78
   rlt_enter_microwave_mode_logic_ON_rlt_fired_1: bool; 
79
   rlt_enter_microwave_mode_logic_ON_rlt_state_2_states___root: int; 
80
   rlt_enter_microwave_mode_logic_ON_rlt_state_2_outports_mode: int; 
81
   rlt_enter_microwave_mode_logic_ON_rlt_fired_2: bool; 
82
   rlt_enter_microwave_mode_logic_ON_rlt_state_4_states___root: int; 
83
   rlt_eval_microwave_mode_logic_rlt_fired_0: bool; 
84
   rlt_eval_microwave_mode_logic_rlt_state_1_outports_steps_remaining: int; 
85
   rlt_eval_microwave_mode_logic_rlt_fired_1: bool; 
86
   rlt_eval_microwave_mode_logic_rlt_state_2_states___root: int; 
87
   rlt_eval_microwave_mode_logic_rlt_state_3_states___root: int; 
88
   rlt_eval_microwave_mode_logic_rlt_state_3_outports_mode: int; 
89
   rlt_enter_microwave_mode_logic_rlt_state_2_states___root: int; 
90
   chart_microwave_mode_logic_rlt_evtInitStep: bool; 
91
   chart_microwave_mode_logic_begin_state_states___root: int; 
92
   chart_microwave_mode_logic_begin_state_outports_mode: int; 
93
   chart_microwave_mode_logic_begin_state_outports_steps_remaining: int; 
94
   chart_microwave_mode_logic_final_state_states___root: int; 
95
   chart_microwave_mode_logic_mode: int; 
96
   chart_microwave_mode_logic_steps_remaining: int; 
97
   microwave_microwave_TIME_ON_DISPLAY_SECONDS_TO_MINUTES__QUOTIENT: int; 
98
   microwave_microwave_TIME_ON_DISPLAY_SECONDS_TO_TENS__QUOTIENT: int; 
99
   microwave_microwave_TIME_ON_DISPLAY_SECONDS_TO_TENS__REMAINDER: int; 
100
   microwave_microwave_mode_logic_mode: int; 
101
   MWI_FcnMaxI_In16: int; 
102
   MWI_FcnMaxI_In15: int; 
103
   MWI_FcnMaxI_In13: int; 
104
   MWI_FcnMaxI_In12: int; 
105
   MWI_FcnMaxI_In11: int; 
106
   MWI_FcnMaxI_In1: int; 
107
let 
108
   rlt__Arrow5 = (639 -> 
109
      (if (not (not SETUP))
110
         then 
111
               (if (MWI_FcnMaxI_In13 > 0)
112
                  then MWI_FcnMaxI_In13
113
                  else 0)
114
         else 639));
115

    
116
   rlt__Arrow4 = (639 -> 
117
      (if (not SUSPENDED)
118
         then 
119
               (if (MWI_FcnMaxI_In12 > 0)
120
                  then MWI_FcnMaxI_In12
121
                  else 0)
122
         else 639));
123

    
124
   rlt__Arrow3 = (639 -> 
125
      (if (not (not COOKING))
126
         then 
127
               (if (MWI_FcnMaxI_In16 > 0)
128
                  then MWI_FcnMaxI_In16
129
                  else 0)
130
         else 639));
131

    
132
   rlt__Arrow2 = (639 -> 
133
      (if (not (not SUSPENDED))
134
         then 
135
               (if (MWI_FcnMaxI_In15 > 0)
136
                  then MWI_FcnMaxI_In15
137
                  else 0)
138
         else 639));
139

    
140
   rlt__Arrow1 = (639 -> 
141
      (if (not COOKING)
142
         then 
143
               (if (MWI_FcnMaxI_In11 > 0)
144
                  then MWI_FcnMaxI_In11
145
                  else 0)
146
         else 639));
147

    
148
   rlt__Arrow = (639 -> 
149
      (if (not SETUP)
150
         then 
151
               (if (MWI_FcnMaxI_In1 > 0)
152
                  then MWI_FcnMaxI_In1
153
                  else 0)
154
         else 639));
155

    
156

    
157

    
158

    
159

    
160
   MIDDLE_DIGIT = microwave_microwave_TIME_ON_DISPLAY_SECONDS_TO_TENS__QUOTIENT;
161

    
162
   RIGHT_DIGIT = microwave_microwave_TIME_ON_DISPLAY_SECONDS_TO_TENS__REMAINDER;
163

    
164

    
165

    
166

    
167
   MWI_FcnMaxI_In1 = ((pre rlt__Arrow) - 1);
168

    
169
   CLEAR_PRESSED = (KP_CLEAR -> (KP_CLEAR and 
170
      (not (pre KP_CLEAR))));
171

    
172
   microwave_microwave_TIME_ON_DISPLAY_SECONDS_TO_MINUTES__QUOTIENT = ((chart_microwave_mode_logic_steps_remaining div 1) div 60);
173

    
174
   microwave_microwave_TIME_ON_DISPLAY_SECONDS_TO_TENS__REMAINDER = (((chart_microwave_mode_logic_steps_remaining div 1) - (((chart_microwave_mode_logic_steps_remaining div 1) div 60) * 60)) - ((((chart_microwave_mode_logic_steps_remaining div 1) - (((chart_microwave_mode_logic_steps_remaining div 1) div 60) * 60)) div 10) * 10));
175

    
176
   SUSPENDED = 
177
      (if (3 = microwave_microwave_mode_logic_mode)
178
         then true
179
         else false);
180

    
181
   OK = (true -> ((not (enable and 
182
      (not KP_CLEAR))) or 
183
      (((((((((((KP_1 and 
184
      (not (pre KP_1))) or 
185
      (KP_2 and 
186
      (not (pre KP_2)))) or 
187
      (KP_3 and 
188
      (not (pre KP_3)))) or 
189
      (KP_4 and 
190
      (not (pre KP_4)))) or 
191
      (KP_5 and 
192
      (not (pre KP_5)))) or 
193
      (KP_6 and 
194
      (not (pre KP_6)))) or 
195
      (KP_7 and 
196
      (not (pre KP_7)))) or 
197
      (KP_8 and 
198
      (not (pre KP_8)))) or 
199
      (KP_9 and 
200
      (not (pre KP_9)))) or 
201
      (KP_0 and 
202
      (not (pre KP_0)))) or 
203
      (RIGHT_DIGIT = (pre RIGHT_DIGIT)))));
204

    
205
   MWI_FcnMaxI_In11 = ((pre rlt__Arrow1) - 1);
206

    
207
   MWI_FcnMaxI_In15 = ((pre rlt__Arrow2) - 1);
208

    
209

    
210

    
211

    
212
   microwave_microwave_TIME_ON_DISPLAY_SECONDS_TO_TENS__QUOTIENT = (((chart_microwave_mode_logic_steps_remaining div 1) - (((chart_microwave_mode_logic_steps_remaining div 1) div 60) * 60)) div 10);
213

    
214
   MWI_FcnMaxI_In16 = ((pre rlt__Arrow3) - 1);
215

    
216

    
217
   MWI_FcnMaxI_In12 = ((pre rlt__Arrow4) - 1);
218

    
219

    
220

    
221
   COOKING = 
222
      (if (2 = microwave_microwave_mode_logic_mode)
223
         then true
224
         else false);
225

    
226
   LEFT_DIGIT = microwave_microwave_TIME_ON_DISPLAY_SECONDS_TO_MINUTES__QUOTIENT;
227

    
228
   START_PRESSED = (KP_START -> (KP_START and 
229
      (not (pre KP_START))));
230

    
231
   chart_microwave_mode_logic_start = 
232
      (if (START_PRESSED = false)
233
         then 0
234
         else 1);
235

    
236
   chart_microwave_mode_logic_clear_off = 
237
      (if (CLEAR_PRESSED = false)
238
         then 0
239
         else 1);
240

    
241
   chart_microwave_mode_logic_door_closed = 
242
      (if (DOOR_CLOSED = false)
243
         then 0
244
         else 1);
245

    
246
   chart_microwave_mode_logic____wakeup___ = true;
247

    
248
   chart_microwave_mode_logic_rlt_evtInitStep = (true -> 
249
      (if (pre chart_microwave_mode_logic____wakeup___)
250
         then false
251
         else (pre chart_microwave_mode_logic_rlt_evtInitStep)));
252

    
253
   chart_microwave_mode_logic_begin_state_states___root = (0 -> (pre chart_microwave_mode_logic_final_state_states___root));
254

    
255
   chart_microwave_mode_logic_begin_state_outports_mode = (0 -> (pre chart_microwave_mode_logic_mode));
256

    
257
   chart_microwave_mode_logic_begin_state_outports_steps_remaining = (0 -> (pre chart_microwave_mode_logic_steps_remaining));
258

    
259
   chart_microwave_mode_logic_final_state_states___root = 
260
      (if chart_microwave_mode_logic____wakeup___
261
         then 
262
               (if chart_microwave_mode_logic_rlt_evtInitStep
263
                  then rlt_enter_microwave_mode_logic_rlt_state_2_states___root
264
                  else 
265
               (if ((not rlt_eval_microwave_mode_logic_rlt_fired_1) and 
266
                  
267
                  
268
                  ((rlt_eval_microwave_mode_logic_rlt_state_3_states___root >= 1) and 
269
                  (rlt_eval_microwave_mode_logic_rlt_state_3_states___root <= 3)))
270
                  then 
271
                        (if rlt_eval_microwave_mode_logic_ON_rlt_fired_6
272
                           then 
273
                                 (if (not (rlt_eval_microwave_mode_logic_ON_rlt_state_11_states___root = 3))
274
                                    then 
275
                                          
276
                                          3
277
                                    else rlt_eval_microwave_mode_logic_ON_rlt_state_11_states___root)
278
                           else rlt_eval_microwave_mode_logic_ON_rlt_state_11_states___root)
279
                  else rlt_eval_microwave_mode_logic_rlt_state_3_states___root))
280
         else chart_microwave_mode_logic_begin_state_states___root);
281

    
282
   chart_microwave_mode_logic_mode = 
283
      (if chart_microwave_mode_logic____wakeup___
284
         then 
285
               (if chart_microwave_mode_logic_rlt_evtInitStep
286
                  then 
287
                        (if (not (chart_microwave_mode_logic_begin_state_states___root = 4))
288
                           then 1
289
                           else chart_microwave_mode_logic_begin_state_outports_mode)
290
                  else 
291
               (if ((not rlt_eval_microwave_mode_logic_rlt_fired_1) and 
292
                  
293
                  
294
                  ((rlt_eval_microwave_mode_logic_rlt_state_3_states___root >= 1) and 
295
                  (rlt_eval_microwave_mode_logic_rlt_state_3_states___root <= 3)))
296
                  then 
297
                        (if rlt_eval_microwave_mode_logic_ON_rlt_fired_6
298
                           then 
299
                                 (if (not (rlt_eval_microwave_mode_logic_ON_rlt_state_11_states___root = 3))
300
                                    then 3
301
                                    else rlt_eval_microwave_mode_logic_ON_rlt_state_11_outports_mode)
302
                           else rlt_eval_microwave_mode_logic_ON_rlt_state_11_outports_mode)
303
                  else rlt_eval_microwave_mode_logic_rlt_state_3_outports_mode))
304
         else chart_microwave_mode_logic_begin_state_outports_mode);
305

    
306
   chart_microwave_mode_logic_steps_remaining = 
307
      (if chart_microwave_mode_logic____wakeup___
308
         then 
309
               (if chart_microwave_mode_logic_rlt_evtInitStep
310
                  then chart_microwave_mode_logic_begin_state_outports_steps_remaining
311
                  else 
312
               (if ((not rlt_eval_microwave_mode_logic_rlt_fired_1) and 
313
                  
314
                  
315
                  ((rlt_eval_microwave_mode_logic_rlt_state_3_states___root >= 1) and 
316
                  (rlt_eval_microwave_mode_logic_rlt_state_3_states___root <= 3)))
317
                  then 
318
                        (if rlt_eval_microwave_mode_logic_ON_rlt_fired_5
319
                           then (rlt_eval_microwave_mode_logic_ON_rlt_state_6_outports_steps_remaining - 1)
320
                           else rlt_eval_microwave_mode_logic_ON_rlt_state_6_outports_steps_remaining)
321
                  else rlt_eval_microwave_mode_logic_rlt_state_1_outports_steps_remaining))
322
         else chart_microwave_mode_logic_begin_state_outports_steps_remaining);
323

    
324
   
325
   
326
   rlt_eval_microwave_mode_logic_rlt_fired_0 = (chart_microwave_mode_logic_begin_state_states___root = 4);
327

    
328
   
329
   
330
   rlt_eval_microwave_mode_logic_rlt_state_1_outports_steps_remaining = 
331
      (if rlt_eval_microwave_mode_logic_rlt_fired_0
332
         then STEPS_TO_COOK
333
         else chart_microwave_mode_logic_begin_state_outports_steps_remaining);
334

    
335
   
336
   
337
   rlt_eval_microwave_mode_logic_rlt_fired_1 = (rlt_eval_microwave_mode_logic_rlt_fired_0 and 
338
      ((chart_microwave_mode_logic_begin_state_states___root = 4) and 
339
      (
340
      (if (chart_microwave_mode_logic_start <> 0)
341
         then true
342
         else false) and 
343
      
344
      (if (
345
         (if ((STEPS_TO_COOK > 0) = false)
346
            then 0
347
            else 1) <> 0)
348
         then true
349
         else false))));
350

    
351
   
352
   
353
   rlt_eval_microwave_mode_logic_rlt_state_2_states___root = 
354
      (if rlt_eval_microwave_mode_logic_rlt_fired_1
355
         then 
356
               (if (chart_microwave_mode_logic_begin_state_states___root = 4)
357
                  then 
358
                        
359
                        0
360
                  else chart_microwave_mode_logic_begin_state_states___root)
361
         else chart_microwave_mode_logic_begin_state_states___root);
362

    
363
   
364
   
365
   rlt_eval_microwave_mode_logic_rlt_state_3_states___root = 
366
      (if rlt_eval_microwave_mode_logic_rlt_fired_1
367
         then rlt_enter_microwave_mode_logic_ON_rlt_state_4_states___root
368
         else rlt_eval_microwave_mode_logic_rlt_state_2_states___root);
369
   
370
   
371

    
372
   
373
   
374
   rlt_eval_microwave_mode_logic_rlt_state_3_outports_mode = 
375
      (if rlt_eval_microwave_mode_logic_rlt_fired_1
376
         then 
377
               (if rlt_enter_microwave_mode_logic_ON_rlt_fired_2
378
                  then 
379
                        (if (not (rlt_enter_microwave_mode_logic_ON_rlt_state_2_states___root = 3))
380
                           then 3
381
                           else rlt_enter_microwave_mode_logic_ON_rlt_state_2_outports_mode)
382
                  else rlt_enter_microwave_mode_logic_ON_rlt_state_2_outports_mode)
383
         else chart_microwave_mode_logic_begin_state_outports_mode);
384
   
385
   
386

    
387
   
388
   
389
   rlt_eval_microwave_mode_logic_ON_rlt_fired_1 = (((rlt_eval_microwave_mode_logic_rlt_state_3_states___root = 2) and 
390
      (rlt_eval_microwave_mode_logic_rlt_state_1_outports_steps_remaining <= 0)) and 
391
      (rlt_eval_microwave_mode_logic_rlt_state_3_states___root = 2));
392

    
393
   
394
   
395
   rlt_eval_microwave_mode_logic_ON_rlt_state_1_states___root = 
396
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_1
397
         then 
398
               (if 
399
                  
400
                  ((rlt_eval_microwave_mode_logic_rlt_state_3_states___root >= 1) and 
401
                  (rlt_eval_microwave_mode_logic_rlt_state_3_states___root <= 3))
402
                  then 
403
                        
404
                        0
405
                  else rlt_eval_microwave_mode_logic_rlt_state_3_states___root)
406
         else rlt_eval_microwave_mode_logic_rlt_state_3_states___root);
407

    
408
   
409
   
410
   rlt_eval_microwave_mode_logic_ON_rlt_state_2_states___root = 
411
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_1
412
         then 
413
               (if (not (rlt_eval_microwave_mode_logic_ON_rlt_state_1_states___root = 4))
414
                  then 
415
                        
416
                        4
417
                  else rlt_eval_microwave_mode_logic_ON_rlt_state_1_states___root)
418
         else rlt_eval_microwave_mode_logic_ON_rlt_state_1_states___root);
419
   
420
   
421

    
422
   
423
   
424
   rlt_eval_microwave_mode_logic_ON_rlt_fired_2 = ((rlt_eval_microwave_mode_logic_ON_rlt_state_2_states___root = 3) and 
425
      ((
426
      (if (chart_microwave_mode_logic_start <> 0)
427
         then true
428
         else false) and 
429
      
430
      (if (chart_microwave_mode_logic_door_closed <> 0)
431
         then true
432
         else false)) and 
433
      (not rlt_eval_microwave_mode_logic_ON_rlt_fired_1)));
434

    
435
   
436
   
437
   rlt_eval_microwave_mode_logic_ON_rlt_complete_1 = (rlt_eval_microwave_mode_logic_ON_rlt_fired_2 or 
438
      rlt_eval_microwave_mode_logic_ON_rlt_fired_1);
439

    
440
   
441
   
442
   rlt_eval_microwave_mode_logic_ON_rlt_state_3_states___root = 
443
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_2
444
         then 
445
               (if (rlt_eval_microwave_mode_logic_ON_rlt_state_2_states___root = 3)
446
                  then 
447
                        
448
                        1
449
                  else rlt_eval_microwave_mode_logic_ON_rlt_state_2_states___root)
450
         else rlt_eval_microwave_mode_logic_ON_rlt_state_2_states___root);
451

    
452
   
453
   
454
   rlt_eval_microwave_mode_logic_ON_rlt_state_3_outports_mode = 
455
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_1
456
         then 
457
               (if (not (rlt_eval_microwave_mode_logic_ON_rlt_state_1_states___root = 4))
458
                  then 1
459
                  else rlt_eval_microwave_mode_logic_rlt_state_3_outports_mode)
460
         else rlt_eval_microwave_mode_logic_rlt_state_3_outports_mode);
461

    
462
   
463
   
464
   rlt_eval_microwave_mode_logic_ON_rlt_state_4_states___root = 
465
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_2
466
         then 
467
               (if (not (rlt_eval_microwave_mode_logic_ON_rlt_state_3_states___root = 2))
468
                  then 
469
                        
470
                        2
471
                  else rlt_eval_microwave_mode_logic_ON_rlt_state_3_states___root)
472
         else rlt_eval_microwave_mode_logic_ON_rlt_state_3_states___root);
473
   
474
   
475

    
476
   
477
   
478
   rlt_eval_microwave_mode_logic_ON_rlt_state_4_outports_mode = 
479
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_2
480
         then 
481
               (if (not (rlt_eval_microwave_mode_logic_ON_rlt_state_3_states___root = 2))
482
                  then 2
483
                  else rlt_eval_microwave_mode_logic_ON_rlt_state_3_outports_mode)
484
         else rlt_eval_microwave_mode_logic_ON_rlt_state_3_outports_mode);
485
   
486
   
487

    
488
   
489
   
490
   rlt_eval_microwave_mode_logic_ON_rlt_fired_4 = (((rlt_eval_microwave_mode_logic_ON_rlt_state_4_states___root = 3) and 
491
      (
492
      (if (chart_microwave_mode_logic_clear_off <> 0)
493
         then true
494
         else false) and 
495
      (not rlt_eval_microwave_mode_logic_ON_rlt_complete_1))) and 
496
      ((rlt_eval_microwave_mode_logic_ON_rlt_state_4_states___root = 3) and 
497
      (not rlt_eval_microwave_mode_logic_ON_rlt_complete_1)));
498

    
499
   
500
   
501
   rlt_eval_microwave_mode_logic_ON_rlt_complete_2 = (rlt_eval_microwave_mode_logic_ON_rlt_fired_4 or 
502
      rlt_eval_microwave_mode_logic_ON_rlt_complete_1);
503

    
504
   
505
   
506
   rlt_eval_microwave_mode_logic_ON_rlt_state_6_states___root = 
507
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_4
508
         then 
509
               (if 
510
                  
511
                  ((rlt_eval_microwave_mode_logic_ON_rlt_state_4_states___root >= 1) and 
512
                  (rlt_eval_microwave_mode_logic_ON_rlt_state_4_states___root <= 3))
513
                  then 
514
                        
515
                        0
516
                  else rlt_eval_microwave_mode_logic_ON_rlt_state_4_states___root)
517
         else rlt_eval_microwave_mode_logic_ON_rlt_state_4_states___root);
518

    
519
   
520
   
521
   rlt_eval_microwave_mode_logic_ON_rlt_state_6_outports_steps_remaining = 
522
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_4
523
         then 0
524
         else rlt_eval_microwave_mode_logic_rlt_state_1_outports_steps_remaining);
525

    
526
   
527
   
528
   rlt_eval_microwave_mode_logic_ON_rlt_state_7_states___root = 
529
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_4
530
         then 
531
               (if (not (rlt_eval_microwave_mode_logic_ON_rlt_state_6_states___root = 4))
532
                  then 
533
                        
534
                        4
535
                  else rlt_eval_microwave_mode_logic_ON_rlt_state_6_states___root)
536
         else rlt_eval_microwave_mode_logic_ON_rlt_state_6_states___root);
537
   
538
   
539

    
540
   
541
   
542
   rlt_eval_microwave_mode_logic_ON_rlt_fired_5 = ((rlt_eval_microwave_mode_logic_ON_rlt_state_7_states___root = 2) and 
543
      ((rlt_eval_microwave_mode_logic_ON_rlt_state_6_outports_steps_remaining > 0) and 
544
      (not rlt_eval_microwave_mode_logic_ON_rlt_complete_2)));
545

    
546
   
547
   
548
   rlt_eval_microwave_mode_logic_ON_rlt_state_8_outports_mode = 
549
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_4
550
         then 
551
               (if (not (rlt_eval_microwave_mode_logic_ON_rlt_state_6_states___root = 4))
552
                  then 1
553
                  else rlt_eval_microwave_mode_logic_ON_rlt_state_4_outports_mode)
554
         else rlt_eval_microwave_mode_logic_ON_rlt_state_4_outports_mode);
555

    
556
   
557
   
558
   rlt_eval_microwave_mode_logic_ON_rlt_state_9_states___root = 
559
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_5
560
         then 
561
               (if (rlt_eval_microwave_mode_logic_ON_rlt_state_7_states___root = 2)
562
                  then 
563
                        
564
                        1
565
                  else rlt_eval_microwave_mode_logic_ON_rlt_state_7_states___root)
566
         else rlt_eval_microwave_mode_logic_ON_rlt_state_7_states___root);
567

    
568
   
569
   
570
   rlt_eval_microwave_mode_logic_ON_rlt_state_10_states___root = 
571
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_5
572
         then 
573
               (if (not (rlt_eval_microwave_mode_logic_ON_rlt_state_9_states___root = 2))
574
                  then 
575
                        
576
                        2
577
                  else rlt_eval_microwave_mode_logic_ON_rlt_state_9_states___root)
578
         else rlt_eval_microwave_mode_logic_ON_rlt_state_9_states___root);
579
   
580
   
581

    
582
   
583
   
584
   rlt_eval_microwave_mode_logic_ON_rlt_fired_6 = ((rlt_eval_microwave_mode_logic_ON_rlt_state_10_states___root = 2) and 
585
      ((
586
      (if (chart_microwave_mode_logic_clear_off <> 0)
587
         then true
588
         else false) or 
589
      (not 
590
      (if (chart_microwave_mode_logic_door_closed <> 0)
591
         then true
592
         else false))) and 
593
      (not (rlt_eval_microwave_mode_logic_ON_rlt_fired_5 or 
594
      rlt_eval_microwave_mode_logic_ON_rlt_complete_2))));
595

    
596
   
597
   
598
   rlt_eval_microwave_mode_logic_ON_rlt_state_11_states___root = 
599
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_6
600
         then 
601
               (if (rlt_eval_microwave_mode_logic_ON_rlt_state_10_states___root = 2)
602
                  then 
603
                        
604
                        1
605
                  else rlt_eval_microwave_mode_logic_ON_rlt_state_10_states___root)
606
         else rlt_eval_microwave_mode_logic_ON_rlt_state_10_states___root);
607

    
608
   
609
   
610
   rlt_eval_microwave_mode_logic_ON_rlt_state_11_outports_mode = 
611
      (if rlt_eval_microwave_mode_logic_ON_rlt_fired_5
612
         then 
613
               (if (not (rlt_eval_microwave_mode_logic_ON_rlt_state_9_states___root = 2))
614
                  then 2
615
                  else rlt_eval_microwave_mode_logic_ON_rlt_state_8_outports_mode)
616
         else rlt_eval_microwave_mode_logic_ON_rlt_state_8_outports_mode);
617

    
618
   rlt_enter_microwave_mode_logic_ON_rlt_state_1_states___root = 
619
      (if (not 
620
         
621
         ((rlt_eval_microwave_mode_logic_rlt_state_2_states___root >= 1) and 
622
         (rlt_eval_microwave_mode_logic_rlt_state_2_states___root <= 3)))
623
         then 
624
               
625
               1
626
         else rlt_eval_microwave_mode_logic_rlt_state_2_states___root);
627

    
628
   
629
   
630
   rlt_enter_microwave_mode_logic_ON_rlt_fired_0 = ((not 
631
      
632
      ((rlt_eval_microwave_mode_logic_rlt_state_2_states___root >= 1) and 
633
      (rlt_eval_microwave_mode_logic_rlt_state_2_states___root <= 3))) and 
634
      
635
      
636
      ((rlt_enter_microwave_mode_logic_ON_rlt_state_1_states___root >= 1) and 
637
      (rlt_enter_microwave_mode_logic_ON_rlt_state_1_states___root <= 3)));
638

    
639
   
640
   
641
   rlt_enter_microwave_mode_logic_ON_rlt_fired_1 = (rlt_enter_microwave_mode_logic_ON_rlt_fired_0 and 
642
      (
643
      
644
      ((rlt_enter_microwave_mode_logic_ON_rlt_state_1_states___root >= 1) and 
645
      (rlt_enter_microwave_mode_logic_ON_rlt_state_1_states___root <= 3)) and 
646
      
647
      (if (chart_microwave_mode_logic_door_closed <> 0)
648
         then true
649
         else false)));
650

    
651
   
652
   
653
   rlt_enter_microwave_mode_logic_ON_rlt_state_2_states___root = 
654
      (if rlt_enter_microwave_mode_logic_ON_rlt_fired_1
655
         then 
656
               (if (not (rlt_enter_microwave_mode_logic_ON_rlt_state_1_states___root = 2))
657
                  then 
658
                        
659
                        2
660
                  else rlt_enter_microwave_mode_logic_ON_rlt_state_1_states___root)
661
         else rlt_enter_microwave_mode_logic_ON_rlt_state_1_states___root);
662
   
663
   
664

    
665
   
666
   
667
   rlt_enter_microwave_mode_logic_ON_rlt_state_2_outports_mode = 
668
      (if rlt_enter_microwave_mode_logic_ON_rlt_fired_1
669
         then 
670
               (if (not (rlt_enter_microwave_mode_logic_ON_rlt_state_1_states___root = 2))
671
                  then 2
672
                  else chart_microwave_mode_logic_begin_state_outports_mode)
673
         else chart_microwave_mode_logic_begin_state_outports_mode);
674
   
675
   
676

    
677
   
678
   
679
   rlt_enter_microwave_mode_logic_ON_rlt_fired_2 = (rlt_enter_microwave_mode_logic_ON_rlt_fired_0 and 
680
      (
681
      
682
      ((rlt_enter_microwave_mode_logic_ON_rlt_state_2_states___root >= 1) and 
683
      (rlt_enter_microwave_mode_logic_ON_rlt_state_2_states___root <= 3)) and 
684
      (not rlt_enter_microwave_mode_logic_ON_rlt_fired_1)));
685

    
686
   
687
   
688
   rlt_enter_microwave_mode_logic_ON_rlt_state_4_states___root = 
689
      (if rlt_enter_microwave_mode_logic_ON_rlt_fired_2
690
         then 
691
               (if (not (rlt_enter_microwave_mode_logic_ON_rlt_state_2_states___root = 3))
692
                  then 
693
                        
694
                        3
695
                  else rlt_enter_microwave_mode_logic_ON_rlt_state_2_states___root)
696
         else rlt_enter_microwave_mode_logic_ON_rlt_state_2_states___root);
697
   
698
   
699

    
700
   
701
   
702
   rlt_enter_microwave_mode_logic_rlt_state_2_states___root = 
703
      (if (not (chart_microwave_mode_logic_begin_state_states___root = 4))
704
         then 
705
               
706
               4
707
         else chart_microwave_mode_logic_begin_state_states___root);
708
   
709
   
710

    
711
   microwave_microwave_mode_logic_mode = chart_microwave_mode_logic_mode;
712

    
713

    
714
   MWI_FcnMaxI_In13 = ((pre rlt__Arrow5) - 1);
715

    
716

    
717
   rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_clock = enable;
718

    
719
   KP_01 = KP_0;
720

    
721
   KP_11 = KP_1;
722

    
723
   KP_21 = KP_2;
724

    
725
   KP_31 = KP_3;
726

    
727
   KP_41 = KP_4;
728

    
729
   KP_51 = KP_5;
730

    
731
   KP_61 = KP_6;
732

    
733
   KP_71 = KP_7;
734

    
735
   KP_81 = KP_8;
736

    
737
   KP_91 = KP_9;
738

    
739
   microwave_microwave_KEYPAD_PROCESSING_DISPLAY_LEFT_DIGIT_DIGIT_TO_DISPLAY = (0 -> 
740
      (if rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_clock
741
         then 
742
               (if rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_init_step
743
                  then 0
744
                  else 
745
               (if KP_CLEAR
746
                  then 0
747
                  else 
748
               (if 
749
                  (if (
750
                     (if (KP_01 and 
751
                        (not (pre KP_01)))
752
                        then 0
753
                        else 
754
                     (if (KP_11 and 
755
                        (not (pre KP_11)))
756
                        then 1
757
                        else 
758
                     (if (KP_21 and 
759
                        (not (pre KP_21)))
760
                        then 2
761
                        else 
762
                     (if (KP_31 and 
763
                        (not (pre KP_31)))
764
                        then 3
765
                        else 
766
                     (if (KP_41 and 
767
                        (not (pre KP_41)))
768
                        then 4
769
                        else 
770
                     (if (KP_51 and 
771
                        (not (pre KP_51)))
772
                        then 5
773
                        else 
774
                     (if (KP_61 and 
775
                        (not (pre KP_61)))
776
                        then 6
777
                        else 
778
                     (if (KP_71 and 
779
                        (not (pre KP_71)))
780
                        then 7
781
                        else 
782
                     (if (KP_81 and 
783
                        (not (pre KP_81)))
784
                        then 8
785
                        else 
786
                     (if (KP_91 and 
787
                        (not (pre KP_91)))
788
                        then 9
789
                        else 10)))))))))) <= 9)
790
                     then true
791
                     else false)
792
                  then (pre microwave_microwave_KEYPAD_PROCESSING_DISPLAY_MIDDLE_DIGIT_DIGIT_TO_DISPLAY)
793
                  else (pre microwave_microwave_KEYPAD_PROCESSING_DISPLAY_LEFT_DIGIT_DIGIT_TO_DISPLAY))))
794
         else (pre microwave_microwave_KEYPAD_PROCESSING_DISPLAY_LEFT_DIGIT_DIGIT_TO_DISPLAY)));
795

    
796
   microwave_microwave_KEYPAD_PROCESSING_DISPLAY_MIDDLE_DIGIT_DIGIT_TO_DISPLAY = (0 -> 
797
      (if rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_clock
798
         then 
799
               (if rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_init_step
800
                  then 0
801
                  else 
802
               (if KP_CLEAR
803
                  then 0
804
                  else 
805
               (if 
806
                  (if (
807
                     (if (KP_01 and 
808
                        (not (pre KP_01)))
809
                        then 0
810
                        else 
811
                     (if (KP_11 and 
812
                        (not (pre KP_11)))
813
                        then 1
814
                        else 
815
                     (if (KP_21 and 
816
                        (not (pre KP_21)))
817
                        then 2
818
                        else 
819
                     (if (KP_31 and 
820
                        (not (pre KP_31)))
821
                        then 3
822
                        else 
823
                     (if (KP_41 and 
824
                        (not (pre KP_41)))
825
                        then 4
826
                        else 
827
                     (if (KP_51 and 
828
                        (not (pre KP_51)))
829
                        then 5
830
                        else 
831
                     (if (KP_61 and 
832
                        (not (pre KP_61)))
833
                        then 6
834
                        else 
835
                     (if (KP_71 and 
836
                        (not (pre KP_71)))
837
                        then 7
838
                        else 
839
                     (if (KP_81 and 
840
                        (not (pre KP_81)))
841
                        then 8
842
                        else 
843
                     (if (KP_91 and 
844
                        (not (pre KP_91)))
845
                        then 9
846
                        else 10)))))))))) <= 9)
847
                     then true
848
                     else false)
849
                  then (pre microwave_microwave_KEYPAD_PROCESSING_DISPLAY_RIGHT_DIGIT_DIGIT_TO_DISPLAY)
850
                  else (pre microwave_microwave_KEYPAD_PROCESSING_DISPLAY_MIDDLE_DIGIT_DIGIT_TO_DISPLAY))))
851
         else (pre microwave_microwave_KEYPAD_PROCESSING_DISPLAY_MIDDLE_DIGIT_DIGIT_TO_DISPLAY)));
852

    
853
   microwave_microwave_KEYPAD_PROCESSING_DISPLAY_RIGHT_DIGIT_DIGIT_TO_DISPLAY = (
854
      (if KP_CLEAR
855
         then 0
856
         else 
857
      (if 
858
         (if (
859
            (if KP_01
860
               then 0
861
               else 
862
            (if KP_11
863
               then 1
864
               else 
865
            (if KP_21
866
               then 2
867
               else 
868
            (if KP_31
869
               then 3
870
               else 
871
            (if KP_41
872
               then 4
873
               else 
874
            (if KP_51
875
               then 5
876
               else 
877
            (if KP_61
878
               then 6
879
               else 
880
            (if KP_71
881
               then 7
882
               else 
883
            (if KP_81
884
               then 8
885
               else 
886
            (if KP_91
887
               then 9
888
               else 10)))))))))) <= 9)
889
            then true
890
            else false)
891
         then 
892
               (if KP_01
893
                  then 0
894
                  else 
895
               (if KP_11
896
                  then 1
897
                  else 
898
               (if KP_21
899
                  then 2
900
                  else 
901
               (if KP_31
902
                  then 3
903
                  else 
904
               (if KP_41
905
                  then 4
906
                  else 
907
               (if KP_51
908
                  then 5
909
                  else 
910
               (if KP_61
911
                  then 6
912
                  else 
913
               (if KP_71
914
                  then 7
915
                  else 
916
               (if KP_81
917
                  then 8
918
                  else 
919
               (if KP_91
920
                  then 9
921
                  else 10))))))))))
922
         else 0)) -> 
923
      (if rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_clock
924
         then 
925
               (if rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_init_step
926
                  then 
927
                        (if KP_CLEAR
928
                           then 0
929
                           else 
930
                        (if 
931
                           (if (
932
                              (if KP_01
933
                                 then 0
934
                                 else 
935
                              (if KP_11
936
                                 then 1
937
                                 else 
938
                              (if KP_21
939
                                 then 2
940
                                 else 
941
                              (if KP_31
942
                                 then 3
943
                                 else 
944
                              (if KP_41
945
                                 then 4
946
                                 else 
947
                              (if KP_51
948
                                 then 5
949
                                 else 
950
                              (if KP_61
951
                                 then 6
952
                                 else 
953
                              (if KP_71
954
                                 then 7
955
                                 else 
956
                              (if KP_81
957
                                 then 8
958
                                 else 
959
                              (if KP_91
960
                                 then 9
961
                                 else 10)))))))))) <= 9)
962
                              then true
963
                              else false)
964
                           then 
965
                                 (if KP_01
966
                                    then 0
967
                                    else 
968
                                 (if KP_11
969
                                    then 1
970
                                    else 
971
                                 (if KP_21
972
                                    then 2
973
                                    else 
974
                                 (if KP_31
975
                                    then 3
976
                                    else 
977
                                 (if KP_41
978
                                    then 4
979
                                    else 
980
                                 (if KP_51
981
                                    then 5
982
                                    else 
983
                                 (if KP_61
984
                                    then 6
985
                                    else 
986
                                 (if KP_71
987
                                    then 7
988
                                    else 
989
                                 (if KP_81
990
                                    then 8
991
                                    else 
992
                                 (if KP_91
993
                                    then 9
994
                                    else 10))))))))))
995
                           else 0))
996
                  else 
997
               (if KP_CLEAR
998
                  then 0
999
                  else 
1000
               (if 
1001
                  (if (
1002
                     (if (KP_01 and 
1003
                        (not (pre KP_01)))
1004
                        then 0
1005
                        else 
1006
                     (if (KP_11 and 
1007
                        (not (pre KP_11)))
1008
                        then 1
1009
                        else 
1010
                     (if (KP_21 and 
1011
                        (not (pre KP_21)))
1012
                        then 2
1013
                        else 
1014
                     (if (KP_31 and 
1015
                        (not (pre KP_31)))
1016
                        then 3
1017
                        else 
1018
                     (if (KP_41 and 
1019
                        (not (pre KP_41)))
1020
                        then 4
1021
                        else 
1022
                     (if (KP_51 and 
1023
                        (not (pre KP_51)))
1024
                        then 5
1025
                        else 
1026
                     (if (KP_61 and 
1027
                        (not (pre KP_61)))
1028
                        then 6
1029
                        else 
1030
                     (if (KP_71 and 
1031
                        (not (pre KP_71)))
1032
                        then 7
1033
                        else 
1034
                     (if (KP_81 and 
1035
                        (not (pre KP_81)))
1036
                        then 8
1037
                        else 
1038
                     (if (KP_91 and 
1039
                        (not (pre KP_91)))
1040
                        then 9
1041
                        else 10)))))))))) <= 9)
1042
                     then true
1043
                     else false)
1044
                  then 
1045
                        (if (KP_01 and 
1046
                           (not (pre KP_01)))
1047
                           then 0
1048
                           else 
1049
                        (if (KP_11 and 
1050
                           (not (pre KP_11)))
1051
                           then 1
1052
                           else 
1053
                        (if (KP_21 and 
1054
                           (not (pre KP_21)))
1055
                           then 2
1056
                           else 
1057
                        (if (KP_31 and 
1058
                           (not (pre KP_31)))
1059
                           then 3
1060
                           else 
1061
                        (if (KP_41 and 
1062
                           (not (pre KP_41)))
1063
                           then 4
1064
                           else 
1065
                        (if (KP_51 and 
1066
                           (not (pre KP_51)))
1067
                           then 5
1068
                           else 
1069
                        (if (KP_61 and 
1070
                           (not (pre KP_61)))
1071
                           then 6
1072
                           else 
1073
                        (if (KP_71 and 
1074
                           (not (pre KP_71)))
1075
                           then 7
1076
                           else 
1077
                        (if (KP_81 and 
1078
                           (not (pre KP_81)))
1079
                           then 8
1080
                           else 
1081
                        (if (KP_91 and 
1082
                           (not (pre KP_91)))
1083
                           then 9
1084
                           else 10))))))))))
1085
                  else (pre microwave_microwave_KEYPAD_PROCESSING_DISPLAY_RIGHT_DIGIT_DIGIT_TO_DISPLAY))))
1086
         else (pre microwave_microwave_KEYPAD_PROCESSING_DISPLAY_RIGHT_DIGIT_DIGIT_TO_DISPLAY)));
1087

    
1088
   STEPS_TO_COOK = (
1089
      (if (rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_init_step and 
1090
         (not rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_clock))
1091
         then 0
1092
         else ((((microwave_microwave_KEYPAD_PROCESSING_DISPLAY_RIGHT_DIGIT_DIGIT_TO_DISPLAY * 1) + (microwave_microwave_KEYPAD_PROCESSING_DISPLAY_MIDDLE_DIGIT_DIGIT_TO_DISPLAY * 10)) + (microwave_microwave_KEYPAD_PROCESSING_DISPLAY_LEFT_DIGIT_DIGIT_TO_DISPLAY * 60)) * 1)) -> 
1093
      (if (rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_init_step and 
1094
         (not rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_clock))
1095
         then 0
1096
         else 
1097
      (if rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_clock
1098
         then ((((microwave_microwave_KEYPAD_PROCESSING_DISPLAY_RIGHT_DIGIT_DIGIT_TO_DISPLAY * 1) + (microwave_microwave_KEYPAD_PROCESSING_DISPLAY_MIDDLE_DIGIT_DIGIT_TO_DISPLAY * 10)) + (microwave_microwave_KEYPAD_PROCESSING_DISPLAY_LEFT_DIGIT_DIGIT_TO_DISPLAY * 60)) * 1)
1099
         else (pre STEPS_TO_COOK))));
1100

    
1101
   rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_init_step = (true -> 
1102
      (if (not rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_clock)
1103
         then true
1104
         else 
1105
      (if (pre rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_clock)
1106
         then false
1107
         else (pre rlt_condact_resetmicrowave_microwave_KEYPAD_PROCESSING_rlt_init_step))));
1108

    
1109
   SETUP = 
1110
      (if (1 = microwave_microwave_mode_logic_mode)
1111
         then true
1112
         else false);
1113

    
1114
   enable = (true -> 
1115
      (if (1 = (pre microwave_microwave_mode_logic_mode))
1116
         then true
1117
         else false));
1118

    
1119

    
1120

    
1121

    
1122

    
1123

    
1124
  --%PROPERTY OK=true;
1125
  --%MAIN;
1126

    
1127
tel
1128