| 
															
																@@ -65,7 +65,7 @@ namespace FurnaceRT.Equipments.Systems 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             _enableLog = SC.GetValue<bool>($"System.ModbusCommunicationEnableLogMessage");
 
															 | 
															
															 | 
															
																             _enableLog = SC.GetValue<bool>($"System.ModbusCommunicationEnableLogMessage");
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             OP.Subscribe($"Sysytem.{Name}.ModbusPLC", InvokeReset);
 
															 | 
															
															 | 
															
																             OP.Subscribe($"Sysytem.{Name}.ModbusPLC", InvokeReset);
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            if (SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            if (!SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             {
 
															 | 
															
															 | 
															
																             {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 _wcfPlc = new WcfPlc("System", Name, $"WcfPlc_{Name}");
 
															 | 
															
															 | 
															
																                 _wcfPlc = new WcfPlc("System", Name, $"WcfPlc_{Name}");
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 _wcfPlc.Initialize();
 
															 | 
															
															 | 
															
																                 _wcfPlc.Initialize();
 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -244,7 +244,7 @@ namespace FurnaceRT.Equipments.Systems 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             if (!_trigConnected.M)
 
															 | 
															
															 | 
															
																             if (!_trigConnected.M)
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             {
 
															 | 
															
															 | 
															
																             {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-                if (!SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                if (SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 {
 
															 | 
															
															 | 
															
																                 {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                     Close();
 
															 | 
															
															 | 
															
																                     Close();
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                     Open();
 
															 | 
															
															 | 
															
																                     Open();
 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -267,7 +267,7 @@ namespace FurnaceRT.Equipments.Systems 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         protected override bool[] ReadDi(int offset, int size)
 
															 | 
															
															 | 
															
																         protected override bool[] ReadDi(int offset, int size)
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         {
 
															 | 
															
															 | 
															
																         {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            if (SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            if (!SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             {
 
															 | 
															
															 | 
															
																             {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 int address = offset + _aiStartAddress;
 
															 | 
															
															 | 
															
																                 int address = offset + _aiStartAddress;
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 var ret = _wcfPlc.ReadBool(address.ToString(), out bool[] data, size, out _);
 
															 | 
															
															 | 
															
																                 var ret = _wcfPlc.ReadBool(address.ToString(), out bool[] data, size, out _);
 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -356,7 +356,7 @@ namespace FurnaceRT.Equipments.Systems 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         protected override float[] ReadAiFloat(int offset, int size)
 
															 | 
															
															 | 
															
																         protected override float[] ReadAiFloat(int offset, int size)
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         {
 
															 | 
															
															 | 
															
																         {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            if (SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            if (!SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             {
 
															 | 
															
															 | 
															
																             {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 int address = offset + _aiStartAddress;
 
															 | 
															
															 | 
															
																                 int address = offset + _aiStartAddress;
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 var ret = _wcfPlc.ReadFloat(address.ToString(), out float[] data, size, out _);
 
															 | 
															
															 | 
															
																                 var ret = _wcfPlc.ReadFloat(address.ToString(), out float[] data, size, out _);
 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -435,7 +435,7 @@ namespace FurnaceRT.Equipments.Systems 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         protected bool[] ReadDo(int offset, int size)
 
															 | 
															
															 | 
															
																         protected bool[] ReadDo(int offset, int size)
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         {
 
															 | 
															
															 | 
															
																         {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            if (SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            if (!SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             {
 
															 | 
															
															 | 
															
																             {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 return null;
 
															 | 
															
															 | 
															
																                 return null;
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             }
 
															 | 
															
															 | 
															
																             }
 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -501,7 +501,7 @@ namespace FurnaceRT.Equipments.Systems 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         protected override short[] ReadAi(int offset, int size)
 
															 | 
															
															 | 
															
																         protected override short[] ReadAi(int offset, int size)
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         {
 
															 | 
															
															 | 
															
																         {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            if (SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            if (!SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             {
 
															 | 
															
															 | 
															
																             {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 int address = offset + _aiStartAddress;
 
															 | 
															
															 | 
															
																                 int address = offset + _aiStartAddress;
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 var ret = _wcfPlc.ReadInt16(address.ToString(), out short[] data, size, out _);
 
															 | 
															
															 | 
															
																                 var ret = _wcfPlc.ReadInt16(address.ToString(), out short[] data, size, out _);
 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -580,7 +580,7 @@ namespace FurnaceRT.Equipments.Systems 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         protected float[] ReadAoFloat(int offset, int size)
 
															 | 
															
															 | 
															
																         protected float[] ReadAoFloat(int offset, int size)
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         {
 
															 | 
															
															 | 
															
																         {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            if (SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            if (!SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             {
 
															 | 
															
															 | 
															
																             {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 return null;
 
															 | 
															
															 | 
															
																                 return null;
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             }
 
															 | 
															
															 | 
															
																             }
 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -653,7 +653,7 @@ namespace FurnaceRT.Equipments.Systems 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         protected short[] ReadAo(int offset, int size)
 
															 | 
															
															 | 
															
																         protected short[] ReadAo(int offset, int size)
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         {
 
															 | 
															
															 | 
															
																         {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            if (SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            if (!SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             {
 
															 | 
															
															 | 
															
																             {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 return null;
 
															 | 
															
															 | 
															
																                 return null;
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             }
 
															 | 
															
															 | 
															
																             }
 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -726,7 +726,7 @@ namespace FurnaceRT.Equipments.Systems 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         public override bool SetValueFloat(AOAccessor aoItem, float value)
 
															 | 
															
															 | 
															
																         public override bool SetValueFloat(AOAccessor aoItem, float value)
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         {
 
															 | 
															
															 | 
															
																         {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            if (SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            if (!SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 return true;
 
															 | 
															
															 | 
															
																                 return true;
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             if (!_trigConnected.M)
 
															 | 
															
															 | 
															
																             if (!_trigConnected.M)
 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -760,7 +760,7 @@ namespace FurnaceRT.Equipments.Systems 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         public override bool SetValue(DOAccessor doItem, bool value)
 
															 | 
															
															 | 
															
																         public override bool SetValue(DOAccessor doItem, bool value)
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         {
 
															 | 
															
															 | 
															
																         {
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            if (SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            if (!SC.GetValue<bool>("System.IsSimulatorMode"))
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 return true;
 
															 | 
															
															 | 
															
																                 return true;
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
 
															 | 
															
															 | 
															
																 
 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             if (!_trigConnected.M)
 
															 | 
															
															 | 
															
																             if (!_trigConnected.M)
 
															 |