diff --git a/MTC_Adapter/SCMA/AdapterCom/Gateway.cs b/MTC_Adapter/SCMA/AdapterCom/Gateway.cs index d6bb924..d77f47b 100644 --- a/MTC_Adapter/SCMA/AdapterCom/Gateway.cs +++ b/MTC_Adapter/SCMA/AdapterCom/Gateway.cs @@ -73,6 +73,11 @@ namespace SCMA.AdapterCom /// Elenco ultimi allarmi riportati... /// protected Dictionary lastAlarmList; + /// + /// Bool di allarmi presenti + /// + public bool alarmPresent = false; + #endregion #region gestione globale oggetto @@ -390,8 +395,6 @@ namespace SCMA.AdapterCom /// public virtual void processAlarm() { - bool alarmPresent = false; - // continuo controllo if (AlarmFlags != null && AlarmFlags.Length > 0) { diff --git a/MTC_Adapter/SCMA/AdapterGeneric.cs b/MTC_Adapter/SCMA/AdapterGeneric.cs index dc4d8a5..ffe7c9d 100644 --- a/MTC_Adapter/SCMA/AdapterGeneric.cs +++ b/MTC_Adapter/SCMA/AdapterGeneric.cs @@ -3388,6 +3388,17 @@ namespace SCMA // anche il secondo! procPath02_Status(); } + + // cerco status allarmi presenti + if (STRB_DW2.HasFlag(StFlag32.B29)) + { + currGateway.alarmPresent = true; + } + else + { + currGateway.alarmPresent = false; + } + } ///