Commit 63afe22b 几米阳光

报警修改

1 个父辈 59605f9f
...@@ -417,6 +417,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -417,6 +417,7 @@ namespace OnlineStore.DeviceLibrary
LogUtil.info(LOGGER, StoreName + "复位:进出轴回原点"); LogUtil.info(LOGGER, StoreName + "复位:进出轴回原点");
//复位和回原点要等轴3进出轴ORG亮了以后才能返回其他轴 //复位和回原点要等轴3进出轴ORG亮了以后才能返回其他轴
ACAxisHomeMove(Config.InOut_Axis); ACAxisHomeMove(Config.InOut_Axis);
StoreMove.WaitList.Add(WaitResultInfo.WaitTime(2000));
break; break;
case StoreMoveStep.BOX_H_InOutBack: case StoreMoveStep.BOX_H_InOutBack:
...@@ -734,12 +735,14 @@ namespace OnlineStore.DeviceLibrary ...@@ -734,12 +735,14 @@ namespace OnlineStore.DeviceLibrary
if (alarmType == StoreAlarmType.AxisAlarm) if (alarmType == StoreAlarmType.AxisAlarm)
{ {
LogUtil.error(LOGGER, StoreName + "轴报警,关闭轴,打开报警灯"); LogUtil.error(LOGGER, StoreName + "轴报警,关闭轴,打开报警灯");
StopMove();
CloseAllAxis(); CloseAllAxis();
} }
else if (alarmType == StoreAlarmType.SuddenStop) else if (alarmType == StoreAlarmType.SuddenStop)
{ {
isInSuddenDown = true; isInSuddenDown = true;
LogUtil.error(LOGGER, StoreName + "收到急停信号,关闭所有轴卡,关闭所有IO,停止所有运动"); LogUtil.error(LOGGER, StoreName + "收到急停信号,关闭所有轴卡,关闭所有IO,停止所有运动");
StopMove();
CloseAllAxis(); CloseAllAxis();
StoreMove.EndMove(); StoreMove.EndMove();
storeStatus = StoreStatus.SuddenStop; storeStatus = StoreStatus.SuddenStop;
...@@ -748,15 +751,15 @@ namespace OnlineStore.DeviceLibrary ...@@ -748,15 +751,15 @@ namespace OnlineStore.DeviceLibrary
{ {
isNoAirCheck = true; isNoAirCheck = true;
LogUtil.error(LOGGER, StoreName + " 未检测到气压信号 ,关闭所有轴卡,关闭所有IO,停止所有运动"); LogUtil.error(LOGGER, StoreName + " 未检测到气压信号 ,关闭所有轴卡,关闭所有IO,停止所有运动");
CloseAllAxis(); StopMove();
CloseAllAxis();
StoreMove.EndMove(); StoreMove.EndMove();
storeStatus = StoreStatus.SuddenStop; storeStatus = StoreStatus.SuddenStop;
} }
if (alarmType != StoreAlarmType.IoSingleTimeOut) //if (alarmType != StoreAlarmType.IoSingleTimeOut)
{ //{
StopMove(); // StopMove();
} //}
} }
private bool InProcess = false; private bool InProcess = false;
private DateTime preProcessTime = DateTime.Now; private DateTime preProcessTime = DateTime.Now;
...@@ -1137,7 +1140,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -1137,7 +1140,7 @@ namespace OnlineStore.DeviceLibrary
if (alarmIo == 1) if (alarmIo == 1)
{ {
WarnMsg = StoreName + " 运动轴" + axisInfo.Explain + "报警"; WarnMsg = StoreName + " 运动轴" + axisInfo.Explain + "报警";
if (info.AlarmIoValue != alarmIo) if (!info.AlarmIoValue.Equals( alarmIo))
{ {
LogUtil.error(LOGGER, WarnMsg); LogUtil.error(LOGGER, WarnMsg);
int alarmCode = GetAlarmCodeByAxis(axisInfo); int alarmCode = GetAlarmCodeByAxis(axisInfo);
...@@ -1149,7 +1152,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -1149,7 +1152,7 @@ namespace OnlineStore.DeviceLibrary
} }
else else
{ {
if (info.AlarmIoValue != alarmIo) if (!info.AlarmIoValue.Equals(alarmIo))
{ {
LogUtil.error(LOGGER, StoreName + " 运动轴 " + axisInfo.Explain + ",报警已解除!"); LogUtil.error(LOGGER, StoreName + " 运动轴 " + axisInfo.Explain + ",报警已解除!");
info.AlarmIoValue = alarmIo; info.AlarmIoValue = alarmIo;
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!