系统配置中删除BypassEnableTable项。
修改IoValue中对BypassEnableTable的调用,改为BypassInterlock。
This commit is contained in:
parent
ab3c600461
commit
3bb0321c52
|
@ -118,7 +118,7 @@ namespace Aitex.Core.RT.Device.Unit
|
|||
R_TRIG _mutexSignalTrigger = new R_TRIG();
|
||||
DeviceTimer _timer = new DeviceTimer();
|
||||
DeviceTimer _mutexSignalTimer = new DeviceTimer();
|
||||
private SCConfigItem _scBypassEnableTable;
|
||||
//private SCConfigItem _scBypassEnableTable;
|
||||
|
||||
private string _uniqueName;
|
||||
|
||||
|
@ -140,7 +140,7 @@ namespace Aitex.Core.RT.Device.Unit
|
|||
_doClose = ParseDoNode("doClose", node, ioModule);
|
||||
|
||||
_uniqueName = $"{Module}.{Name}";
|
||||
_scBypassEnableTable = ParseScNode("BypassEnableTable", node, module, "System.BypassEnableTable");
|
||||
//_scBypassEnableTable = ParseScNode("BypassEnableTable", node, module, "System.BypassEnableTable");
|
||||
}
|
||||
|
||||
public bool Initialize()
|
||||
|
@ -283,13 +283,18 @@ namespace Aitex.Core.RT.Device.Unit
|
|||
}
|
||||
|
||||
//达到一定条件,强制打开阀门
|
||||
if(FuncForceOpen!= null && !_scBypassEnableTable.BoolValue)
|
||||
if(FuncForceOpen!= null)
|
||||
{
|
||||
forceOpenTrigger.CLK = FuncForceOpen(Status);
|
||||
if (forceOpenTrigger.Q)
|
||||
var scBypassEnableTable = SC.GetValue<bool>("System.BypassInterlock");
|
||||
if (!scBypassEnableTable)
|
||||
{
|
||||
EV.PostMessage(Module, EventEnum.SwInterlock, Module, $"Force Set {Name} to {!Status} for Interlock enable table!");
|
||||
SetPoint = !Status;
|
||||
forceOpenTrigger.CLK = FuncForceOpen(Status);
|
||||
if (forceOpenTrigger.Q)
|
||||
{
|
||||
EV.PostMessage(Module, EventEnum.SwInterlock, Module,
|
||||
$"Force Set {Name} to {!Status} for Interlock enable table!");
|
||||
SetPoint = !Status;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -316,12 +321,16 @@ namespace Aitex.Core.RT.Device.Unit
|
|||
return false;
|
||||
}
|
||||
|
||||
if (FuncCheckInterLock != null && !_scBypassEnableTable.BoolValue)
|
||||
if (FuncCheckInterLock != null)
|
||||
{
|
||||
if (!FuncCheckInterLock(isOn))
|
||||
var scBypassEnableTable = SC.GetValue<bool>("System.BypassInterlock");
|
||||
if (!scBypassEnableTable)
|
||||
{
|
||||
EV.PostWarningLog(Module, $"Turn {Display} {stringOnOff} failed for check condition!");
|
||||
return false;
|
||||
if (!FuncCheckInterLock(isOn))
|
||||
{
|
||||
EV.PostWarningLog(Module, $"Turn {Display} {stringOnOff} failed for check condition!");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -20,7 +20,6 @@
|
|||
<config default="true" name="IsIgnoreSaveDB" description="IO不存储到数据库" max="" min="" paramter="" tag="" unit="" type="Bool" />
|
||||
<config default="false" name="BypassInterlock" description="Bypass Interlock" max="" min="" paramter="" tag="" unit="" type="Bool" />
|
||||
<config default="600" name="BypassInterlockTimeout" description="旁路互锁的超时时间,超过此时间后互锁自动恢复" max="3600" min="5" paramter="" tag="" unit="s" type="Integer" />
|
||||
<config default="false" name="BypassEnableTable" description="Bypass EnableTable" max="" min="" paramter="" tag="" unit="" type="Bool" />
|
||||
<config default="true" name="RecipeCascadeLoading" description="启用瀑布流方式加载Recipe" max="" min="" paramter="" tag="" unit="" type="Bool" />
|
||||
<config default="false" name="RecipeSaveToDB" description="Recipe文件保存到数据库" max="" min="" paramter="" tag="" unit="" type="Bool" />
|
||||
<config default="300" name="ModuleOfflineTimeout" description="模块离线超过该指定时间后产生警告" max="100000" min="0" paramter="" tag="" unit="s" type="Integer" />
|
||||
|
|
Loading…
Reference in New Issue