Commit 4c513d02 几米阳光

出库完成手动发送消息给服务器

1 个父辈 7a8703a7
......@@ -17,7 +17,7 @@ namespace OnlineStore.DeviceLibrary
/// </summary>
public class KNDAIManager
{
public static bool NeedReadAI = false;
public static ushort DefaultAILength = 8;
public static byte DefualtSlaveID = 255;
private static string AIStartAddress = "0258";
......@@ -126,6 +126,7 @@ namespace OnlineStore.DeviceLibrary
{
isProcess = true;
bool IsNeedReadAI = StoreManager.Store.KNDIOValue(IO_Type.TrayCheck_Door).Equals(IO_VALUE.HIGH);
IsNeedReadAI = (IsNeedReadAI || NeedReadAI);
TimeSpan span = DateTime.Now - PreCheckTime;
List<string> list = new List<string>(mastMap.Keys);
foreach (string IP in list)
......
......@@ -717,25 +717,27 @@ namespace OnlineStore.DeviceLibrary
StoreMove.NextMoveStep(StoreMoveStep.SO_12_DeviceOutFromDoor);
OutStoreLog("出库:SO_12 叉子从出料口返回,,进出轴动作至P1(待机点) ");
InOutBackToP1(moveP.InOut_P1);
KNDAIManager.NeedReadAI = true;
}
else if (StoreMove.MoveStep == StoreMoveStep.SO_12_DeviceOutFromDoor)
{
StoreMove.NextMoveStep(StoreMoveStep.SO_121_CheckHasTray);
OutStoreLog("出库:SO_121等待门口有料盘高度");
StoreMove.WaitList.Add(WaitResultInfo.WaitHeight(8));
OutStoreLog("出库:SO_121等待门口有料盘高度,更新状态为出库完成");
StoreMove.WaitList.Add(WaitResultInfo.WaitHeight(8));
//把料盘放到门口时出库完成
string posId = StoreMove.MoveParam != null ? StoreMove.MoveParam.PositionNum : "";
lastPosId = posId;
lastPosIdStatus = StoreStatus.OutStoreEnd;
storeStatus = StoreStatus.OutStoreEnd;
//手动给服务器发消息
SendLineStatus();
}
else if (StoreMove.MoveStep == StoreMoveStep.SO_121_CheckHasTray)
{
StoreMove.NextMoveStep(StoreMoveStep.SO_13_GoBack);
OutStoreLog("出库:SO_13 升降轴返回,轴2至P1(待机点) ,关闭舱门");
ACAxisMove(Config.UpDown_Axis, moveP.UpDown_P1, Config.UpDownAxis_P1_Speed);
CloseDoorAndWait();
//把料盘放到门口时出库完成
string posId = StoreMove.MoveParam != null ? StoreMove.MoveParam.PositionNum : "";
lastPosId = posId;
lastPosIdStatus = StoreStatus.OutStoreEnd;
storeStatus = StoreStatus.OutStoreEnd;
CloseDoorAndWait();
}
else if (StoreMove.MoveStep == StoreMoveStep.SO_13_GoBack)
{
......@@ -757,6 +759,7 @@ namespace OnlineStore.DeviceLibrary
TimeSpan span = DateTime.Now - startOutStoreTime;
string posId = StoreMove.MoveParam != null ? StoreMove.MoveParam.PositionNum : "";
KNDAIManager.NeedReadAI = false ;
storeStatus = StoreStatus.StoreOnline;
LogUtil.info(LOGGER, StoreName + " 【" + posId + "】 整个出库流程结束,耗时【" + FormUtil.GetSpanStr(span) + "】!", storeMoveColor);
StoreMove.EndMove();
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!