diff --git a/StateMachine/Jetco/59_RETTIFICA_TANGENZIALE.rul b/StateMachine/Jetco/59_RETTIFICA_TANGENZIALE.rul new file mode 100644 index 0000000..44f5eb1 --- /dev/null +++ b/StateMachine/Jetco/59_RETTIFICA_TANGENZIALE.rul @@ -0,0 +1,103 @@ +# +# Jetco macchine RETTIFICA TANGENZIALE +# +# partenza da IdxFam 42 +# +# +$DEFINITIONS + +$NAME : FANUC +$IDX : 59 +$N_STATES : 9 +$N_BITS : 7 + +#definizione bit : obbligatorio iniziare da 0 +$BIT : 0 : power_on +$BIT : 1 : refrig_on +$BIT : 2 : on_move +$BIT : 3 : start_tavola +$BIT : 4 : piano_magn_on +$BIT : 5 : mola_started +$BIT : 6 : ripari_chiusi + +#definizione stati : obbligatorio iniziare da 0 +$STATE : 0 : ST_Init +$STATE : 1 : ST_Power_off +$STATE : 2 : ST_Machine_ready +$STATE : 3 : ST_refrig_on +$STATE : 4 : ST_on_move +$STATE : 5 : ST_start_tavola +$STATE : 6 : ST_piano_magn_on +$STATE : 7 : ST_mola_started +$STATE : 8 : ST_manuale + +#definizione eventi : obbligatorio iniziare da 0 +$EVENT : 00 : EV_00 +$EVENT : 01 : EV_01 +$EVENT : 02 : EV_02 +$EVENT : 03 : EV_03 +$EVENT : 04 : EV_04 +$EVENT : 05 : EV_05 +$EVENT : 06 : EV_06 +$EVENT : 07 : EV_07 +$EVENT : 08 : EV_08 +$EVENT : 09 : EV_09 +$EVENT : 10 : EV_10 +$EVENT : 11 : EV_11 +$EVENT : 12 : EV_12 +$EVENT : 13 : HW_init +$EVENT : 14 : HW_power_off +$EVENT : 15 : HW_power_on +$EVENT : 16 : HW_machining +$EVENT : 17 : HW_end_machining +$EVENT : 18 : HW_error +$EVENT : 19 : Barcode_cambio operatore +$EVENT : 20 : Contapezzi +$EVENT : 21 : HW_start_pallet +$EVENT : 22 : HW_end_pallet +$EVENT : 23 : HW_rottura_nastro_abrasivo +$EVENT : 24 : HW_manuale +$EVENT : 25 : HW_nastro_scarico_pieno +$EVENT : 26 : Barcode_Manca_Riforn_MPD +$EVENT : 27 : Timer_timeout_tempo_ciclo +$EVENT : 28 : Timer_timeout_TURNO_by_tempo_ciclo +$EVENT : 29 : HW_magazzino_grezzi vuoto +$EVENT : 30 : HW_emergenza +$EVENT : 31 : Barcode_Modifica_Programmi +$EVENT : 32 : Barcode_Sostituzione_Utensile +$EVENT : 33 : HW_Allarme Macchina +$EVENT : 34 : HW_end_pallet_1 +$EVENT : 35 : HW_end_pallet_2 +$EVENT : 36 : HW_deposito_robot +$EVENT : 37 : Barcode_Riempimento_Vasca +$EVENT : 38 : Barcode_Riscaldamento +$EVENT : 39 : Barcode_Anomalia_Macchina +$EVENT : 40 : HW_WarmUp_CoolDown +$EVENT : 41 : HW_machining_SLOW +$EVENT : 42 : HW_Warn_Livello_Vasca +$EVENT : 43 : HW_Warn_Livello_Cell +$EVENT : 44 : HW_Warn_a_Vuoto +$EVENT : 45 : HW_Warn_Riserva +$EVENT : 46 : HW_Carico +$EVENT : 47 : HW_Mismatch +$EVENT : 48 : HW_preparing +#EVENT : 120 : IncrementoPezzi +#EVENT : 121 : RettificaPezzi +#$EVENT : 999 : Commento + + +$RULES +# state : input : next state : event +ALL_STATES : NOT power_on : ST_Power_off : HW_power_off +ALL_STATES : NOT ripari_chiusi : ST_manuale : HW_manuale +ALL_STATES : piano_magn_on : ST_piano_magn_on : HW_preparing +ALL_STATES : start_tavola : ST_start_tavola : HW_error +ALL_STATES : mola_started : ST_mola_started : HW_WarmUp_CoolDown +ALL_STATES : refrig_on : ST_refrig_on : HW_machining +ALL_STATES : power_on : ST_Machine_ready : HW_power_on + +#-------------------------------------------------------------------------- + + + +$DO diff --git a/StateMachine/LVF/49_LVF_FANUC.csv b/StateMachine/LVF/49_LVF_FANUC.csv index 77b8713..feb3069 100644 --- a/StateMachine/LVF/49_LVF_FANUC.csv +++ b/StateMachine/LVF/49_LVF_FANUC.csv @@ -1,16 +1,16 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStato 49;0;0;14;1 -49;0;1;15;2 +49;0;1;30;7 49;0;2;14;1 -49;0;3;16;3 +49;0;3;30;7 49;0;4;14;1 49;0;5;22;4 49;0;6;14;1 49;0;7;22;4 49;0;8;14;1 -49;0;9;18;5 +49;0;9;30;7 49;0;10;14;1 -49;0;11;18;5 +49;0;11;30;7 49;0;12;14;1 49;0;13;22;4 49;0;14;14;1 @@ -32,17 +32,17 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;0;30;14;1 49;0;31;22;4 49;0;32;14;1 -49;0;33;30;7 +49;0;33;15;2 49;0;34;14;1 -49;0;35;30;7 +49;0;35;16;3 49;0;36;14;1 49;0;37;22;4 49;0;38;14;1 49;0;39;22;4 49;0;40;14;1 -49;0;41;30;7 +49;0;41;18;5 49;0;42;14;1 -49;0;43;30;7 +49;0;43;18;5 49;0;44;14;1 49;0;45;22;4 49;0;46;14;1 @@ -63,12 +63,12 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;0;61;22;4 49;0;62;14;1 49;0;63;22;4 -49;1;1;15;2 -49;1;3;16;3 +49;1;1;30;7 +49;1;3;30;7 49;1;5;22;4 49;1;7;22;4 -49;1;9;18;5 -49;1;11;18;5 +49;1;9;30;7 +49;1;11;30;7 49;1;13;22;4 49;1;15;22;4 49;1;17;24;6 @@ -79,12 +79,12 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;1;27;24;6 49;1;29;22;4 49;1;31;22;4 -49;1;33;30;7 -49;1;35;30;7 +49;1;33;15;2 +49;1;35;16;3 49;1;37;22;4 49;1;39;22;4 -49;1;41;30;7 -49;1;43;30;7 +49;1;41;18;5 +49;1;43;18;5 49;1;45;22;4 49;1;47;22;4 49;1;49;24;6 @@ -96,16 +96,17 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;1;61;22;4 49;1;63;22;4 49;2;0;14;1 +49;2;1;30;7 49;2;2;14;1 -49;2;3;16;3 +49;2;3;30;7 49;2;4;14;1 49;2;5;22;4 49;2;6;14;1 49;2;7;22;4 49;2;8;14;1 -49;2;9;18;5 +49;2;9;30;7 49;2;10;14;1 -49;2;11;18;5 +49;2;11;30;7 49;2;12;14;1 49;2;13;22;4 49;2;14;14;1 @@ -127,17 +128,16 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;2;30;14;1 49;2;31;22;4 49;2;32;14;1 -49;2;33;30;7 49;2;34;14;1 -49;2;35;30;7 +49;2;35;16;3 49;2;36;14;1 49;2;37;22;4 49;2;38;14;1 49;2;39;22;4 49;2;40;14;1 -49;2;41;30;7 +49;2;41;18;5 49;2;42;14;1 -49;2;43;30;7 +49;2;43;18;5 49;2;44;14;1 49;2;45;22;4 49;2;46;14;1 @@ -159,16 +159,17 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;2;62;14;1 49;2;63;22;4 49;3;0;14;1 -49;3;1;15;2 +49;3;1;30;7 49;3;2;14;1 +49;3;3;30;7 49;3;4;14;1 49;3;5;22;4 49;3;6;14;1 49;3;7;22;4 49;3;8;14;1 -49;3;9;18;5 +49;3;9;30;7 49;3;10;14;1 -49;3;11;18;5 +49;3;11;30;7 49;3;12;14;1 49;3;13;22;4 49;3;14;14;1 @@ -190,17 +191,16 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;3;30;14;1 49;3;31;22;4 49;3;32;14;1 -49;3;33;30;7 +49;3;33;15;2 49;3;34;14;1 -49;3;35;30;7 49;3;36;14;1 49;3;37;22;4 49;3;38;14;1 49;3;39;22;4 49;3;40;14;1 -49;3;41;30;7 +49;3;41;18;5 49;3;42;14;1 -49;3;43;30;7 +49;3;43;18;5 49;3;44;14;1 49;3;45;22;4 49;3;46;14;1 @@ -222,15 +222,15 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;3;62;14;1 49;3;63;22;4 49;4;0;14;1 -49;4;1;15;2 +49;4;1;30;7 49;4;2;14;1 -49;4;3;16;3 +49;4;3;30;7 49;4;4;14;1 49;4;6;14;1 49;4;8;14;1 -49;4;9;18;5 +49;4;9;30;7 49;4;10;14;1 -49;4;11;18;5 +49;4;11;30;7 49;4;12;14;1 49;4;14;14;1 49;4;16;14;1 @@ -246,15 +246,15 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;4;28;14;1 49;4;30;14;1 49;4;32;14;1 -49;4;33;30;7 +49;4;33;15;2 49;4;34;14;1 -49;4;35;30;7 +49;4;35;16;3 49;4;36;14;1 49;4;38;14;1 49;4;40;14;1 -49;4;41;30;7 +49;4;41;18;5 49;4;42;14;1 -49;4;43;30;7 +49;4;43;18;5 49;4;44;14;1 49;4;46;14;1 49;4;48;14;1 @@ -270,15 +270,17 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;4;60;14;1 49;4;62;14;1 49;5;0;14;1 -49;5;1;15;2 +49;5;1;30;7 49;5;2;14;1 -49;5;3;16;3 +49;5;3;30;7 49;5;4;14;1 49;5;5;22;4 49;5;6;14;1 49;5;7;22;4 49;5;8;14;1 +49;5;9;30;7 49;5;10;14;1 +49;5;11;30;7 49;5;12;14;1 49;5;13;22;4 49;5;14;14;1 @@ -300,17 +302,15 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;5;30;14;1 49;5;31;22;4 49;5;32;14;1 -49;5;33;30;7 +49;5;33;15;2 49;5;34;14;1 -49;5;35;30;7 +49;5;35;16;3 49;5;36;14;1 49;5;37;22;4 49;5;38;14;1 49;5;39;22;4 49;5;40;14;1 -49;5;41;30;7 49;5;42;14;1 -49;5;43;30;7 49;5;44;14;1 49;5;45;22;4 49;5;46;14;1 @@ -332,17 +332,17 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;5;62;14;1 49;5;63;22;4 49;6;0;14;1 -49;6;1;15;2 +49;6;1;30;7 49;6;2;14;1 -49;6;3;16;3 +49;6;3;30;7 49;6;4;14;1 49;6;5;22;4 49;6;6;14;1 49;6;7;22;4 49;6;8;14;1 -49;6;9;18;5 +49;6;9;30;7 49;6;10;14;1 -49;6;11;18;5 +49;6;11;30;7 49;6;12;14;1 49;6;13;22;4 49;6;14;14;1 @@ -360,17 +360,17 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;6;30;14;1 49;6;31;22;4 49;6;32;14;1 -49;6;33;30;7 +49;6;33;15;2 49;6;34;14;1 -49;6;35;30;7 +49;6;35;16;3 49;6;36;14;1 49;6;37;22;4 49;6;38;14;1 49;6;39;22;4 49;6;40;14;1 -49;6;41;30;7 +49;6;41;18;5 49;6;42;14;1 -49;6;43;30;7 +49;6;43;18;5 49;6;44;14;1 49;6;45;22;4 49;6;46;14;1 @@ -388,17 +388,13 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;6;62;14;1 49;6;63;22;4 49;7;0;14;1 -49;7;1;15;2 49;7;2;14;1 -49;7;3;16;3 49;7;4;14;1 49;7;5;22;4 49;7;6;14;1 49;7;7;22;4 49;7;8;14;1 -49;7;9;18;5 49;7;10;14;1 -49;7;11;18;5 49;7;12;14;1 49;7;13;22;4 49;7;14;14;1 @@ -420,13 +416,17 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 49;7;30;14;1 49;7;31;22;4 49;7;32;14;1 +49;7;33;15;2 49;7;34;14;1 +49;7;35;16;3 49;7;36;14;1 49;7;37;22;4 49;7;38;14;1 49;7;39;22;4 49;7;40;14;1 +49;7;41;18;5 49;7;42;14;1 +49;7;43;18;5 49;7;44;14;1 49;7;45;22;4 49;7;46;14;1 diff --git a/StateMachine/LVF/49_LVF_FANUC.rul b/StateMachine/LVF/49_LVF_FANUC.rul index 4f87f5d..8174102 100644 --- a/StateMachine/LVF/49_LVF_FANUC.rul +++ b/StateMachine/LVF/49_LVF_FANUC.rul @@ -3,6 +3,7 @@ # # partenza da IdxFam 42 # +# 2020.09.24: cambiato emergenza in emergenza negata/armata # $DEFINITIONS @@ -18,7 +19,7 @@ $BIT : 1 : run $BIT : 2 : end_cycle $BIT : 3 : alarm $BIT : 4 : manual -$BIT : 5 : emergency +$BIT : 5 : armedEmerg #$BIT : 6 : alarm_air_oil #$BIT : 7 : auto_mode @@ -85,7 +86,7 @@ $RULES ALL_STATES : NOT power_on : ST_Power_off : HW_power_off ALL_STATES : end_cycle : ST_Cycle_end : HW_end_pallet ALL_STATES : manual : ST_Manual : HW_manuale -ALL_STATES : emergency : ST_Emergency : HW_emergenza +ALL_STATES : NOT armedEmerg : ST_Emergency : HW_emergenza ALL_STATES : alarm : ST_Alarm : HW_error ALL_STATES : run : ST_Run : HW_machining ALL_STATES : power_on : ST_Machine_ready : HW_power_on diff --git a/StateMachine/Valvital/55_Valvital_SAET.csv b/StateMachine/Valvital/55_Valvital_SAET.csv index 7f0a49b..0c74ee0 100644 --- a/StateMachine/Valvital/55_Valvital_SAET.csv +++ b/StateMachine/Valvital/55_Valvital_SAET.csv @@ -16,9 +16,9 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 55;0;14;14;1 55;0;15;22;4 55;0;16;14;1 -55;0;17;15;2 +55;0;17;24;6 55;0;18;14;1 -55;0;19;16;3 +55;0;19;24;6 55;0;20;14;1 55;0;21;22;4 55;0;22;14;1 @@ -39,8 +39,8 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 55;1;11;18;5 55;1;13;22;4 55;1;15;22;4 -55;1;17;15;2 -55;1;19;16;3 +55;1;17;24;6 +55;1;19;24;6 55;1;21;22;4 55;1;23;22;4 55;1;25;18;5 @@ -63,8 +63,9 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 55;2;14;14;1 55;2;15;22;4 55;2;16;14;1 +55;2;17;24;6 55;2;18;14;1 -55;2;19;16;3 +55;2;19;24;6 55;2;20;14;1 55;2;21;22;4 55;2;22;14;1 @@ -93,8 +94,9 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 55;3;14;14;1 55;3;15;22;4 55;3;16;14;1 -55;3;17;15;2 +55;3;17;24;6 55;3;18;14;1 +55;3;19;24;6 55;3;20;14;1 55;3;21;22;4 55;3;22;14;1 @@ -120,9 +122,9 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 55;4;12;14;1 55;4;14;14;1 55;4;16;14;1 -55;4;17;15;2 +55;4;17;24;6 55;4;18;14;1 -55;4;19;16;3 +55;4;19;24;6 55;4;20;14;1 55;4;22;14;1 55;4;24;14;1 @@ -146,9 +148,9 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 55;5;14;14;1 55;5;15;22;4 55;5;16;14;1 -55;5;17;15;2 +55;5;17;24;6 55;5;18;14;1 -55;5;19;16;3 +55;5;19;24;6 55;5;20;14;1 55;5;21;22;4 55;5;22;14;1 @@ -176,9 +178,7 @@ IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStat 55;6;14;14;1 55;6;15;22;4 55;6;16;14;1 -55;6;17;15;2 55;6;18;14;1 -55;6;19;16;3 55;6;20;14;1 55;6;21;22;4 55;6;22;14;1 diff --git a/StateMachine/Valvital/55_Valvital_SAET.rul b/StateMachine/Valvital/55_Valvital_SAET.rul index 8252d02..725ed29 100644 --- a/StateMachine/Valvital/55_Valvital_SAET.rul +++ b/StateMachine/Valvital/55_Valvital_SAET.rul @@ -2,7 +2,7 @@ # Valvital macchine SAET con contapezzi # # partenza da IdxFam 42 -# +# 2020.09.22: fix manuale vs errore # $DEFINITIONS @@ -17,7 +17,7 @@ $BIT : 0 : POWERON $BIT : 1 : RUN $BIT : 2 : END_CYCLE $BIT : 3 : ALARM -$BIT : 4 : ERROR +$BIT : 4 : MANUAL #definizione stati : obbligatorio iniziare da 0 @@ -27,7 +27,7 @@ $STATE : 2 : ST_MACHINE_READY $STATE : 3 : ST_RUN $STATE : 4 : ST_END_CYCLE $STATE : 5 : ST_ALARM -$STATE : 6 : ST_ERROR +$STATE : 6 : ST_MANUAL #definizione eventi : obbligatorio iniziare da 0 @@ -79,18 +79,21 @@ $EVENT : 44 : HW_Warna_Vuoto $EVENT : 45 : HW_WarnRiserva $EVENT : 46 : HW_Carico $EVENT : 47 : HW_MISMATCH +$EVENT : 48 : HW_preparing +#EVENT : 120 : IncrementoPezzi +#EVENT : 121 : RettificaPezzi #$EVENT : 999 : Commento $RULES # state : input : next state : event -ALL_STATES : NOT POWERON : ST_POWER_OFF : HW_POWER_OFF +ALL_STATES : NOT POWERON : ST_POWER_OFF : HW_POWER_OFF ALL_STATES : END_CYCLE : ST_END_CYCLE : HW_END_PALLET ALL_STATES : ALARM : ST_ALARM : HW_ERROR -#ALL_STATES : ERROR : ST_ERROR : HW_MISMATCH +ALL_STATES : MANUAL : ST_MANUAL : HW_MANUALE ALL_STATES : RUN : ST_RUN : HW_MACHINING -ALL_STATES : POWERON : ST_MACHINE_READY : HW_POWERON +ALL_STATES : POWERON : ST_MACHINE_READY : HW_POWERON #-------------------------------------------------------------------------- diff --git a/StateMachine/_DEFAULT/60_STD_MACHINE.csv b/StateMachine/_DEFAULT/60_STD_MACHINE.csv new file mode 100644 index 0000000..7da30aa --- /dev/null +++ b/StateMachine/_DEFAULT/60_STD_MACHINE.csv @@ -0,0 +1,193 @@ +IdxFamigliaIngresso;IdxMicroStato;ValoreIngresso;IdxTipoEvento;next_IdxMicroStato +60;0;0;14;1 +60;0;1;15;2 +60;0;2;14;1 +60;0;3;16;3 +60;0;4;14;1 +60;0;5;22;4 +60;0;6;14;1 +60;0;7;22;4 +60;0;8;14;1 +60;0;9;18;5 +60;0;10;14;1 +60;0;11;18;5 +60;0;12;14;1 +60;0;13;22;4 +60;0;14;14;1 +60;0;15;22;4 +60;0;16;14;1 +60;0;17;24;6 +60;0;18;14;1 +60;0;19;24;6 +60;0;20;14;1 +60;0;21;22;4 +60;0;22;14;1 +60;0;23;22;4 +60;0;24;14;1 +60;0;25;24;6 +60;0;26;14;1 +60;0;27;24;6 +60;0;28;14;1 +60;0;29;22;4 +60;0;30;14;1 +60;0;31;22;4 +60;1;1;15;2 +60;1;3;16;3 +60;1;5;22;4 +60;1;7;22;4 +60;1;9;18;5 +60;1;11;18;5 +60;1;13;22;4 +60;1;15;22;4 +60;1;17;24;6 +60;1;19;24;6 +60;1;21;22;4 +60;1;23;22;4 +60;1;25;24;6 +60;1;27;24;6 +60;1;29;22;4 +60;1;31;22;4 +60;2;0;14;1 +60;2;2;14;1 +60;2;3;16;3 +60;2;4;14;1 +60;2;5;22;4 +60;2;6;14;1 +60;2;7;22;4 +60;2;8;14;1 +60;2;9;18;5 +60;2;10;14;1 +60;2;11;18;5 +60;2;12;14;1 +60;2;13;22;4 +60;2;14;14;1 +60;2;15;22;4 +60;2;16;14;1 +60;2;17;24;6 +60;2;18;14;1 +60;2;19;24;6 +60;2;20;14;1 +60;2;21;22;4 +60;2;22;14;1 +60;2;23;22;4 +60;2;24;14;1 +60;2;25;24;6 +60;2;26;14;1 +60;2;27;24;6 +60;2;28;14;1 +60;2;29;22;4 +60;2;30;14;1 +60;2;31;22;4 +60;3;0;14;1 +60;3;1;15;2 +60;3;2;14;1 +60;3;4;14;1 +60;3;5;22;4 +60;3;6;14;1 +60;3;7;22;4 +60;3;8;14;1 +60;3;9;18;5 +60;3;10;14;1 +60;3;11;18;5 +60;3;12;14;1 +60;3;13;22;4 +60;3;14;14;1 +60;3;15;22;4 +60;3;16;14;1 +60;3;17;24;6 +60;3;18;14;1 +60;3;19;24;6 +60;3;20;14;1 +60;3;21;22;4 +60;3;22;14;1 +60;3;23;22;4 +60;3;24;14;1 +60;3;25;24;6 +60;3;26;14;1 +60;3;27;24;6 +60;3;28;14;1 +60;3;29;22;4 +60;3;30;14;1 +60;3;31;22;4 +60;4;0;14;1 +60;4;1;15;2 +60;4;2;14;1 +60;4;3;16;3 +60;4;4;14;1 +60;4;6;14;1 +60;4;8;14;1 +60;4;9;18;5 +60;4;10;14;1 +60;4;11;18;5 +60;4;12;14;1 +60;4;14;14;1 +60;4;16;14;1 +60;4;17;24;6 +60;4;18;14;1 +60;4;19;24;6 +60;4;20;14;1 +60;4;22;14;1 +60;4;24;14;1 +60;4;25;24;6 +60;4;26;14;1 +60;4;27;24;6 +60;4;28;14;1 +60;4;30;14;1 +60;5;0;14;1 +60;5;1;15;2 +60;5;2;14;1 +60;5;3;16;3 +60;5;4;14;1 +60;5;5;22;4 +60;5;6;14;1 +60;5;7;22;4 +60;5;8;14;1 +60;5;10;14;1 +60;5;12;14;1 +60;5;13;22;4 +60;5;14;14;1 +60;5;15;22;4 +60;5;16;14;1 +60;5;17;24;6 +60;5;18;14;1 +60;5;19;24;6 +60;5;20;14;1 +60;5;21;22;4 +60;5;22;14;1 +60;5;23;22;4 +60;5;24;14;1 +60;5;25;24;6 +60;5;26;14;1 +60;5;27;24;6 +60;5;28;14;1 +60;5;29;22;4 +60;5;30;14;1 +60;5;31;22;4 +60;6;0;14;1 +60;6;1;15;2 +60;6;2;14;1 +60;6;3;16;3 +60;6;4;14;1 +60;6;5;22;4 +60;6;6;14;1 +60;6;7;22;4 +60;6;8;14;1 +60;6;9;18;5 +60;6;10;14;1 +60;6;11;18;5 +60;6;12;14;1 +60;6;13;22;4 +60;6;14;14;1 +60;6;15;22;4 +60;6;16;14;1 +60;6;18;14;1 +60;6;20;14;1 +60;6;21;22;4 +60;6;22;14;1 +60;6;23;22;4 +60;6;24;14;1 +60;6;26;14;1 +60;6;28;14;1 +60;6;29;22;4 +60;6;30;14;1 +60;6;31;22;4 diff --git a/StateMachine/_DEFAULT/60_STD_MACHINE.rul b/StateMachine/_DEFAULT/60_STD_MACHINE.rul new file mode 100644 index 0000000..d99be42 --- /dev/null +++ b/StateMachine/_DEFAULT/60_STD_MACHINE.rul @@ -0,0 +1,102 @@ +# +# Macchine STD con contapezzi SEMPRE attivo (anche in attrezzaggio) +# +# partenza da IdxFam 42 +# +# +$DEFINITIONS + +$NAME : FANUC +$IDX : 60 +$N_STATES : 7 +$N_BITS : 5 + +#definizione bit : obbligatorio iniziare da 0 + +$BIT : 0 : power_on +$BIT : 1 : run +$BIT : 2 : pz_count +$BIT : 3 : alarm +$BIT : 4 : manual + +#definizione stati : obbligatorio iniziare da 0 + +$STATE : 0 : ST_Init +$STATE : 1 : ST_Power_off +$STATE : 2 : ST_Machine_ready +$STATE : 3 : ST_Run +$STATE : 4 : ST_Cycle_end +$STATE : 5 : ST_Alarm +$STATE : 6 : ST_Manual + +#definizione eventi : obbligatorio iniziare da 0 + +$EVENT : 00 : EV_00 +$EVENT : 01 : EV_01 +$EVENT : 02 : EV_02 +$EVENT : 03 : EV_03 +$EVENT : 04 : EV_04 +$EVENT : 05 : EV_05 +$EVENT : 06 : EV_06 +$EVENT : 07 : EV_07 +$EVENT : 08 : EV_08 +$EVENT : 09 : EV_09 +$EVENT : 10 : EV_10 +$EVENT : 11 : EV_11 +$EVENT : 12 : EV_12 +$EVENT : 13 : HW_init +$EVENT : 14 : HW_power_off +$EVENT : 15 : HW_power_on +$EVENT : 16 : HW_machining +$EVENT : 17 : HW_end_machining +$EVENT : 18 : HW_error +$EVENT : 19 : Barcode_cambio operatore +$EVENT : 20 : Contapezzi +$EVENT : 21 : HW_start_pallet +$EVENT : 22 : HW_end_pallet +$EVENT : 23 : HW_rottura_nastro_abrasivo +$EVENT : 24 : HW_manuale +$EVENT : 25 : HW_nastro_scarico_pieno +$EVENT : 26 : Barcode_Manca_Riforn_MPD +$EVENT : 27 : Timer_timeout_tempo_ciclo +$EVENT : 28 : Timer_timeout_TURNO_by_tempo_ciclo +$EVENT : 29 : HW_magazzino_grezzi vuoto +$EVENT : 30 : HW_emergenza +$EVENT : 31 : Barcode_Modifica_Programmi +$EVENT : 32 : Barcode_Sostituzione_Utensile +$EVENT : 33 : HW_Allarme Macchina +$EVENT : 34 : HW_end_pallet_1 +$EVENT : 35 : HW_end_pallet_2 +$EVENT : 36 : HW_deposito_robot +$EVENT : 37 : Barcode_Riempimento_Vasca +$EVENT : 38 : Barcode_Riscaldamento +$EVENT : 39 : Barcode_Anomalia_Macchina +$EVENT : 40 : HW_WarmUp_CoolDown +$EVENT : 41 : HW_machining_SLOW +$EVENT : 42 : HW_Warn_Livello_Vasca +$EVENT : 43 : HW_Warn_Livello_Cell +$EVENT : 44 : HW_Warn_a_Vuoto +$EVENT : 45 : HW_Warn_Riserva +$EVENT : 46 : HW_Carico +$EVENT : 47 : HW_Mismatch +$EVENT : 48 : HW_preparing +#EVENT : 120 : IncrementoPezzi +#EVENT : 121 : RettificaPezzi +#$EVENT : 999 : Commento + +$RULES + +# state : input : next state : event + +ALL_STATES : NOT power_on : ST_Power_off : HW_power_off +ALL_STATES : pz_count : ST_Cycle_end : HW_end_pallet +ALL_STATES : manual : ST_Manual : HW_manuale +ALL_STATES : alarm : ST_Alarm : HW_error +ALL_STATES : run : ST_Run : HW_machining +ALL_STATES : power_on : ST_Machine_ready : HW_power_on + +#-------------------------------------------------------------------------- + + + +$DO