Commit 00924ade LN

修改BUG

1 个父辈 7070aeee
...@@ -130,7 +130,7 @@ namespace OnlineStore.Common ...@@ -130,7 +130,7 @@ namespace OnlineStore.Common
{ {
if (key.Equals("") || value.Equals("")) if (key.Equals("") || value.Equals(""))
{ {
return; //return;
} }
//增加的内容写在appSettings段下 <add key="RegCode" value="0"/> //增加的内容写在appSettings段下 <add key="RegCode" value="0"/>
System.Configuration.Configuration config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None); System.Configuration.Configuration config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None);
......
...@@ -328,9 +328,11 @@ namespace OnlineStore.DeviceLibrary ...@@ -328,9 +328,11 @@ namespace OnlineStore.DeviceLibrary
{ {
LogUtil.error(LOGGER, "进出轴报警!复位失败,请检查!"); LogUtil.error(LOGGER, "进出轴报警!复位失败,请检查!");
} }
//复位和回原点要等轴3进出轴ORG亮了以后才能返回其他轴 //复位和回原点要等轴3进出轴ORG亮了以后才能返回其他轴
LogUtil.info(LOGGER, StoreName + "复位中: 压紧轴,旋转轴,上下轴开始 原点返回"); LogUtil.info(LOGGER, StoreName + "复位中: 压紧轴,旋转轴,上下轴开始 原点返回");
StoreMove.NextMoveStep(StoreMoveStep.BOX_H_OtherAxisBack); StoreMove.NextMoveStep(StoreMoveStep.BOX_H_OtherAxisBack);
StoreMove.TimeOutSeconds = 100;
if (IsHasCompress_Axis) if (IsHasCompress_Axis)
{ {
ACAxisHomeMove(Config.Comp_Axis); ACAxisHomeMove(Config.Comp_Axis);
...@@ -520,7 +522,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -520,7 +522,7 @@ namespace OnlineStore.DeviceLibrary
Thread.Sleep(50); Thread.Sleep(50);
ACServerManager.ServoOn(portName, slvAddr); ACServerManager.ServoOn(portName, slvAddr);
} }
Thread.Sleep(1000); Thread.Sleep(500);
//打开所有轴 //打开所有轴
if (isCheck) if (isCheck)
{ {
......
...@@ -4,6 +4,7 @@ using System.Collections.Generic; ...@@ -4,6 +4,7 @@ using System.Collections.Generic;
using System.Linq; using System.Linq;
using System.Text; using System.Text;
using System.Threading; using System.Threading;
using System.Threading.Tasks;
namespace OnlineStore.DeviceLibrary namespace OnlineStore.DeviceLibrary
{ {
...@@ -14,17 +15,19 @@ namespace OnlineStore.DeviceLibrary ...@@ -14,17 +15,19 @@ namespace OnlineStore.DeviceLibrary
public static List<string> WaitInStoreList = new List<string>(); public static List<string> WaitInStoreList = new List<string>();
public static void StartConnect() public static void StartConnect()
{ {
string lineServer = ConfigAppSettings.GetValue(Setting_Init.LineServerIp); Task.Factory.StartNew(delegate
int linePort = ConfigAppSettings.GetIntValue(Setting_Init.LineServerPort);
if (lineServer.Equals(""))
{ {
LogUtil.error("未配置流水线地址,不需要连接"); string lineServer = ConfigAppSettings.GetValue(Setting_Init.LineServerIp);
return; int linePort = ConfigAppSettings.GetIntValue(Setting_Init.LineServerPort);
} if (lineServer.Equals(""))
client = new TcpClient(); {
LogUtil.error("未配置流水线地址,不需要连接");
bool result = client.StartConnect(lineServer, linePort, HandlerMsg,2000); return;
}
client = new TcpClient();
bool result = client.StartConnect(lineServer, linePort, HandlerMsg, 2000);
});
} }
public static void StopConnect() public static void StopConnect()
......
...@@ -89,6 +89,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -89,6 +89,7 @@ namespace OnlineStore.DeviceLibrary
WaitList = new List<WaitResultInfo>(); WaitList = new List<WaitResultInfo>();
OneWaitCanEndStep = false; OneWaitCanEndStep = false;
CanWhileCount = 5; CanWhileCount = 5;
TimeOutSeconds = 60;
} }
/// <summary> /// <summary>
/// 当前步骤执行完成 /// 当前步骤执行完成
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!