/******************************************************************************

             File generated by Beologic visualSTATE Classic Matrix Designer
                               Version 3.01
                           Thu Jul 03 14:10:43 1997

******************************************************************************/

#STATEEVENT

/*$@
#FONT          0, 0, 10
#SIZE          0, 0, 804, 576
#COLORS        0X00FF00, 0XC0C0C0, 0X00FFFF, 0XFF00FF
#LEFTTEXT      0
#PRINTER       0
#PRINT         0, 79, 65, 0
#POST          0, 11.67, 8.25, 0, 1.00, 0, 1, 1, 0.60, 0.60, 0.75, 0.75
#PRINTPROCESS  "net print $1 lpt1:"
#COMPRESS      1
$*/

SE_INPUT
  CD;
  Key_0_Pressed;
  Key_1_Pressed;
  Key_2_Pressed;
  Key_3_Pressed;
  Key_4_Pressed;
  Key_5_Pressed;
  Key_6_Pressed;
  Key_7_Pressed;
  Key_8_Pressed;
  Key_9_Pressed;
  Lead_Out;
  OFF;
  P;
  PLAY;
  RANDOM;
  REPEAT;
  Random_Done;
  SE_RESET;
  Slut_info;
  Start_info;
  Start_musik;
  Timeout_1;
  Timeout_1800;
  Timeout_2;
  Timeout_3;
  NotOk;
  TILBAGE;
  FREM;
  SPOL_FREM;
  SPOL_TILBAGE;
  DISPLAY;
  Timeout_4;
  MUTE;
  PAUSE;

SE_INPUTGROUP
  Key_pressed (Key_0_Pressed, Key_1_Pressed, Key_2_Pressed, Key_3_Pressed,
    Key_4_Pressed, Key_5_Pressed, Key_7_Pressed, Key_6_Pressed,
    Key_8_Pressed, Key_9_Pressed);
  Random_Repeat (RANDOM, REPEAT);

SE_STATE
  CD_End;
  Key_1;
  Key_10;
  Key_11;
  Key_12;
  Key_13;
  Key_14;
  Key_15;
  Key_16;
  Key_17;
  Key_18;
  Key_19;
  Random_off;
  Random_on;
  Repeat_off;
  Repeat_on;
  Spinning;
  Stand_By;
  Stand_by_Key1;
  Time;
  Time3;
  Time3_reset;
  Time_reset;
  Key_2;
  Key_20;
  Key_21;
  Key_22;
  Key_23;
  Key_24;
  Key_25;
  Key_26;
  Key_27;
  Key_28;
  Key_29;
  Stand_by_Key2;
  Key_3;
  Key_30;
  Key_31;
  Key_32;
  Key_33;
  Key_34;
  Key_35;
  Key_36;
  Key_37;
  Key_38;
  Key_39;
  Stand_by_Key3;
  Key_0;
  Key_01;
  Key_02;
  Key_03;
  Key_04;
  Key_05;
  Key_06;
  Key_07;
  Key_08;
  Key_09;
  Stand_by_Key0;
  Reset_K_0;
  Reset_K_1;
  Reset_K_2;
  Reset_K_3;
  Reset_T_1;
  Reset_T_3;
  Time1800;
  Time2;
  Time2_reset;
  Time_1800_Reset;
  Reset_T_1800;
  Reset_T_2;
  Random_reset;
  Repeat_reset;
  Forward_reset;
  Forward_ready;
  Rewind_reset;
  Rewind_ready;
  Spoler_frem;
  Spoler_tilbage;
  Time_nr;
  Time_total;
  Cd_nr;
  Disp_ready;
  Pause_cd;
  Mute_cd;
  Time4_reset;
  Time4;
  Reset_T_4;

SE_STATEGROUP
  Main (Stand_By, Spinning, Spoler_frem, Spoler_tilbage, Pause_cd, Mute_cd,
    CD_End)
    /*$$MSGPOS0 98 0 8 0 9 0 0 800 35 505 1$*/;
  Forward (Forward_reset, Forward_ready)
    /*$$MSGPOS0 100 0 0 -1 -1 0 400 800 35 191 1$*/;
  Rewind (Rewind_reset, Rewind_ready)
    /*$$MSGPOS0 100 0 0 -1 -1 0 0 400 346 504 1$*/;
  T_4 (Reset_T_4, Time4_reset, Time4)
    /*$$MSGPOS0 100 3 2 -1 -1 0 0 400 191 347 1$*/;
  K_1 (Stand_by_Key1, Reset_K_1, Key_1, Key_11, Key_10, Key_12, Key_13,
    Key_14, Key_15, Key_16, Key_17, Key_18, Key_19)
    /*$$MSGPOS0 100 8 13 -1 -1 0 532 800 221 314 1$*/;
  Random_Control (Random_reset, Random_off, Random_on)
    /*$$MSGPOS0 100 0 4 -1 -1 0 0 266 152 269 1$*/;
  T_3 (Reset_T_3, Time3_reset, Time3)
    /*$$MSGPOS0 100 0 0 -1 -1 0 0 800 35 505 1$*/;
  Repeat_Control (Repeat_reset, Repeat_off, Repeat_on)
    /*$$MSGPOS0 100 0 0 -1 -1 0 0 160 481 505 1$*/;
  T_1 (Reset_T_1, Time, Time_reset)
    /*$$MSGPOS0 100 0 3 -1 -1 0 532 800 35 128 1$*/;
  K_2 (Stand_by_Key2, Reset_K_2, Key_2, Key_21, Key_20, Key_22, Key_23,
    Key_24, Key_25, Key_26, Key_27, Key_28, Key_29)
    /*$$MSGPOS0 100 3 9 -1 -1 0 266 532 407 505 1$*/;
  K_3 (Reset_K_3, Stand_by_Key3, Key_3, Key_31, Key_30, Key_32, Key_33,
    Key_34, Key_35, Key_36, Key_37, Key_38, Key_39)
    /*$$MSGPOS0 100 0 2 -1 -1 0 0 266 386 505 1$*/;
  K_0 (Reset_K_0, Stand_by_Key0, Key_0, Key_01, Key_02, Key_03, Key_04,
    Key_05, Key_06, Key_07, Key_08, Key_09)
    /*$$MSGPOS0 100 0 2 -1 -1 0 266 532 314 407 1$*/;
  T_1800 (Reset_T_1800, Time_1800_Reset, Time1800)
    /*$$MSGPOS0 100 1 2 -1 -1 1 266 532 221 314 1$*/;
  T_2 (Reset_T_2, Time2_reset, Time2)
    /*$$MSGPOS0 100 0 0 -1 -1 0 266 532 128 221 1$*/;
  Disp (Disp_ready, Cd_nr, Time_nr, Time_total)
    /*$$MSGPOS0 100 4 0 -1 -1 -1 400 800 191 347 1$*/;

SE_OUTPUT
  Display_1;
  Display_10;
  Display_11;
  Display_12;
  Display_13;
  Display_14;
  Display_15;
  Display_16;
  Display_17;
  Display_18;
  Display_19;
  Display_OFF;
  Display_ON;
  Display_SIGN;
  Display_UNKNOWN;
  Display__1;
  Goto_1;
  Goto_10;
  Goto_11;
  Goto_12;
  Goto_13;
  Goto_14;
  Goto_15;
  Goto_16;
  Goto_17;
  Goto_18;
  Goto_19;
  Goto_Random;
  Laes_streng;
  Musik_ud;
  Musik_ud_stop;
  Next_P;
  Prev_P;
  Start_laser;
  Start_motor;
  Stop_laser;
  Stop_motor;
  Time_1;
  Time_1800;
  Time_2;
  Time_3;
  Display_3;
  Display_4;
  Display_5;
  Display_6;
  Display_7;
  Display_8;
  Display_9;
  Display_20;
  Display_21;
  Display_22;
  Display_23;
  Display_24;
  Display_25;
  Display_26;
  Display_27;
  Display_28;
  Display_29;
  Display_30;
  Display_31;
  Display_32;
  Display_33;
  Display__2;
  Display_2;
  Display__3;
  Display__4;
  Display__5;
  Display__6;
  Display__7;
  Display__8;
  Display__9;
  Goto_2;
  Goto_21;
  Goto_22;
  Goto_23;
  Goto_24;
  Goto_25;
  Goto_26;
  Goto_27;
  Goto_28;
  Goto_29;
  Goto_30;
  Goto_31;
  Goto_32;
  Goto_33;
  Goto_20;
  Display_34;
  Display_35;
  Display_36;
  Display_37;
  Display_38;
  Display_39;
  Display_40;
  Display_41;
  Display_42;
  Display_43;
  Display_44;
  Display_45;
  Display_46;
  Display_47;
  Display_48;
  Display_49;
  Goto_3;
  Goto_34;
  Goto_35;
  Goto_36;
  Goto_37;
  Goto_38;
  Goto_39;
  Display__0;
  Goto_9;
  Goto_8;
  Goto_7;
  Goto_6;
  Goto_5;
  Goto_4;
  Goto_next;
  Inc_display;
  Dec_display;
  Goto_prev;
  Goto_nr_start;
  Laser_forward;
  Laser_reverse;
  Laser_normal;
  Get_time;
  Get_time_left;
  Get_nr;
  Time_4;
  Laser_hold;
  Display_last_disp;
  Display_Nothing;

  /*$$MNCSPOS0 100 0 -1 -1 0 0 219 35 303$*/

SE_RULE        /* Rules from Main */

  SE_RESET : Stand_By
    /*$$MCOND0 Main @ 0 100 **$*/;
  CD Stand_By : Spinning Random_off Repeat_off Start_laser Start_motor
    /*$$MCOND0 Main Stand_By 1 100 **$*/;
  Start_info Spinning : Laes_streng
    /*$$MCOND0 Main Spinning 2 100 **$*/;
  Start_musik Spinning : Musik_ud Display_1
    /*$$MCOND0 Main Spinning 3 100 **$*/;
  PLAY Spoler_frem : Spinning Laser_normal
    /*$$MCOND0 Main Spoler_frem 4 100 **$*/;
  PLAY Spoler_tilbage : Spinning Laser_normal
    /*$$MCOND0 Main Spoler_tilbage 4 100 **$*/;
  PLAY Pause_cd : Spinning Laser_normal Musik_ud
    /*$$MCOND0 Main Pause_cd 4 100 **$*/;
  PLAY CD_End : Spinning Start_motor Start_laser
    /*$$MCOND0 Main CD_End 4 100 **$*/;
  SPOL_FREM Spinning : Spoler_frem Laser_forward
    /*$$MCOND0 Main Spinning 5 100 **$*/;
  SPOL_TILBAGE Spinning : Spoler_tilbage Laser_reverse
    /*$$MCOND0 Main Spinning 6 100 **$*/;
  PAUSE Spinning : Pause_cd Musik_ud_stop Laser_hold
    /*$$MCOND0 Main Spinning 7 100 **$*/;
  PAUSE Pause_cd : Spinning Laser_normal Musik_ud
    /*$$MCOND0 Main Pause_cd 7 100 **$*/;
  MUTE Spinning : Mute_cd Musik_ud_stop
    /*$$MCOND0 Main Spinning 8 100 **$*/;
  MUTE Mute_cd : Spinning Musik_ud
    /*$$MCOND0 Main Mute_cd 8 100 **$*/;
  OFF : Display_Nothing
    /*$$MCOND0 Main @ 9 117 **$*/;
  OFF Spinning : Stand_By Musik_ud_stop Stop_laser Stop_motor
    /*$$MCOND0 Main Spinning 9 117 **$*/;
  Lead_Out Random_off Repeat_off Spinning : CD_End Display_SIGN Time_1800
    Musik_ud_stop Stop_motor Stop_laser
    /*$$MCOND0 Main Spinning 10 100 **$*/;
  Timeout_1800 CD_End : Stand_By Display_Nothing
    /*$$MCOND0 Main CD_End 11 116 **$*/;
  Random_Done Repeat_off Spinning : CD_End Time_1800 Musik_ud_stop
    Stop_motor Stop_laser Display_SIGN
    /*$$MCOND0 Main Spinning 12 100 **$*/;

SE_RULE        /* Rules from Forward */

  SE_RESET : Forward_reset
    /*$$MCOND0 Forward @ 0 100 **$*/;
  CD Forward_reset : Forward_ready
    /*$$MCOND0 Forward Forward_reset 1 100 **$*/;
  NotOk : Forward_ready
    /*$$MCOND0 Forward @ 2 100 **$*/;
  FREM Forward_ready : Goto_next Inc_display
    /*$$MCOND0 Forward Forward_ready 3 100 **$*/;

SE_RULE        /* Rules from Rewind */

  SE_RESET : Rewind_reset
    /*$$MCOND0 Rewind @ 0 100 **$*/;
  CD Rewind_reset : Rewind_ready
    /*$$MCOND0 Rewind Rewind_reset 1 100 **$*/;
  NotOk : Rewind_ready
    /*$$MCOND0 Rewind @ 2 100 **$*/;
  TILBAGE Time_reset Rewind_ready : Goto_nr_start
    /*$$MCOND0 Rewind Rewind_ready 3 100 **$*/;
  TILBAGE Time Rewind_ready : Goto_prev Dec_display
    /*$$MCOND0 Rewind Rewind_ready 4 100 **$*/;

SE_RULE        /* Rules from T_4 */

  SE_RESET : Reset_T_4
    /*$$MCOND0 T_4 @ 0 100 **$*/;
  CD Reset_T_4 : Time4_reset
    /*$$MCOND0 T_4 Reset_T_4 1 100 **$*/;
  NotOk Time4_reset : Time4 Time_4
    /*$$MCOND0 T_4 Time4_reset 2 100 **$*/;
  Timeout_4 Time4 : Time4_reset Display_last_disp
    /*$$MCOND0 T_4 Time4 3 126 **$*/;

SE_RULE        /* Rules from K_1 */

  SE_RESET : Reset_K_1
    /*$$MCOND0 K_1 @ 0 100 **$*/;
  CD Reset_K_1 : Stand_by_Key1
    /*$$MCOND0 K_1 Reset_K_1 1 100 **$*/;
  NotOk : Stand_by_Key1
    /*$$MCOND0 K_1 @ 2 100 **$*/;
  Key_1_Pressed !Key_0 !Key_2 !Key_3 Stand_by_Key1 : Key_1 Display__1
    /*$$MCOND0 K_1 Stand_by_Key1 3 100 **$*/;
  Key_1_Pressed !Key_0 !Key_2 !Key_3 Key_1 : Key_11 Display_11
    /*$$MCOND0 K_1 Key_1 3 100 **$*/;
  Key_0_Pressed Key_1 : Key_10 Display_10
    /*$$MCOND0 K_1 Key_1 4 100 **$*/;
  Key_2_Pressed Key_1 : Key_12 Display_12
    /*$$MCOND0 K_1 Key_1 5 100 **$*/;
  Key_3_Pressed Key_1 : Key_13 Display_13
    /*$$MCOND0 K_1 Key_1 6 100 **$*/;
  Key_4_Pressed Key_1 : Key_14 Display_14
    /*$$MCOND0 K_1 Key_1 7 100 **$*/;
  Key_5_Pressed Key_1 : Key_15 Display_15
    /*$$MCOND0 K_1 Key_1 8 100 **$*/;
  Key_6_Pressed Key_1 : Key_16 Display_16
    /*$$MCOND0 K_1 Key_1 9 100 **$*/;
  Key_7_Pressed Key_1 : Key_17 Display_17
    /*$$MCOND0 K_1 Key_1 10 100 **$*/;
  Key_8_Pressed Key_1 : Key_18 Display_18
    /*$$MCOND0 K_1 Key_1 11 100 **$*/;
  Key_9_Pressed Key_1 : Key_19 Display_19
    /*$$MCOND0 K_1 Key_1 12 100 **$*/;
  Timeout_2 Key_1 : Stand_by_Key1 Display_1 Goto_1
    /*$$MCOND0 K_1 Key_1 13 100 **$*/;
  Timeout_2 Key_11 : Stand_by_Key1 Display_11 Goto_11
    /*$$MCOND0 K_1 Key_11 13 100 **$*/;
  Timeout_2 Key_10 : Stand_by_Key1 Display_10 Goto_10
    /*$$MCOND0 K_1 Key_10 13 100 **$*/;
  Timeout_2 Key_12 : Stand_by_Key1 Display_12 Goto_12
    /*$$MCOND0 K_1 Key_12 13 100 **$*/;
  Timeout_2 Key_13 : Stand_by_Key1 Display_13 Goto_13
    /*$$MCOND0 K_1 Key_13 13 100 **$*/;
  Timeout_2 Key_14 : Stand_by_Key1 Display_14 Goto_14
    /*$$MCOND0 K_1 Key_14 13 100 **$*/;
  Timeout_2 Key_15 : Stand_by_Key1 Display_15 Goto_15
    /*$$MCOND0 K_1 Key_15 13 100 **$*/;
  Timeout_2 Key_16 : Stand_by_Key1 Display_16 Goto_16
    /*$$MCOND0 K_1 Key_16 13 100 **$*/;
  Timeout_2 Key_17 : Stand_by_Key1 Display_17 Goto_17
    /*$$MCOND0 K_1 Key_17 13 100 **$*/;
  Timeout_2 Key_18 : Stand_by_Key1 Display_18 Goto_18
    /*$$MCOND0 K_1 Key_18 13 100 **$*/;
  Timeout_2 Key_19 : Stand_by_Key1 Display_19 Goto_19
    /*$$MCOND0 K_1 Key_19 13 100 **$*/;
  PLAY Key_1 : Stand_by_Key1 Display_1 Goto_1
    /*$$MCOND0 K_1 Key_1 14 100 **$*/;
  PLAY Key_11 : Stand_by_Key1 Display_11 Goto_11
    /*$$MCOND0 K_1 Key_11 14 100 **$*/;
  PLAY Key_10 : Stand_by_Key1 Display_10 Goto_10
    /*$$MCOND0 K_1 Key_10 14 100 **$*/;
  PLAY Key_12 : Stand_by_Key1 Display_12 Goto_12
    /*$$MCOND0 K_1 Key_12 14 100 **$*/;
  PLAY Key_13 : Stand_by_Key1 Display_13 Goto_13
    /*$$MCOND0 K_1 Key_13 14 100 **$*/;
  PLAY Key_14 : Stand_by_Key1 Display_14 Goto_14
    /*$$MCOND0 K_1 Key_14 14 100 **$*/;
  PLAY Key_15 : Stand_by_Key1 Display_15 Goto_15
    /*$$MCOND0 K_1 Key_15 14 100 **$*/;
  PLAY Key_16 : Stand_by_Key1 Display_16 Goto_16
    /*$$MCOND0 K_1 Key_16 14 100 **$*/;
  PLAY Key_17 : Stand_by_Key1 Display_17 Goto_17
    /*$$MCOND0 K_1 Key_17 14 100 **$*/;
  PLAY Key_18 : Stand_by_Key1 Display_18 Goto_18
    /*$$MCOND0 K_1 Key_18 14 100 **$*/;
  PLAY Key_19 : Stand_by_Key1 Display_19 Goto_19
    /*$$MCOND0 K_1 Key_19 14 100 **$*/;

SE_RULE        /* Rules from Random_Control */

  SE_RESET : Random_reset
    /*$$MCOND0 Random_Control @ 0 100 **$*/;
  CD Random_reset : Random_off
    /*$$MCOND0 Random_Control Random_reset 1 100 **$*/;
  RANDOM Time3_reset Random_off : Display_OFF
    /*$$MCOND0 Random_Control Random_off 2 100 **$*/;
  RANDOM Time3_reset Random_on : Display_ON
    /*$$MCOND0 Random_Control Random_on 2 100 **$*/;
  RANDOM !Time3_reset Random_off : Random_on Display_ON
    /*$$MCOND0 Random_Control Random_off 3 100 **$*/;
  RANDOM !Time3_reset Random_on : Random_off Display_OFF
    /*$$MCOND0 Random_Control Random_on 3 100 **$*/;
  Random_Done Repeat_on Random_on : Goto_Random
    /*$$MCOND0 Random_Control Random_on 4 100 **$*/;

SE_RULE        /* Rules from T_3 */

  SE_RESET : Reset_T_3
    /*$$MCOND0 T_3 @ 0 100 **$*/;
  CD Reset_T_3 : Time3_reset
    /*$$MCOND0 T_3 Reset_T_3 1 100 **$*/;
  Random_Repeat Time3_reset : Time3 Time_3
    /*$$MCOND0 T_3 Time3_reset 2 100 **$*/;
  Timeout_3 Time3 : Time3_reset Display_last_disp
    /*$$MCOND0 T_3 Time3 3 126 **$*/;

SE_RULE        /* Rules from Repeat_Control */

  SE_RESET : Repeat_reset
    /*$$MCOND0 Repeat_Control @ 0 100 **$*/;
  CD Repeat_reset : Repeat_off
    /*$$MCOND0 Repeat_Control Repeat_reset 1 100 **$*/;
  REPEAT Time3_reset Repeat_off : Display_OFF
    /*$$MCOND0 Repeat_Control Repeat_off 2 100 **$*/;
  REPEAT Time3_reset Repeat_on : Display_ON
    /*$$MCOND0 Repeat_Control Repeat_on 2 100 **$*/;
  REPEAT !Time3_reset Repeat_off : Repeat_on Display_ON
    /*$$MCOND0 Repeat_Control Repeat_off 3 100 **$*/;
  REPEAT !Time3_reset Repeat_on : Repeat_off Display_OFF
    /*$$MCOND0 Repeat_Control Repeat_on 3 100 **$*/;
  Lead_Out Random_off Repeat_on : Goto_1
    /*$$MCOND0 Repeat_Control Repeat_on 4 100 **$*/;

SE_RULE        /* Rules from T_1 */

  SE_RESET : Reset_T_1
    /*$$MCOND0 T_1 @ 0 100 **$*/;
  CD Reset_T_1 : Time_reset
    /*$$MCOND0 T_1 Reset_T_1 1 100 **$*/;
  Timeout_1 Time : Time_reset
    /*$$MCOND0 T_1 Time 2 100 **$*/;
  TILBAGE Time_reset : Time Time_1
    /*$$MCOND0 T_1 Time_reset 3 100 **$*/;

SE_RULE        /* Rules from K_2 */

  SE_RESET : Reset_K_2
    /*$$MCOND0 K_2 @ 0 100 **$*/;
  CD Reset_K_2 : Stand_by_Key2
    /*$$MCOND0 K_2 Reset_K_2 1 100 **$*/;
  NotOk : Stand_by_Key2
    /*$$MCOND0 K_2 @ 2 100 **$*/;
  Key_1_Pressed Key_2 : Key_21 Display_21
    /*$$MCOND0 K_2 Key_2 3 100 **$*/;
  Key_0_Pressed Key_2 : Key_20 Display_20
    /*$$MCOND0 K_2 Key_2 4 100 **$*/;
  Key_2_Pressed !Key_0 !Key_1 !Key_3 Stand_by_Key2 : Key_2 Display__2
    /*$$MCOND0 K_2 Stand_by_Key2 5 100 **$*/;
  Key_2_Pressed !Key_0 !Key_1 !Key_3 Key_2 : Key_22 Display_22
    /*$$MCOND0 K_2 Key_2 5 100 **$*/;
  Key_3_Pressed Key_2 : Key_23 Display_23
    /*$$MCOND0 K_2 Key_2 6 100 **$*/;
  Key_4_Pressed Key_2 : Key_24 Display_24
    /*$$MCOND0 K_2 Key_2 7 100 **$*/;
  Key_5_Pressed Key_2 : Key_25 Display_25
    /*$$MCOND0 K_2 Key_2 8 100 **$*/;
  Key_6_Pressed Key_2 : Key_26 Display_26
    /*$$MCOND0 K_2 Key_2 9 100 **$*/;
  Key_7_Pressed Key_2 : Key_27 Display_27
    /*$$MCOND0 K_2 Key_2 10 99 **$*/;
  Key_8_Pressed Key_2 : Key_28 Display_28
    /*$$MCOND0 K_2 Key_2 11 100 **$*/;
  Key_9_Pressed Key_2 : Key_29 Display_29
    /*$$MCOND0 K_2 Key_2 12 100 **$*/;
  Timeout_2 Key_2 : Stand_by_Key2 Display_2 Goto_2
    /*$$MCOND0 K_2 Key_2 13 100 **$*/;
  Timeout_2 Key_21 : Stand_by_Key2 Display_21 Goto_21
    /*$$MCOND0 K_2 Key_21 13 100 **$*/;
  Timeout_2 Key_20 : Stand_by_Key2 Display_20 Goto_20
    /*$$MCOND0 K_2 Key_20 13 100 **$*/;
  Timeout_2 Key_22 : Stand_by_Key2 Display_22 Goto_22
    /*$$MCOND0 K_2 Key_22 13 100 **$*/;
  Timeout_2 Key_23 : Stand_by_Key2 Display_23 Goto_23
    /*$$MCOND0 K_2 Key_23 13 100 **$*/;
  Timeout_2 Key_24 : Stand_by_Key2 Display_24 Goto_24
    /*$$MCOND0 K_2 Key_24 13 100 **$*/;
  Timeout_2 Key_25 : Stand_by_Key2 Display_25 Goto_25
    /*$$MCOND0 K_2 Key_25 13 100 **$*/;
  Timeout_2 Key_26 : Stand_by_Key2 Display_26 Goto_26
    /*$$MCOND0 K_2 Key_26 13 100 **$*/;
  Timeout_2 Key_27 : Stand_by_Key2 Display_27 Goto_27
    /*$$MCOND0 K_2 Key_27 13 100 **$*/;
  Timeout_2 Key_28 : Stand_by_Key2 Display_28 Goto_28
    /*$$MCOND0 K_2 Key_28 13 100 **$*/;
  Timeout_2 Key_29 : Stand_by_Key2 Display_29 Goto_29
    /*$$MCOND0 K_2 Key_29 13 100 **$*/;
  PLAY Key_2 : Stand_by_Key2 Display_2 Goto_2
    /*$$MCOND0 K_2 Key_2 14 100 **$*/;
  PLAY Key_21 : Stand_by_Key2 Display_21 Goto_21
    /*$$MCOND0 K_2 Key_21 14 100 **$*/;
  PLAY Key_20 : Stand_by_Key2 Display_20 Goto_20
    /*$$MCOND0 K_2 Key_20 14 100 **$*/;
  PLAY Key_22 : Stand_by_Key2 Display_22 Goto_22
    /*$$MCOND0 K_2 Key_22 14 100 **$*/;
  PLAY Key_23 : Stand_by_Key2 Display_23 Goto_23
    /*$$MCOND0 K_2 Key_23 14 100 **$*/;
  PLAY Key_24 : Stand_by_Key2 Display_24 Goto_24
    /*$$MCOND0 K_2 Key_24 14 100 **$*/;
  PLAY Key_25 : Stand_by_Key2 Display_25 Goto_25
    /*$$MCOND0 K_2 Key_25 14 100 **$*/;
  PLAY Key_26 : Stand_by_Key2 Display_26 Goto_26
    /*$$MCOND0 K_2 Key_26 14 100 **$*/;
  PLAY Key_27 : Stand_by_Key2 Display_27 Goto_27
    /*$$MCOND0 K_2 Key_27 14 100 **$*/;
  PLAY Key_28 : Stand_by_Key2 Display_28 Goto_28
    /*$$MCOND0 K_2 Key_28 14 100 **$*/;
  PLAY Key_29 : Stand_by_Key2 Display_29 Goto_29
    /*$$MCOND0 K_2 Key_29 14 100 **$*/;

SE_RULE        /* Rules from K_3 */

  SE_RESET : Reset_K_3
    /*$$MCOND0 K_3 @ 0 100 **$*/;
  CD Reset_K_3 : Stand_by_Key3
    /*$$MCOND0 K_3 Reset_K_3 1 100 **$*/;
  NotOk : Stand_by_Key3
    /*$$MCOND0 K_3 @ 2 100 **$*/;
  Key_1_Pressed Key_3 : Key_31 Display_31
    /*$$MCOND0 K_3 Key_3 3 100 **$*/;
  Key_0_Pressed Key_3 : Key_30 Display_30
    /*$$MCOND0 K_3 Key_3 4 100 **$*/;
  Key_2_Pressed Key_3 : Key_32 Display_32
    /*$$MCOND0 K_3 Key_3 5 100 **$*/;
  Key_3_Pressed !Key_0 !Key_1 !Key_2 Stand_by_Key3 : Key_3 Display__3
    /*$$MCOND0 K_3 Stand_by_Key3 6 100 **$*/;
  Key_3_Pressed !Key_0 !Key_1 !Key_2 Key_3 : Key_33 Display_33
    /*$$MCOND0 K_3 Key_3 6 100 **$*/;
  Key_4_Pressed Key_3 : Key_34 Display_34
    /*$$MCOND0 K_3 Key_3 7 100 **$*/;
  Key_5_Pressed Key_3 : Key_35 Display_35
    /*$$MCOND0 K_3 Key_3 8 100 **$*/;
  Key_6_Pressed Key_3 : Key_36 Display_36
    /*$$MCOND0 K_3 Key_3 9 100 **$*/;
  Key_7_Pressed Key_3 : Key_37 Display_37
    /*$$MCOND0 K_3 Key_3 10 100 **$*/;
  Key_8_Pressed Key_3 : Key_38 Display_38
    /*$$MCOND0 K_3 Key_3 11 100 **$*/;
  Key_9_Pressed Key_3 : Key_39 Display_39
    /*$$MCOND0 K_3 Key_3 12 100 **$*/;
  Timeout_2 Key_3 : Stand_by_Key3 Display_3 Goto_3
    /*$$MCOND0 K_3 Key_3 13 100 **$*/;
  Timeout_2 Key_31 : Stand_by_Key3 Display_31 Goto_31
    /*$$MCOND0 K_3 Key_31 13 100 **$*/;
  Timeout_2 Key_30 : Stand_by_Key3 Display_30 Goto_30
    /*$$MCOND0 K_3 Key_30 13 100 **$*/;
  Timeout_2 Key_32 : Stand_by_Key3 Display_32 Goto_32
    /*$$MCOND0 K_3 Key_32 13 100 **$*/;
  Timeout_2 Key_33 : Stand_by_Key3 Display_33 Goto_33
    /*$$MCOND0 K_3 Key_33 13 100 **$*/;
  Timeout_2 Key_34 : Stand_by_Key3 Display_34 Goto_34
    /*$$MCOND0 K_3 Key_34 13 100 **$*/;
  Timeout_2 Key_35 : Stand_by_Key3 Display_35 Goto_35
    /*$$MCOND0 K_3 Key_35 13 100 **$*/;
  Timeout_2 Key_36 : Stand_by_Key3 Display_36 Goto_36
    /*$$MCOND0 K_3 Key_36 13 100 **$*/;
  Timeout_2 Key_37 : Stand_by_Key3 Display_37 Goto_37
    /*$$MCOND0 K_3 Key_37 13 100 **$*/;
  Timeout_2 Key_38 : Stand_by_Key3 Display_38 Goto_38
    /*$$MCOND0 K_3 Key_38 13 100 **$*/;
  Timeout_2 Key_39 : Stand_by_Key3 Display_39 Goto_39
    /*$$MCOND0 K_3 Key_39 13 100 **$*/;
  PLAY Key_3 : Stand_by_Key3 Display_3 Goto_3
    /*$$MCOND0 K_3 Key_3 14 100 **$*/;
  PLAY Key_31 : Stand_by_Key3 Display_31 Goto_31
    /*$$MCOND0 K_3 Key_31 14 100 **$*/;
  PLAY Key_30 : Stand_by_Key3 Display_30 Goto_30
    /*$$MCOND0 K_3 Key_30 14 100 **$*/;
  PLAY Key_32 : Stand_by_Key3 Display_32 Goto_32
    /*$$MCOND0 K_3 Key_32 14 100 **$*/;
  PLAY Key_33 : Stand_by_Key3 Display_33 Goto_33
    /*$$MCOND0 K_3 Key_33 14 100 **$*/;
  PLAY Key_34 : Stand_by_Key3 Display_34 Goto_34
    /*$$MCOND0 K_3 Key_34 14 100 **$*/;
  PLAY Key_35 : Stand_by_Key3 Display_35 Goto_35
    /*$$MCOND0 K_3 Key_35 14 100 **$*/;
  PLAY Key_36 : Stand_by_Key3 Display_36 Goto_36
    /*$$MCOND0 K_3 Key_36 14 100 **$*/;
  PLAY Key_37 : Stand_by_Key3 Display_37 Goto_37
    /*$$MCOND0 K_3 Key_37 14 100 **$*/;
  PLAY Key_38 : Stand_by_Key3 Display_38 Goto_38
    /*$$MCOND0 K_3 Key_38 14 100 **$*/;
  PLAY Key_39 : Stand_by_Key3 Display_39 Goto_39
    /*$$MCOND0 K_3 Key_39 14 100 **$*/;

SE_RULE        /* Rules from K_0 */

  SE_RESET : Reset_K_0
    /*$$MCOND0 K_0 @ 0 100 **$*/;
  CD Reset_K_0 : Stand_by_Key0
    /*$$MCOND0 K_0 Reset_K_0 1 100 **$*/;
  NotOk : Stand_by_Key0 Display_UNKNOWN
    /*$$MCOND0 K_0 @ 2 100 **$*/;
  Key_1_Pressed Key_0 : Key_01 Display_1
    /*$$MCOND0 K_0 Key_0 3 100 **$*/;
  Key_0_Pressed !Key_1 !Key_2 !Key_3 Stand_by_Key0 : Key_0 Display__0
    /*$$MCOND0 K_0 Stand_by_Key0 4 100 **$*/;
  Key_0_Pressed !Key_1 !Key_2 !Key_3 Key_0 : Stand_by_Key0 Display_UNKNOWN
    /*$$MCOND0 K_0 Key_0 4 100 **$*/;
  Key_2_Pressed Key_0 : Key_02 Display_2
    /*$$MCOND0 K_0 Key_0 5 100 **$*/;
  Key_3_Pressed Key_0 : Key_03 Display_3
    /*$$MCOND0 K_0 Key_0 6 100 **$*/;
  Key_4_Pressed Key_0 : Key_04 Display_4
    /*$$MCOND0 K_0 Key_0 7 100 **$*/;
  Key_5_Pressed Key_0 : Key_05 Display_5
    /*$$MCOND0 K_0 Key_0 8 100 **$*/;
  Key_6_Pressed Key_0 : Key_06 Display_6
    /*$$MCOND0 K_0 Key_0 9 100 **$*/;
  Key_7_Pressed Key_0 : Key_07 Display_7
    /*$$MCOND0 K_0 Key_0 10 100 **$*/;
  Key_8_Pressed Key_0 : Key_08 Display_8
    /*$$MCOND0 K_0 Key_0 11 100 **$*/;
  Key_9_Pressed Key_0 : Key_09 Display_9
    /*$$MCOND0 K_0 Key_0 12 100 **$*/;
  Timeout_2 Key_0 : Stand_by_Key0 Display_UNKNOWN
    /*$$MCOND0 K_0 Key_0 13 100 **$*/;
  Timeout_2 Key_01 : Stand_by_Key0 Display_1 Goto_1
    /*$$MCOND0 K_0 Key_01 13 100 **$*/;
  Timeout_2 Key_02 : Stand_by_Key0 Display_2 Goto_2
    /*$$MCOND0 K_0 Key_02 13 100 **$*/;
  Timeout_2 Key_03 : Stand_by_Key0 Display_3 Goto_3
    /*$$MCOND0 K_0 Key_03 13 100 **$*/;
  Timeout_2 Key_04 : Stand_by_Key0 Display_4 Goto_4
    /*$$MCOND0 K_0 Key_04 13 100 **$*/;
  Timeout_2 Key_05 : Stand_by_Key0 Display_5 Goto_5
    /*$$MCOND0 K_0 Key_05 13 100 **$*/;
  Timeout_2 Key_06 : Stand_by_Key0 Display_6 Goto_6
    /*$$MCOND0 K_0 Key_06 13 100 **$*/;
  Timeout_2 Key_07 : Stand_by_Key0 Display_7 Goto_7
    /*$$MCOND0 K_0 Key_07 13 100 **$*/;
  Timeout_2 Key_08 : Stand_by_Key0 Display_8 Goto_8
    /*$$MCOND0 K_0 Key_08 13 100 **$*/;
  Timeout_2 Key_09 : Stand_by_Key0 Display_9 Goto_9
    /*$$MCOND0 K_0 Key_09 13 100 **$*/;
  PLAY Key_0 : Stand_by_Key0 Display_UNKNOWN
    /*$$MCOND0 K_0 Key_0 14 100 **$*/;
  PLAY Key_01 : Stand_by_Key0 Display_1 Goto_1
    /*$$MCOND0 K_0 Key_01 14 100 **$*/;
  PLAY Key_02 : Stand_by_Key0 Display_2 Goto_2
    /*$$MCOND0 K_0 Key_02 14 100 **$*/;
  PLAY Key_03 : Stand_by_Key0 Display_3 Goto_3
    /*$$MCOND0 K_0 Key_03 14 100 **$*/;
  PLAY Key_04 : Stand_by_Key0 Display_4 Goto_4
    /*$$MCOND0 K_0 Key_04 14 100 **$*/;
  PLAY Key_05 : Stand_by_Key0 Display_5 Goto_5
    /*$$MCOND0 K_0 Key_05 14 100 **$*/;
  PLAY Key_06 : Stand_by_Key0 Display_6 Goto_6
    /*$$MCOND0 K_0 Key_06 14 100 **$*/;
  PLAY Key_07 : Stand_by_Key0 Display_7 Goto_7
    /*$$MCOND0 K_0 Key_07 14 100 **$*/;
  PLAY Key_08 : Stand_by_Key0 Display_8 Goto_8
    /*$$MCOND0 K_0 Key_08 14 100 **$*/;
  PLAY Key_09 : Stand_by_Key0 Display_9 Goto_9
    /*$$MCOND0 K_0 Key_09 14 100 **$*/;

SE_RULE        /* Rules from T_1800 */

  SE_RESET : Reset_T_1800
    /*$$MCOND0 T_1800 @ 0 100 **$*/;
  CD Reset_T_1800 : Time_1800_Reset
    /*$$MCOND0 T_1800 Reset_T_1800 1 100 **$*/;
  Lead_Out !Repeat_on Time_1800_Reset : Time1800 Time_1800
    /*$$MCOND0 T_1800 Time_1800_Reset 2 100 **$*/;
  Timeout_1800 Time1800 : Time_1800_Reset
    /*$$MCOND0 T_1800 Time1800 3 100 **$*/;

SE_RULE        /* Rules from T_2 */

  SE_RESET : Reset_T_2
    /*$$MCOND0 T_2 @ 0 100 **$*/;
  CD Reset_T_2 : Time2_reset
    /*$$MCOND0 T_2 Reset_T_2 1 100 **$*/;
  Key_pressed Time2_reset : Time2 Time_2
    /*$$MCOND0 T_2 Time2_reset 2 100 **$*/;
  Timeout_2 Time2 : Time2_reset
    /*$$MCOND0 T_2 Time2 3 100 **$*/;

SE_RULE        /* Rules from Disp */

  SE_RESET : Disp_ready
    /*$$MCOND0 Disp @ 0 100 **$*/;
  CD Disp_ready : Cd_nr Get_nr
    /*$$MCOND0 Disp Disp_ready 1 100 **$*/;
  DISPLAY Cd_nr : Time_nr Get_time
    /*$$MCOND0 Disp Cd_nr 2 100 **$*/;
  DISPLAY Time_nr : Time_total Get_time_left
    /*$$MCOND0 Disp Time_nr 2 100 **$*/;
  DISPLAY Time_total : Cd_nr Get_nr
    /*$$MCOND0 Disp Time_total 2 100 **$*/;
