Commit 5cf1f174 LN

1.自动模式增加脚踏/按钮暂停功能。

2.料塔初始化失败时,提示是否进入过板模式。
1 个父辈 a388df00
...@@ -104,6 +104,7 @@ ...@@ -104,6 +104,7 @@
<Compile Include="manager\TSAVBean_Partial.cs" /> <Compile Include="manager\TSAVBean_Partial.cs" />
<Compile Include="manager\TSAVStatus.cs" /> <Compile Include="manager\TSAVStatus.cs" />
<Compile Include="manager\WorkInfo.cs" /> <Compile Include="manager\WorkInfo.cs" />
<Compile Include="manager\WorkModeUtil.cs" />
<Compile Include="mes\DeviceStatus.cs" /> <Compile Include="mes\DeviceStatus.cs" />
<Compile Include="mes\MesUtil.cs" /> <Compile Include="mes\MesUtil.cs" />
<Compile Include="Properties\AssemblyInfo.cs" /> <Compile Include="Properties\AssemblyInfo.cs" />
......
...@@ -46,6 +46,14 @@ namespace TSA_V.DeviceLibrary ...@@ -46,6 +46,14 @@ namespace TSA_V.DeviceLibrary
/// 工作模式,0=脚踏模式,1=自动模式 /// 工作模式,0=脚踏模式,1=自动模式
/// </summary> /// </summary>
public static int WorkMode = ConfigAppSettings.GetIntValue(Setting_Init.WorkMode); public static int WorkMode = ConfigAppSettings.GetIntValue(Setting_Init.WorkMode);
/// <summary>
/// 自动模式下,踩脚踏或按按钮, 自动模式暂停,界面显示暂停状态;再次踩脚踏或按按钮,退出暂停状态
/// </summary>
public static bool WorkPause = false;
public static int AuToModeSeconds = ConfigAppSettings.GetIntValue(Setting_Init.AuToModeSeconds); public static int AuToModeSeconds = ConfigAppSettings.GetIntValue(Setting_Init.AuToModeSeconds);
public static TSAVStatus Status = TSAVStatus.Wait; public static TSAVStatus Status = TSAVStatus.Wait;
...@@ -94,7 +102,7 @@ namespace TSA_V.DeviceLibrary ...@@ -94,7 +102,7 @@ namespace TSA_V.DeviceLibrary
for (int j = 1; j <= ceng; j++) for (int j = 1; j <= ceng; j++)
{ {
string str = sp + i + sp + j; string str = sp + i + sp + j;
uint nodeid = ConfigAppSettings.getUintValue(Setting_Init.RNode_Addr, str); uint nodeid = ConfigAppSettings.getUintValue(Setting_Init.RNode_Addr, str);
if (!(nodeid <= 0)) if (!(nodeid <= 0))
{ {
NodeInfo node = new NodeInfo(nodeid, "Node:_" + i + "_" + j, "_" + i + "_" + j); NodeInfo node = new NodeInfo(nodeid, "Node:_" + i + "_" + j, "_" + i + "_" + j);
...@@ -111,15 +119,18 @@ namespace TSA_V.DeviceLibrary ...@@ -111,15 +119,18 @@ namespace TSA_V.DeviceLibrary
{ {
DefaultPSize = 4; DefaultPSize = 4;
} }
// bool result = GalvanometerManager.OpenPort(Gal_Port); Task.Factory.StartNew(delegate
Screen[] sc = Screen.AllScreens;
bool result = sc.Length >= 2;
if (!result)
{ {
LogUtil.error("振镜初始化失败!"); // bool result = GalvanometerManager.OpenPort(Gal_Port);
return ResourceControl.GetString(ResourceControl.InitXFail, "振镜初始化失败"); Screen[] sc = Screen.AllScreens;
} bool result = sc.Length >= 2;
if (!result)
{
LogUtil.error("振镜初始化失败!");
//return ResourceControl.GetString(ResourceControl.InitXFail, "振镜初始化失败");
}
});
return ""; return "";
} }
...@@ -129,31 +140,35 @@ namespace TSA_V.DeviceLibrary ...@@ -129,31 +140,35 @@ namespace TSA_V.DeviceLibrary
string date = DateTime.Now.ToString("HH:mm"); string date = DateTime.Now.ToString("HH:mm");
return "" + date + " ALARM "; return "" + date + " ALARM ";
} }
public static string startRunMsg = "";
public static string StartRun() public static string StartRun()
{ {
startRunMsg = "";
MesUtil.Open(); MesUtil.Open();
if (Status.Equals(TSAVStatus.Wait)) if (Status.Equals(TSAVStatus.Wait))
{ {
LogUtil.info(Name + "开始连接Can协议"); LogUtil.debug(Name + " StartRun:开始连接Can协议");
string msg = PUSICANControl.Open(); string msg = PUSICANControl.Open();
if (!msg.Equals("")) if (!msg.Equals(""))
{ {
LogUtil.error(Name + "Can协议连接失败:" + msg); LogUtil.error(Name + " StartRun 失败:Can协议连接失败:" + msg);
return ResourceControl.GetString(ResourceControl.CanConnectFail, "Can协议连接失败"); startRunMsg = ResourceControl.GetString(ResourceControl.CanConnectFail, "Can协议连接失败");
return startRunMsg;
} }
else else
{ {
LogUtil.info(Name + "连接Can协议成功"); LogUtil.info(Name + " StartRun:连接Can协议成功");
} }
Thread.Sleep(PUSICANControl.SleepMS); Thread.Sleep(PUSICANControl.SleepMS);
resetStep = ResetStep.OpenCan_0; resetStep = ResetStep.OpenCan_0;
LastResetChangeTime = DateTime.Now; LastResetChangeTime = DateTime.Now;
} }
//判断IO模块是否连接 //判断IO模块是否连接
if (IOManager.ISConnection().Equals(false)) if (IOManager.ISConnection().Equals(false))
{ {
LogUtil.info(Name + "IO模块连接失败"); LogUtil.info(Name + " StartRun 失败:IO模块连接失败");
return ResourceControl.GetString(ResourceControl.IOConnectError, "IO模块连接失败"); startRunMsg = ResourceControl.GetString(ResourceControl.IOConnectError, "IO模块连接失败");
return startRunMsg;
} }
StartReset(); StartReset();
...@@ -162,6 +177,81 @@ namespace TSA_V.DeviceLibrary ...@@ -162,6 +177,81 @@ namespace TSA_V.DeviceLibrary
return ""; return "";
} }
public static void DeviceCheck()
{
try
{
//验证旋转轴是否上线,未上线弹出提示
LogUtil.info(Name + " DeviceCheck 开始连接Can协议");
string msg = PUSICANControl.Open();
if (!msg.Equals(""))
{
LogUtil.info(Name + " DeviceCheck Can协议连接失败,询问是否进入 过板模式");
WorkModeUtil.SelectMode(Name);
return;
}
Thread.Sleep(PUSICANControl.SleepMS);
LogUtil.info(Name + " DeviceCheck 初始化所有旋转轴 InitNode");
InitNode();
Thread.Sleep(PUSICANControl.SleepMS);
Thread.Sleep(1000);
//验证旋转轴是否上线
bool isAllOk = true;
string timeOutMsg = "";
SLAVE_STATUS rStatus = new SLAVE_STATUS();
int whileCount = 5;
while (true)
{
foreach (Dictionary<int, NodeInfo> map in RotateMap.Values)
{
foreach (NodeInfo node in map.Values)
{
PUSICANControl.PUSICO_GetNodeStatus(node.NodeId, ref rStatus);
if (!rStatus.Equals(SLAVE_STATUS.SLAVESTATUS_WORK))
{
timeOutMsg = ResourceControl.GetString(ResourceControl.RNodeOnLine, " 旋转轴[{0}][{1}]上线", node.NodeId, rStatus);
isAllOk = false;
break;
}
}
}
if (isAllOk)
{
break;
}
whileCount++;
if (whileCount >= 5)
{
break;
}
Thread.Sleep(500);
}
if (!isAllOk)
{
LogUtil.info(Name + "DeviceCheck 检测 " + timeOutMsg + " 上线超时,询问是否进入 过板模式");
WorkModeUtil.SelectMode(Name);
}
else
{
LogUtil.info(Name + " DeviceCheck 检测旋转轴线完成,所有转盘都已连接");
WorkModeUtil.ModeCheckEnd();
}
}
catch (Exception ex)
{
LogUtil.error(Name + " DeviceCheck 出错:" + ex.ToString());
WorkModeUtil.ModeCheckEnd();
}
}
public static void StartReset() public static void StartReset()
{ {
if (Status > TSAVStatus.Wait) if (Status > TSAVStatus.Wait)
...@@ -179,23 +269,23 @@ namespace TSA_V.DeviceLibrary ...@@ -179,23 +269,23 @@ namespace TSA_V.DeviceLibrary
LogUtil.info(Name + "开始重置设备"); LogUtil.info(Name + "开始重置设备");
LastResetChangeTime = DateTime.Now; LastResetChangeTime = DateTime.Now;
Status = TSAVStatus.Reset; Status = TSAVStatus.Reset;
resetStep = ResetStep.AddNode_1;
resetStep = ResetStep.AddNode_1;
Thread.Sleep(PUSICANControl.SleepMS); Thread.Sleep(PUSICANControl.SleepMS);
foreach (Dictionary<int, NodeInfo> map in RotateMap.Values)
if (WorkModeUtil.OnlyGuoBan)
{
LogUtil.info(Name + "重置中 " + resetStep + ": OnlyGuoBan 模式,不需要初始化旋转轴 ");
}
else
{ {
foreach (NodeInfo nodeid in map.Values) InitNode();
{
PUSICANControl.InitNode(nodeid.NodeId);
}
} }
if (!IOBase.NoLine) if (!IOBase.NoLine)
{ {
PUSICANControl.InitNode(LWidthManager.Line_NodeAddr); PUSICANControl.InitNode(LWidthManager.Line_NodeAddr);
} }
LogUtil.info(Name + "重置中AddNode_1:InitNode 所有节点 "); LogUtil.info(Name + "重置中 "+resetStep+":InitNode 所有节点 ");
} }
public delegate bool ShowPointDelegate(ProjectorPInfo p); public delegate bool ShowPointDelegate(ProjectorPInfo p);
public static event ShowPointDelegate ShowPointEvent; public static event ShowPointDelegate ShowPointEvent;
...@@ -204,6 +294,60 @@ namespace TSA_V.DeviceLibrary ...@@ -204,6 +294,60 @@ namespace TSA_V.DeviceLibrary
ProjectorPInfo p = new ProjectorPInfo((int)x, (int)y, type, sizex, sizey, penWidth, name); ProjectorPInfo p = new ProjectorPInfo((int)x, (int)y, type, sizex, sizey, penWidth, name);
ShowPointEvent?.Invoke(p); ShowPointEvent?.Invoke(p);
} }
private static void InitNode()
{
foreach (Dictionary<int, NodeInfo> map in RotateMap.Values)
{
foreach (NodeInfo nodeid in map.Values)
{
PUSICANControl.InitNode(nodeid.NodeId);
}
}
}
private static void XYHomeMove_3()
{
//初始化所有旋转轴
foreach (Dictionary<int, NodeInfo> map in RotateMap.Values)
{
foreach (NodeInfo node in map.Values)
{
PUSICANControl.InitRNodeConfig(node.NodeId);
Thread.Sleep(10);
}
}
if (!IOBase.NoLine)
{
PUSICANControl.InitRNodeConfig(LWidthManager.Line_NodeAddr, true);
Thread.Sleep(10);
}
//所有轴原点返回
foreach (Dictionary<int, NodeInfo> map in RotateMap.Values)
{
foreach (NodeInfo node in map.Values)
{
PUSICANControl.HomeMove(node.NodeId);
Thread.Sleep(10);
}
}
// PUSICANControl.HomeMove(LWidthManager.Line_NodeAddr);
resetStep = ResetStep.XYHomeMove_3;
LastResetChangeTime = DateTime.Now;
LogUtil.info(Name + "重置中 " + resetStep + ":所有轴已连接, 旋转轴开始原点返回");
}
private static void ToRunning(string msg)
{
if (String.IsNullOrEmpty(msg))
{
msg = "当前为过板模式,转盘不需要复位,复位完成,进入运行状态";
}
WarnMsg = "";
LogUtil.info(Name + msg);
Status = TSAVStatus.Runing;
}
/// <summary> /// <summary>
/// 重置处理中 /// 重置处理中
/// </summary> /// </summary>
...@@ -218,29 +362,41 @@ namespace TSA_V.DeviceLibrary ...@@ -218,29 +362,41 @@ namespace TSA_V.DeviceLibrary
{ {
isTimeOut = true; isTimeOut = true;
} }
//LedManager.LedOFFALL();
if (resetStep.Equals(ResetStep.AddNode_1))
{
// LogUtil.info(Name + "重置中:XYNodeOnline_2 XY已经到待机点,判断旋转轴是否上线");
resetStep = ResetStep.XYNodeOnline_2; //LedManager.LedOFFALL();
} //if (resetStep.Equals(ResetStep.AddNode_1))
else if (resetStep.Equals(ResetStep.XYNodeOnline_2)) //{
{ // // LogUtil.info(Name + "重置中:XYNodeOnline_2 XY已经到待机点,判断旋转轴是否上线");
// resetStep = ResetStep.XYNodeOnline_2;
//}
if (resetStep.Equals(ResetStep.AddNode_1))
{
if (span.TotalSeconds > 10)
{
isTimeOut = true;
}
//判断旋转轴是否已经上线 //判断旋转轴是否已经上线
bool isAllOk = true; bool isAllOk = true;
bool lineOk = true;
SLAVE_STATUS rStatus = new SLAVE_STATUS(); SLAVE_STATUS rStatus = new SLAVE_STATUS();
foreach (Dictionary<int, NodeInfo> map in RotateMap.Values) if (WorkModeUtil.OnlyGuoBan)
{ {
foreach (NodeInfo node in map.Values) LogUtil.info(Name + "重置中 " + resetStep + ":InitNode OnlyGuoBan 模式,不需要验证转盘是否在线 ");
}
else
{
foreach (Dictionary<int, NodeInfo> map in RotateMap.Values)
{ {
foreach (NodeInfo node in map.Values)
PUSICANControl.PUSICO_GetNodeStatus(node.NodeId, ref rStatus);
if (!rStatus.Equals(SLAVE_STATUS.SLAVESTATUS_WORK))
{ {
timeOutMsg = ResourceControl.GetString(ResourceControl.RNodeOnLine, " 旋转轴[{0}][{1}]上线", node.NodeId, rStatus); PUSICANControl.PUSICO_GetNodeStatus(node.NodeId, ref rStatus);
isAllOk = false; if (!rStatus.Equals(SLAVE_STATUS.SLAVESTATUS_WORK))
break; {
timeOutMsg = ResourceControl.GetString(ResourceControl.RNodeOnLine, " 旋转轴[{0}][{1}]上线", node.NodeId, rStatus);
isAllOk = false;
break;
}
} }
} }
} }
...@@ -251,38 +407,36 @@ namespace TSA_V.DeviceLibrary ...@@ -251,38 +407,36 @@ namespace TSA_V.DeviceLibrary
{ {
timeOutMsg = ResourceControl.GetString(ResourceControl.RNodeOnLine, " 调宽轴[{0}][{1}]上线", LWidthManager.Line_NodeAddr, rStatus); timeOutMsg = ResourceControl.GetString(ResourceControl.RNodeOnLine, " 调宽轴[{0}][{1}]上线", LWidthManager.Line_NodeAddr, rStatus);
isAllOk = false; isAllOk = false;
} lineOk = false;
}
} }
if (isAllOk.Equals(true))
if (WorkModeUtil.OnlyGuoBan)
{ {
//初始化所有旋转轴 if (lineOk)
foreach (Dictionary<int, NodeInfo> map in RotateMap.Values) {
{ ToRunning("当前为过板模式,转盘不需要复位,复位完成,进入运行状态");
foreach (NodeInfo node in map.Values)
{
PUSICANControl.InitRNodeConfig(node.NodeId);
Thread.Sleep(10);
}
}
if (!IOBase.NoLine)
{
PUSICANControl.InitRNodeConfig(LWidthManager.Line_NodeAddr, true);
Thread.Sleep(10);
}
//所有轴原点返回
foreach (Dictionary<int, NodeInfo> map in RotateMap.Values)
{
foreach (NodeInfo node in map.Values)
{
PUSICANControl.HomeMove(node.NodeId);
Thread.Sleep(10);
}
} }
// PUSICANControl.HomeMove(LWidthManager.Line_NodeAddr);
resetStep = ResetStep.XYHomeMove_3;
LastResetChangeTime = DateTime.Now;
LogUtil.info(Name + "重置中:所有轴已连接, 旋转轴开始原点返回");
} }
else if (isAllOk.Equals(true))
{
LogUtil.info(Name + "重置中 " + resetStep + ":所有轴已连接");
//开始回原点
XYHomeMove_3();
}
//else if (isTimeOut)
//{
// if (lineOk)
// {
// WorkModeUtil.SelectMode(Name);
// //如果是过板模式,直接结束复位
// if (WorkModeUtil.OnlyGuoBan)
// {
// ToRunning("当前为过板模式,转盘不需要复位,复位完成,进入运行状态");
// }
// }
//}
} }
else if (resetStep.Equals(ResetStep.XYHomeMove_3)) else if (resetStep.Equals(ResetStep.XYHomeMove_3))
{ {
...@@ -314,9 +468,9 @@ namespace TSA_V.DeviceLibrary ...@@ -314,9 +468,9 @@ namespace TSA_V.DeviceLibrary
PUSICANControl.DefatutPosMove(node.NodeId, TSAVBean.RotateNode_DefaultPosition, 0); PUSICANControl.DefatutPosMove(node.NodeId, TSAVBean.RotateNode_DefaultPosition, 0);
} }
} }
LogUtil.info(Name + "重置中:所有旋转轴原点返回完成,开始到待机点:" + TSAVBean.RotateNode_DefaultPosition);
resetStep = ResetStep.RNodeOnline_4; resetStep = ResetStep.RNodeOnline_4;
LogUtil.info(Name + "重置中 "+resetStep+":所有旋转轴原点返回完成,开始到待机点:" + TSAVBean.RotateNode_DefaultPosition);
LastResetChangeTime = DateTime.Now; LastResetChangeTime = DateTime.Now;
} }
} }
...@@ -344,9 +498,7 @@ namespace TSA_V.DeviceLibrary ...@@ -344,9 +498,7 @@ namespace TSA_V.DeviceLibrary
//} //}
if (isAllOk.Equals(true)) if (isAllOk.Equals(true))
{ {
WarnMsg = ""; ToRunning("重置完成:所有旋转轴回到待机点");
LogUtil.info(Name + "重置完成:所有旋转轴回到待机点!");
Status = TSAVStatus.Runing;
} }
} }
if (isTimeOut) if (isTimeOut)
...@@ -469,18 +621,61 @@ namespace TSA_V.DeviceLibrary ...@@ -469,18 +621,61 @@ namespace TSA_V.DeviceLibrary
} }
if (!(Work.IsWaitMove)) if (!(Work.IsWaitMove))
{ {
TimeSpan span = DateTime.Now - Work.endWorkTime; TimeSpan span = DateTime.Now - Work.endWorkTime;
bool IsFootOk = IOManager.IOValue(IOManager.Footrest_Single).Equals(IO_VALUE.HIGH) && (WorkMode.Equals(0)); bool IsFootOk = IOManager.IOValue(IOManager.Footrest_Single).Equals(IO_VALUE.HIGH) && (WorkMode.Equals(0));
if (Work.WorkType.Equals(1)) if (Work.WorkType.Equals(1))
{ {
//等待脚踏板信号
if (IsFootOk if (WorkMode.Equals(1))
|| (span.TotalSeconds > AuToModeSeconds && IsDebug) {
|| (span.TotalSeconds > AuToModeSeconds && WorkMode.Equals(1)) if (IsFootOk)
) {
if (WorkPause)
{
LogUtil.info("自动模式下 已暂停:再次踩脚踏信号,退出暂停状态,重置Work.endWorkTime");
Work.endWorkTime = new DateTime();
WorkPause = false;
}
else
{
LogUtil.info("自动模式下:收到脚踏信号,自动模式暂停,重置Work.endWorkTime");
Work.endWorkTime = new DateTime();
WorkPause = true;
}
}
else if (WorkPause)
{
//暂停中
}
else
{
//自动模式
if ((span.TotalSeconds > AuToModeSeconds && IsDebug)
|| (span.TotalSeconds > AuToModeSeconds && WorkMode.Equals(1))
)
{
Work.MoveToNextPoint(true);
}
}
}
else
{ {
Work.MoveToNextPoint(true); //脚踏模式
if (IsFootOk
|| (span.TotalSeconds > AuToModeSeconds && IsDebug))
{
Work.MoveToNextPoint(true);
}
} }
////等待脚踏板信号
//if (IsFootOk
// || (span.TotalSeconds > AuToModeSeconds && IsDebug)
// || (span.TotalSeconds > AuToModeSeconds && WorkMode.Equals(1))
// )
//{
// Work.MoveToNextPoint(true);
//}
} }
else if (Work.WorkType.Equals(2) || Work.WorkType.Equals(3)) else if (Work.WorkType.Equals(2) || Work.WorkType.Equals(3))
{ {
...@@ -664,7 +859,7 @@ namespace TSA_V.DeviceLibrary ...@@ -664,7 +859,7 @@ namespace TSA_V.DeviceLibrary
} }
else if (TSAVBean.Status.Equals(TSAVStatus.Wait)) else if (TSAVBean.Status.Equals(TSAVStatus.Wait))
{ {
ShowMsg = ResourceControl.GetString(ResourceControl.DeviceNotStart, "设备未启动"); ShowMsg = ResourceControl.GetString(ResourceControl.DeviceNotStart, "设备未启动")+" "+startRunMsg;
} }
else if (TSAVBean.Status.Equals(TSAVStatus.Reset)) else if (TSAVBean.Status.Equals(TSAVStatus.Reset))
{ {
......
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Xml.Linq;
using TSA_V.Common;
namespace TSA_V.DeviceLibrary
{
/// <summary>
/// 工作模式选择
/// </summary>
public class WorkModeUtil
{
/// <summary>
/// 只能进入过板模式
/// </summary>
public static bool OnlyGuoBan = false;
public static bool WaitSelect = false;
private static bool IsSelected = false;
public static event ModeBoxShow boxShowEvent;
public delegate DialogResult ModeBoxShow(string msg,string okMsg);
public static event CheckModeEnd checkModeEndEvent;
public delegate void CheckModeEnd( );
public static void ModeCheckEnd()
{
WorkModeUtil.checkModeEndEvent?.Invoke();
}
internal static void SelectMode(string Name)
{
if (IsSelected)
{
return;
}
try
{
WaitSelect = true;
//如果超时,且调宽轴已上线,旋转轴上线失败,提示是否进入过板模式
IsSelected = true;
LogUtil.error(Name + " 询问是否进入过板模式");
//DialogResult result = MessageBox.Show("料塔加载失败,是否进入过板模式?", "提示", MessageBoxButtons.OKCancel, MessageBoxIcon.Warning);
string msg = ResourceControl.GetString("SelectModeMsg", "料塔加载失败,是否进入过板模式?");
string okMsg = ResourceControl.GetString("SelectModeMsgOK", "您已选择流水线过板模式");
DialogResult result = (DialogResult)(boxShowEvent?.Invoke(msg, okMsg));
LogUtil.error(Name + " 询问是否进入过板模式 ,结果:" + result.ToString());
if (result.Equals(DialogResult.OK))
{
OnlyGuoBan = true;
LogUtil.info(Name + " 选择过板模式,不需要复位料塔");
}
else
{
LogUtil.info(Name + " 继续复位料塔");
}
}
catch(Exception ex)
{
LogUtil.error("询问是否进入过板模式出错:"+ex.ToString());
}finally
{
ModeCheckEnd();
WaitSelect = false;
}
}
}
}
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<configuration> <configuration>
<configSections> <configSections>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net"/> <section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net" />
</configSections> </configSections>
<appSettings> <appSettings>
<!--开机自动运行--> <!--开机自动运行-->
<add key="App_AutoRun" value="1"/> <add key="App_AutoRun" value="1" />
<add key="CodeRun" value="0"/> <add key="CodeRun" value="0" />
<add key="IsDebug" value="1"/> <add key="IsDebug" value="1" />
<add key="IsNeedCount" value="1"/> <add key="IsNeedCount" value="1" />
<add key="CameraName" value="GigE:MV-CE100-30GC (00D18064699)"/> <add key="CameraName" value="GigE:MV-CE100-30GC (00D18064699)" />
<!--界面标题--> <!--界面标题-->
<add key="App_Title" value="SmartWorkstation"/> <add key="App_Title" value="SmartWorkstation" />
<!--默认语言--> <!--默认语言-->
<add key="Default_Language" value="zh-CN"/> <add key="Default_Language" value="zh-CN" />
<!--电路板配置路径--> <!--电路板配置路径-->
<add key="Board_ConfigPath" value="\config\boardData.txt"/> <add key="Board_ConfigPath" value="\config\boardData.txt" />
<!--自动焊接的exe地址--> <!--自动焊接的exe地址-->
<add key="AuToSoldering_FilePath" value="\Debug\SolderingRobot\SolderingRobot.exe"/> <add key="AuToSoldering_FilePath" value="\Debug\SolderingRobot\SolderingRobot.exe" />
<!--元器件配置路径--> <!--元器件配置路径-->
<add key="Component_ConfigPath" value="\config\componentData.txt"/> <add key="Component_ConfigPath" value="\config\componentData.txt" />
<!--元器件库模板地址--> <!--元器件库模板地址-->
<add key="Componet_Template" value="\config\元器件信息模板.csv"/> <add key="Componet_Template" value="\config\元器件信息模板.csv" />
<add key="Componet_Template_zh-CN" value="\config\元器件信息模板.csv"/> <add key="Componet_Template_zh-CN" value="\config\元器件信息模板.csv" />
<add key="Componet_Template_en-US" value="\config\BOM-US.csv"/> <add key="Componet_Template_en-US" value="\config\BOM-US.csv" />
<add key="ComPath_Config" value="\config\componet\"/> <add key="ComPath_Config" value="\config\componet\" />
<!--电路板图片保存路径--> <!--电路板图片保存路径-->
<add key="Board_Image_Path" value="config\image\"/> <add key="Board_Image_Path" value="config\image\" />
<!--电路板默认图片--> <!--电路板默认图片-->
<add key="BOARD_IMAGE_DEFAULT" value="defaultBoard.jpg"/> <add key="BOARD_IMAGE_DEFAULT" value="defaultBoard.jpg" />
<!--料格位置配置--> <!--料格位置配置-->
<add key="Position_Config" value="\config\Positions.csv"/> <add key="Position_Config" value="\config\Positions.csv" />
<!--使用AIOIO模块 <!--使用AIOIO模块
0=康耐得 0=康耐得
1=零点 1=零点
2=南京实点 2=南京实点
3=泥人科技,无线体 3=泥人科技,无线体
--> -->
<add key="UseAIOBOX" value="3"/> <add key="UseAIOBOX" value="1" />
<!--IO模块配置--> <!--IO模块配置-->
<add key="IO_IP" value="192.168.200.11"/> <add key="IO_IP" value="192.168.200.11" />
<add key="IO_Port" value="502"/> <add key="IO_Port" value="502" />
<add key="PUSICAN_Ip" value="192.168.0.178"/> <add key="PUSICAN_Ip" value="192.168.0.178" />
<add key="PUSICAN_Port" value="4001"/> <add key="PUSICAN_Port" value="4001" />
<!--料格旋转轴配置 一圈=57230 /11=5200--> <!--料格旋转轴配置 一圈=57230 /11=5200-->
<add key="RotateNode_DefaultPosition" value="-1500"/> <add key="RotateNode_DefaultPosition" value="-1500" />
<add key="RotateNode_MicroStepping" value="64"/> <add key="RotateNode_MicroStepping" value="64" />
<add key="RotateNode_MaxSpeed" value="20000"/> <add key="RotateNode_MaxSpeed" value="20000" />
<add key="RotateNode_StartSpeed" value="8000"/> <add key="RotateNode_StartSpeed" value="8000" />
<add key="RotateNode_StopSpeed" value="8000"/> <add key="RotateNode_StopSpeed" value="8000" />
<add key="RotateNode_HomeSpeed" value="2000"/> <add key="RotateNode_HomeSpeed" value="2000" />
<add key="RotateNode_HomeStartSpeed" value="1000"/> <add key="RotateNode_HomeStartSpeed" value="1000" />
<add key="RotateNode_HomeStopSpeed" value="1000"/> <add key="RotateNode_HomeStopSpeed" value="1000" />
<add key="RotateNode_AddSpeed" value="8"/> <add key="RotateNode_AddSpeed" value="8" />
<add key="RotateNode_DelSpeed" value="8"/> <add key="RotateNode_DelSpeed" value="8" />
<add key="RotateNode_MaxPhaseCurrent" value="800"/> <add key="RotateNode_MaxPhaseCurrent" value="1500" />
<add key="RotateNode_DelPhaseCurrent" value="2"/> <add key="RotateNode_DelPhaseCurrent" value="2" />
<add key="Position_Change_Value" value="100"/> <add key="Position_Change_Value" value="100" />
<add key="TSAV_Storage_Count" value="2"/> <add key="TSAV_Storage_Count" value="2" />
<add key="RNode_Addr_1_1" value="1"/> <add key="RNode_Addr_1_1" value="1" />
<add key="RNode_Addr_1_2" value="2"/> <add key="RNode_Addr_1_2" value="2" />
<add key="RNode_Addr_1_3" value="3"/> <add key="RNode_Addr_1_3" value="3" />
<add key="RNode_Addr_1_4" value="4"/> <add key="RNode_Addr_1_4" value="4" />
<add key="RNode_Addr_1_5" value="5"/> <add key="RNode_Addr_1_5" value="5" />
<add key="RNode_Addr_2_1" value="6"/> <add key="RNode_Addr_2_1" value="6" />
<add key="RNode_Addr_2_2" value="7"/> <add key="RNode_Addr_2_2" value="7" />
<add key="RNode_Addr_2_3" value="8"/> <add key="RNode_Addr_2_3" value="8" />
<add key="RNode_Addr_2_4" value="9"/> <add key="RNode_Addr_2_4" value="9" />
<add key="RNode_Addr_2_5" value="10"/> <add key="RNode_Addr_2_5" value="10" />
<add key="app.title" value="智能组装工作站"/> <add key="app.title" value="智能组装工作站" />
<!--0=脚踏模式,1=自动模式,间隔指定的时间自动下一步--> <!--0=脚踏模式,1=自动模式,间隔指定的时间自动下一步-->
<add key="WorkMode" value="1"/> <add key="WorkMode" value="1" />
<!-- 自动模式间隔时间/秒--> <!-- 自动模式间隔时间/秒-->
<add key="AuToModeSeconds" value="5"/> <add key="AuToModeSeconds" value="5" />
<add key="WorkCount_ConfigPath" value="\config\workCount.json"/> <add key="WorkCount_ConfigPath" value="\config\workCount.json" />
<!--元器件库名称的类型,0=英文,1=中文--> <!--元器件库名称的类型,0=英文,1=中文-->
<add key="LibNameType" value="1"/> <add key="LibNameType" value="1" />
<!--AOI程序文件夹--> <!--AOI程序文件夹-->
<add key="AOIFileConfig" value="\config\AOIConfig\"/> <add key="AOIFileConfig" value="\config\AOIConfig\" />
<!--是否启动AOI--> <!--是否启动AOI-->
<add key="IsNeedAOI" value="0"/> <add key="IsNeedAOI" value="1" />
<add key="DefaultPointSize" value="5"/> <add key="DefaultPointSize" value="5" />
<add key="DefaultPointType" value="1"/> <add key="DefaultPointType" value="1" />
<add key="Config_Pwd" value="123456"/> <add key="Config_Pwd" value="123456" />
<!--调宽配置:电机回原点速度--> <!--调宽配置:电机回原点速度-->
<add key="Line_HomeSpeed" value="2020"/> <add key="Line_HomeSpeed" value="2020" />
<add key="Line_HomeStartSpeed" value="1000"/> <add key="Line_HomeStartSpeed" value="1000" />
<add key="Line_HomeStopSpeed" value="1000"/> <add key="Line_HomeStopSpeed" value="1000" />
<add key="Line_MicroStepping" value="4"/> <add key="Line_MicroStepping" value="4" />
<add key="Line_MaxSpeed" value="2000"/> <add key="Line_MaxSpeed" value="2000" />
<add key="Line_StartSpeed" value="1000"/> <add key="Line_StartSpeed" value="1000" />
<add key="Line_StopSpeed" value="1000"/> <add key="Line_StopSpeed" value="1000" />
<add key="Line_AddSpeed" value="8"/> <add key="Line_AddSpeed" value="8" />
<add key="Line_DelSpeed" value="8"/> <add key="Line_DelSpeed" value="8" />
<add key="Line_MaxPhaseCurrent" value="2200"/> <add key="Line_MaxPhaseCurrent" value="4500" />
<add key="Line_DelPhaseCurrent" value="2"/> <add key="Line_DelPhaseCurrent" value="2" />
<!--调宽配置:电机回原点后的宽度--> <!--调宽配置:电机回原点后的宽度-->
<add key="Line_HomeWidth" value="508"/> <add key="Line_HomeWidth" value="508" />
<!--调宽配置:宽度转换系数,1mm对应的电机位置--> <!--调宽配置:宽度转换系数,1mm对应的电机位置-->
<add key="Line_ChangeValue" value="200"/> <add key="Line_ChangeValue" value="200" />
<!--调宽配置:调宽伺服地址--> <!--调宽配置:调宽伺服地址-->
<add key="Line_NodeAddr" value="11"/> <add key="Line_NodeAddr" value="11" />
<!--流水线最后一次调的宽度--> <!--流水线最后一次调的宽度-->
<add key="Line_LastWidth" value="400"/> <add key="Line_LastWidth" value="400" />
<!--宽度对应位置配置--> <!--宽度对应位置配置-->
<add key="Line_WidthPosition" value=""/> <add key="Line_WidthPosition" value="" />
<add key="Server_Log_Open" value="0"/> <add key="Server_Log_Open" value="0" />
<!--本地开放的http服务器端口号--> <!--本地开放的http服务器端口号-->
<add key="WebServiceAddr" value="http://localhost:4090/rest/api/v1/station/"/> <add key="WebServiceAddr" value="http://localhost:4090/rest/api/v1/station/" />
<!--组装完成后上传数据的服务器地址--> <!--组装完成后上传数据的服务器地址-->
<!--<add key="DCSServerAddr" value="http://192.168.8.1:1007/DCS_Integration/Cartridge.asmx?op=CartridgeInfo" />--> <!--<add key="DCSServerAddr" value="http://192.168.8.1:1007/DCS_Integration/Cartridge.asmx?op=CartridgeInfo" />-->
<!--组装工作前,需要输入pcb板条码--> <!--组装工作前,需要输入pcb板条码-->
<add key="NeedPCBCode" value="0"/> <add key="NeedPCBCode" value="0" />
<!--是否调整气缸顺序,配置1时,侧挡气缸前进,底部气缸在上升--> <!--是否调整气缸顺序,配置1时,侧挡气缸前进,底部气缸在上升-->
<add key="SideCylinderMoveFirst" value="1"/> <add key="SideCylinderMoveFirst" value="1" />
<!--是否启用工作区信号触发开始工作--> <!--是否启用工作区信号触发开始工作-->
<add key="WorkSingleStart" value="0"/> <add key="WorkSingleStart" value="0" />
<!--点位描述显示类型--> <!--点位描述显示类型-->
<add key="PointDisplayType" value="1"/> <add key="PointDisplayType" value="1" />
</appSettings> </appSettings>
<log4net> <log4net>
<appender name="defaultAppender" type="log4net.Appender.RollingFileAppender"> <appender name="defaultAppender" type="log4net.Appender.RollingFileAppender">
<file value="logs/TSA_V.log"/> <file value="logs/TSA_V.log" />
<param name="Encoding" value="UTF-8"/> <param name="Encoding" value="UTF-8" />
<appendToFile value="true"/> <appendToFile value="true" />
<rollingStyle value="Date"/> <rollingStyle value="Date" />
<datePattern value="yyyy-MM-dd"/> <datePattern value="yyyy-MM-dd" />
<layout type="log4net.Layout.PatternLayout"> <layout type="log4net.Layout.PatternLayout">
<conversionPattern value="[%date][%t]%-5p %m%n"/> <conversionPattern value="[%date][%t]%-5p %m%n" />
</layout> </layout>
</appender> </appender>
<appender name="MetcalLogAppender" type="log4net.Appender.RollingFileAppender"> <appender name="MetcalLogAppender" type="log4net.Appender.RollingFileAppender">
<file value="logs/metcal/revicedata.log"/> <file value="logs/metcal/revicedata.log" />
<param name="Encoding" value="UTF-8"/> <param name="Encoding" value="UTF-8" />
<appendToFile value="true"/> <appendToFile value="true" />
<rollingStyle value="Date"/> <rollingStyle value="Date" />
<datePattern value="yyyy-MM-dd"/> <datePattern value="yyyy-MM-dd" />
<layout type="log4net.Layout.PatternLayout"> <layout type="log4net.Layout.PatternLayout">
<conversionPattern value="[%date] %m%n"/> <conversionPattern value="[%date] %m%n" />
</layout> </layout>
</appender> </appender>
<logger name="defaultAppender"> <logger name="defaultAppender">
<level value="All"/> <level value="All" />
<appender-ref ref="defaultAppender"/> <appender-ref ref="defaultAppender" />
</logger> </logger>
<logger name="MetcalLogAppender"> <logger name="MetcalLogAppender">
<level value="Info"/> <level value="Info" />
<appender-ref ref="MetcalLogAppender"/> <appender-ref ref="MetcalLogAppender" />
</logger> </logger>
</log4net> </log4net>
<startup> <startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.8"/> <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
</startup> </startup>
<runtime> <runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral"/> <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-12.0.0.0" newVersion="12.0.0.0"/> <bindingRedirect oldVersion="0.0.0.0-12.0.0.0" newVersion="12.0.0.0" />
</dependentAssembly> </dependentAssembly>
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="log4net" culture="neutral" publicKeyToken="669e0ddf0bb1aa2a"/> <assemblyIdentity name="log4net" culture="neutral" publicKeyToken="669e0ddf0bb1aa2a" />
<bindingRedirect oldVersion="0.0.0.0-2.0.12.0" newVersion="2.0.12.0"/> <bindingRedirect oldVersion="0.0.0.0-2.0.12.0" newVersion="2.0.12.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Collections.Concurrent" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Collections.Concurrent" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Collections" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Collections" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.ComponentModel" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.ComponentModel" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.ComponentModel.EventBasedAsync" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.ComponentModel.EventBasedAsync" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Data.Common" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Data.Common" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Diagnostics.Contracts" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Diagnostics.Contracts" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Diagnostics.Debug" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Diagnostics.Debug" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Diagnostics.StackTrace" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Diagnostics.StackTrace" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Diagnostics.Tools" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Diagnostics.Tools" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Diagnostics.Tracing" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Diagnostics.Tracing" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Dynamic.Runtime" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Dynamic.Runtime" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Globalization" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Globalization" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Globalization.Extensions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Globalization.Extensions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.IO.Compression" publicKeyToken="b77a5c561934e089" culture="neutral"/> <assemblyIdentity name="System.IO.Compression" publicKeyToken="b77a5c561934e089" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.IO" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.IO" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Linq" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Linq" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Linq.Expressions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Linq.Expressions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Linq.Parallel" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Linq.Parallel" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Linq.Queryable" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Linq.Queryable" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Net.Http" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Net.Http" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.0.0" newVersion="4.0.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.0.0" newVersion="4.0.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Net.NetworkInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Net.NetworkInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Net.Primitives" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Net.Primitives" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Net.Requests" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Net.Requests" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Net.Sockets" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Net.Sockets" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.ObjectModel" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.ObjectModel" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Reflection" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Reflection" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Reflection.Extensions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Reflection.Extensions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Reflection.Primitives" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Reflection.Primitives" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Resources.ResourceManager" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Resources.ResourceManager" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Runtime" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Runtime" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Runtime.Extensions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Runtime.Extensions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Runtime.InteropServices" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Runtime.InteropServices" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.2.0" newVersion="4.0.2.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.2.0" newVersion="4.0.2.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Runtime.Numerics" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Runtime.Numerics" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Runtime.Serialization.Json" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Runtime.Serialization.Json" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Runtime.Serialization.Primitives" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Runtime.Serialization.Primitives" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Runtime.Serialization.Xml" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Runtime.Serialization.Xml" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.3.0" newVersion="4.1.3.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.3.0" newVersion="4.1.3.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Security.Cryptography.Algorithms" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Security.Cryptography.Algorithms" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.3.0.0" newVersion="4.3.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.3.0.0" newVersion="4.3.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Security.Principal" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Security.Principal" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Security.SecureString" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Security.SecureString" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Text.Encoding" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Text.Encoding" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Text.Encoding.Extensions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Text.Encoding.Extensions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Text.RegularExpressions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Text.RegularExpressions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.1.0" newVersion="4.1.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.1.0" newVersion="4.1.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Threading" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Threading" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Threading.Overlapped" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Threading.Overlapped" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Threading.Tasks" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Threading.Tasks" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Threading.Tasks.Parallel" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Threading.Tasks.Parallel" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Threading.Timer" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Threading.Timer" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.ValueTuple" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral"/> <assemblyIdentity name="System.ValueTuple" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.2.0" newVersion="4.0.2.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.2.0" newVersion="4.0.2.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Xml.ReaderWriter" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Xml.ReaderWriter" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.1.0" newVersion="4.1.1.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.1.0" newVersion="4.1.1.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Xml.XDocument" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Xml.XDocument" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Xml.XmlSerializer" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Xml.XmlSerializer" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/> <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Xml.XPath.XDocument" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/> <assemblyIdentity name="System.Xml.XPath.XDocument" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0"/> <bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0" />
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
</runtime> </runtime>
......
...@@ -32,8 +32,13 @@ namespace TSA_V ...@@ -32,8 +32,13 @@ namespace TSA_V
private void btnPosition_Click(object sender, EventArgs e) private void btnPosition_Click(object sender, EventArgs e)
{ {
string msg = ""; string msg = "";
if (WorkModeUtil.OnlyGuoBan)
{
msg = ResourceControl.GetString("GuobanMode", "操作失败,当前为过板模式");
}
//复位完成才能打开 //复位完成才能打开
if (TSAVBean.IsInSuddenDown) else if (TSAVBean.IsInSuddenDown)
{ {
msg = ResourceControl.GetString(ResourceControl.DeviceInSuddenStop, "设备急停中"); msg = ResourceControl.GetString(ResourceControl.DeviceInSuddenStop, "设备急停中");
} }
...@@ -48,8 +53,10 @@ namespace TSA_V ...@@ -48,8 +53,10 @@ namespace TSA_V
if (!String.IsNullOrEmpty(msg)) if (!String.IsNullOrEmpty(msg))
{ {
MessageBox.Show(msg); MessageBoxMidle.Show(this, msg, ResourceCulture.GetString("提示"), MessageBoxButtons.OK, MessageBoxIcon.Error);
return; return;
//MessageBox.Show(msg);
//return;
} }
FrmPusicanTest frmCom = new FrmPusicanTest(); FrmPusicanTest frmCom = new FrmPusicanTest();
this.Visible = false; this.Visible = false;
......
...@@ -20,9 +20,9 @@ using Asa; ...@@ -20,9 +20,9 @@ using Asa;
namespace TSA_V namespace TSA_V
{ {
public partial class FrmMenu : FrmBase public partial class FrmMenu : FrmBase
{ {
public static FrmMenu frmMain = null; public static FrmMenu frmMain = null;
private bool isClick = false; private bool isClick = false;
public FrmMenu() public FrmMenu()
{ //设置语言 { //设置语言
...@@ -38,13 +38,13 @@ namespace TSA_V ...@@ -38,13 +38,13 @@ namespace TSA_V
if (FormManager.UserInfo.Limit.Equals(UserLimit.Admin) || FormManager.UserInfo.Limit.Equals(UserLimit.Debug)) if (FormManager.UserInfo.Limit.Equals(UserLimit.Admin) || FormManager.UserInfo.Limit.Equals(UserLimit.Debug))
{ {
btnProduct.Visible = true; btnProduct.Visible = true;
btnCom.Visible = true; btnCom.Visible = true;
} }
else else
{ {
btnProduct.Visible = false; btnProduct.Visible = false;
btnCom.Visible = false ; btnCom.Visible = false;
} }
lblMsg.Text = ""; lblMsg.Text = "";
//if (FormManager.UserInfo.Limit.Equals(UserLimit.Admin)) //if (FormManager.UserInfo.Limit.Equals(UserLimit.Admin))
...@@ -66,7 +66,7 @@ namespace TSA_V ...@@ -66,7 +66,7 @@ namespace TSA_V
} }
private void btnWork_Click(object sender, EventArgs e) private void btnWork_Click(object sender, EventArgs e)
{ {
// Speak("你点击了开始工作"); // Speak("你点击了开始工作");
GC.Collect(); GC.Collect();
//if (TSAVBean.IsInRunTest()) //if (TSAVBean.IsInRunTest())
...@@ -92,42 +92,43 @@ namespace TSA_V ...@@ -92,42 +92,43 @@ namespace TSA_V
// return; // return;
//} //}
this.Visible = false; ; this.Visible = false; ;
isClick = true; isClick = true;
FrmBoardList.instance.Show(); FrmBoardList.instance.Show();
FrmBoardList.instance.LoadCom(); FrmBoardList.instance.LoadCom();
} }
private bool useLed = false; private bool useLed = false;
private System.Timers.Timer timer = new System.Timers.Timer(); private System.Timers.Timer timer = new System.Timers.Timer();
private void FrmMenu_Load(object sender, EventArgs e) private void FrmMenu_Load(object sender, EventArgs e)
{ {
DB.userName = FormManager.UserInfo.Name; DB.userName = FormManager.UserInfo.Name;
string time = GetVersion(true); string time = GetVersion(true);
System.Reflection.AssemblyName assemblyName = System.Reflection.Assembly.GetExecutingAssembly().GetName(); System.Reflection.AssemblyName assemblyName = System.Reflection.Assembly.GetExecutingAssembly().GetName();
lblVersion.Text = "V" + assemblyName.Version.ToString() ; lblVersion.Text = "V" + assemblyName.Version.ToString();
lblVersion.Text = "V3.0"; lblVersion.Text = "V3.0";
//lblVersion.Text = "V" + assemblyName.Version.ToString() + "(" + time + ")"; //lblVersion.Text = "V" + assemblyName.Version.ToString() + "(" + time + ")";
LblUserName.Text = FormManager.UserInfo.Name + "/" + FormManager.UserInfo.Limit; LblUserName.Text = FormManager.UserInfo.Name + "/" + FormManager.UserInfo.Limit;
Task.Factory.StartNew(delegate Task.Factory.StartNew(delegate
{ {
LoadBackImage(); LoadBackImage();
}); });
WorkModeUtil.boxShowEvent += WorkModeUtil_boxShowEvent;
WorkModeUtil.checkModeEndEvent += WorkModeUtil_checkModeEndEvent;
this.Enabled = false;
//加载板卡 //加载板卡
BoardManager.LoadBoard(); BoardManager.LoadBoard();
WorkCountManager.LoadData(); WorkCountManager.LoadData();
string positionFileName = CSVPositionReader<TSAVPosition>.getPositionFilePath(); string positionFileName = CSVPositionReader<TSAVPosition>.getPositionFilePath();
//加载位置 //加载位置
LoadCSVLibrary.CSVPositionReader<TSAVPosition>.LoadFile(positionFileName); LoadCSVLibrary.CSVPositionReader<TSAVPosition>.LoadFile(positionFileName);
CSVBomManager.LoadAllCom(); CSVBomManager.LoadAllCom();
//加载设备信息 //加载设备信息
TSAVBean.LoadTSAV(); TSAVBean.LoadTSAV();
//需要链接IO //需要链接IO
timer.AutoReset = true; timer.AutoReset = true;
timer.Interval = 1000; timer.Interval = 1000;
...@@ -137,14 +138,15 @@ namespace TSA_V ...@@ -137,14 +138,15 @@ namespace TSA_V
{ {
Task.Factory.StartNew(delegate Task.Factory.StartNew(delegate
{ {
TSAVBean.DeviceCheck();
IOManager.ConnectionIO(); IOManager.ConnectionIO();
TSAVBean.StartRun(); //TSAVBean.StartRun();
timer.Enabled = true; //timer.Enabled = true;
}); });
} }
LWidthManager.Init(); LWidthManager.Init();
this.Text = ConfigAppSettings.GetValue(Setting_Init.App_Title); this.Text = ConfigAppSettings.GetValue(Setting_Init.App_Title);
btnCloseLed.Visible = useLed; btnCloseLed.Visible = useLed;
btnOpenLed.Visible = useLed; btnOpenLed.Visible = useLed;
...@@ -153,21 +155,30 @@ namespace TSA_V ...@@ -153,21 +155,30 @@ namespace TSA_V
btnCom.Top = btnAOI.Top; btnCom.Top = btnAOI.Top;
btnCom.Left = btnAOI.Left; btnCom.Left = btnAOI.Left;
btnAOI.Visible = false; btnAOI.Visible = false;
}
}
try try
{ {
AccAOI.camera.CameraManager.LoadCamera(); AccAOI.camera.CameraManager.LoadCamera();
LogUtil.info("加载到相机:" + string.Join(";",AccAOI.camera.CameraManager.hikNameList.ToArray())); LogUtil.info("加载到相机:" + string.Join(";", AccAOI.camera.CameraManager.hikNameList.ToArray()));
this.Focus(); this.Focus();
SetMouseAtCenterScreen(); SetMouseAtCenterScreen();
} }
catch (Exception ex) catch (Exception ex)
{ {
LogUtil.error("加载相机出错:" + ex.ToString()); LogUtil.error("加载相机出错:" + ex.ToString());
} }
}
private void WorkModeUtil_checkModeEndEvent()
{
Task.Factory.StartNew(delegate
{
TSAVBean.StartRun();
timer.Enabled = true;
});
this.Enabled = true;
} }
public void LoadBackImage() public void LoadBackImage()
...@@ -176,7 +187,7 @@ namespace TSA_V ...@@ -176,7 +187,7 @@ namespace TSA_V
{ {
this.panel1.BackgroundImage = ImageManager.frm_背景图; this.panel1.BackgroundImage = ImageManager.frm_背景图;
// button1.BackgroundImage = ImageManager.Main_US_MOSCOT; // button1.BackgroundImage = ImageManager.Main_US_MOSCOT;
btnExit.BackgroundImage = ImageManager.Main_US_退出; btnExit.BackgroundImage = ImageManager.Main_US_退出;
this.btnMaintenance.BackgroundImage = ImageManager.Main_US_设备配置; this.btnMaintenance.BackgroundImage = ImageManager.Main_US_设备配置;
this.btnWork.BackgroundImage = ImageManager.Main_US_开始工作; this.btnWork.BackgroundImage = ImageManager.Main_US_开始工作;
...@@ -191,7 +202,7 @@ namespace TSA_V ...@@ -191,7 +202,7 @@ namespace TSA_V
else else
{ {
this.panel1.BackgroundImage = ImageManager.frm_背景图; this.panel1.BackgroundImage = ImageManager.frm_背景图;
// button1.BackgroundImage = ImageManager.Main_MOSCOT; // button1.BackgroundImage = ImageManager.Main_MOSCOT;
btnExit.BackgroundImage = ImageManager.Main_退出; btnExit.BackgroundImage = ImageManager.Main_退出;
this.btnMaintenance.BackgroundImage = ImageManager.Main_设备配置; this.btnMaintenance.BackgroundImage = ImageManager.Main_设备配置;
this.btnWork.BackgroundImage = ImageManager.Main_开始工作; this.btnWork.BackgroundImage = ImageManager.Main_开始工作;
...@@ -255,10 +266,10 @@ namespace TSA_V ...@@ -255,10 +266,10 @@ namespace TSA_V
} }
//MetcalManager.ColseAllPort(); //MetcalManager.ColseAllPort();
AccAOI.camera.CameraManager.CloseCamera(); AccAOI.camera.CameraManager.CloseCamera();
// PUSICANControl.Close(); // PUSICANControl.Close();
} }
private void FrmMenu_SizeChanged(object sender, EventArgs e) private void FrmMenu_SizeChanged(object sender, EventArgs e)
{ {
return; return;
...@@ -275,13 +286,13 @@ namespace TSA_V ...@@ -275,13 +286,13 @@ namespace TSA_V
//} //}
isClick = true; isClick = true;
if (FrmComponentList.instance != null && FrmComponentList.instance.Visible == false) if (FrmComponentList.instance != null && FrmComponentList.instance.Visible == false)
{ {
FrmComponentList.instance.LoadComList(); FrmComponentList.instance.LoadComList();
} }
FrmComponentList.instance.Show(); FrmComponentList.instance.Show();
this.Visible = false; this.Visible = false;
} }
private void btnChangeSkin_Click(object sender, EventArgs e) private void btnChangeSkin_Click(object sender, EventArgs e)
{ {
...@@ -292,13 +303,13 @@ namespace TSA_V ...@@ -292,13 +303,13 @@ namespace TSA_V
private void FrmMenu_Shown(object sender, EventArgs e) private void FrmMenu_Shown(object sender, EventArgs e)
{ {
//SetSkin(this); //SetSkin(this);
this.BackColor = Color.White; this.BackColor = Color.White;
TSAVBean.ShowPointEvent += TSAVBean_ShowPointEvent; TSAVBean.ShowPointEvent += TSAVBean_ShowPointEvent;
//showProjectorTimer.Start(); //showProjectorTimer.Start();
timer1.Start(); timer1.Start();
} }
private bool TSAVBean_ShowPointEvent(ProjectorPInfo p ) private bool TSAVBean_ShowPointEvent(ProjectorPInfo p)
{ {
FrmProjectorScreen.instance.ClearPoint(); FrmProjectorScreen.instance.ClearPoint();
FrmProjectorScreen.instance.ShowPoint(p); FrmProjectorScreen.instance.ShowPoint(p);
...@@ -312,10 +323,10 @@ namespace TSA_V ...@@ -312,10 +323,10 @@ namespace TSA_V
} }
private void btnMaintenance_Click(object sender, EventArgs e) private void btnMaintenance_Click(object sender, EventArgs e)
{ {
isClick = true; isClick = true;
FrmMaintenance.instance.Show(); FrmMaintenance.instance.Show();
this.Visible = false; this.Visible = false;
} }
private void btnExit_Click(object sender, EventArgs e) private void btnExit_Click(object sender, EventArgs e)
...@@ -323,7 +334,7 @@ namespace TSA_V ...@@ -323,7 +334,7 @@ namespace TSA_V
FrmProjectorScreen.instance.Close(); FrmProjectorScreen.instance.Close();
this.Close(); this.Close();
} }
private void btnOpenLed_Click(object sender, EventArgs e) private void btnOpenLed_Click(object sender, EventArgs e)
{ {
...@@ -343,8 +354,8 @@ namespace TSA_V ...@@ -343,8 +354,8 @@ namespace TSA_V
return; return;
} }
// IOManager.IOMove(IOManager.Camera_Led, IO_VALUE.LOW); // IOManager.IOMove(IOManager.Camera_Led, IO_VALUE.LOW);
btnCloseLed.Visible = false ; btnCloseLed.Visible = false;
btnOpenLed.Visible = true ; btnOpenLed.Visible = true;
} }
private void timer1_Tick(object sender, EventArgs e) private void timer1_Tick(object sender, EventArgs e)
...@@ -358,22 +369,23 @@ namespace TSA_V ...@@ -358,22 +369,23 @@ namespace TSA_V
bool result = FrmProjectorScreen.instance.ShowForm(); bool result = FrmProjectorScreen.instance.ShowForm();
} }
else if (sc.Length <= FrmProjectorScreen.instance.ScreenIndex && FrmProjectorScreen.instance.ISShow) else if (sc.Length <= FrmProjectorScreen.instance.ScreenIndex && FrmProjectorScreen.instance.ISShow)
{ {
FrmProjectorScreen.instance.Close(); FrmProjectorScreen.instance.Close();
FrmProjectorScreen.instance = new FrmProjectorScreen(); FrmProjectorScreen.instance = new FrmProjectorScreen();
LogUtil.info("检测到只有一个显示器,关闭投影界面"); LogUtil.info("检测到只有一个显示器,关闭投影界面");
} }
}catch(Exception ex) }
catch (Exception ex)
{ {
LogUtil.error("投影界面检测处理出错:" + ex.ToString()); LogUtil.error("投影界面检测处理出错:" + ex.ToString());
} }
} }
private void openForms() private void openForms()
{ {
FrmScreenTest form2 = new FrmScreenTest(); FrmScreenTest form2 = new FrmScreenTest();
form2.ScreenIndex = 1; form2.ScreenIndex = 1;
form2.Show(); form2.Show();
} }
private void btnScreenTest_Click(object sender, EventArgs e) private void btnScreenTest_Click(object sender, EventArgs e)
...@@ -397,12 +409,12 @@ namespace TSA_V ...@@ -397,12 +409,12 @@ namespace TSA_V
AOIManager.LoadAOIFile(null, ""); AOIManager.LoadAOIFile(null, "");
List<string> listb = new List<string>(AOIManager.FileList); List<string> listb = new List<string>(AOIManager.FileList);
listb.Insert(0, createnew); listb.Insert(0, createnew);
FrmSelectPoint frma = new FrmSelectPoint(ResourceCulture.GetString("FrmBoardSelect_Text", "请选择AOI"), listb, listb.Count>1?1:0); FrmSelectPoint frma = new FrmSelectPoint(ResourceCulture.GetString("FrmBoardSelect_Text", "请选择AOI"), listb, listb.Count > 1 ? 1 : 0);
DialogResult result = frma.ShowDialog(); DialogResult result = frma.ShowDialog();
if (result.Equals(DialogResult.OK)) if (result.Equals(DialogResult.OK))
{ {
string aoiName = listb[frma.SelectIndex]; string aoiName = listb[frma.SelectIndex];
string path = Application.StartupPath + ConfigAppSettings.GetValue(Setting_Init.AOIFileConfig); string path = Application.StartupPath + ConfigAppSettings.GetValue(Setting_Init.AOIFileConfig);
string fileName = ""; string fileName = "";
if (!aoiName.Equals("")) if (!aoiName.Equals(""))
...@@ -419,6 +431,14 @@ namespace TSA_V ...@@ -419,6 +431,14 @@ namespace TSA_V
private void btnReplenish_Click(object sender, EventArgs e) private void btnReplenish_Click(object sender, EventArgs e)
{ {
if (WorkModeUtil.OnlyGuoBan)
{
string msg = ResourceControl.GetString("GuobanMode", "操作失败,当前为过板模式");
MessageBoxMidle.Show(this, msg, ResourceCulture.GetString("提示"), MessageBoxButtons.OK, MessageBoxIcon.Error);
return;
}
List<BoardInfo> listb = new List<BoardInfo>(BoardManager.boardList); List<BoardInfo> listb = new List<BoardInfo>(BoardManager.boardList);
var ls = listb.Select((point) => { return point.boardName; }).ToList(); var ls = listb.Select((point) => { return point.boardName; }).ToList();
...@@ -457,5 +477,26 @@ namespace TSA_V ...@@ -457,5 +477,26 @@ namespace TSA_V
} }
} }
} }
private DialogResult WorkModeUtil_boxShowEvent(string msg, string okMsg)
{
return (DialogResult)this.Invoke(new MessageBoxShow(MessageBoxShow_F), new object[] { msg, okMsg });
}
delegate DialogResult MessageBoxShow(string msg, string okMsg);
DialogResult MessageBoxShow_F(string msg, string okMsg)
{
DialogResult result = MessageBoxMidle.Show(this, msg, ResourceCulture.GetString("提示"), MessageBoxButtons.OKCancel, MessageBoxIcon.Warning);
Task.Factory.StartNew(delegate
{
if (result.Equals(DialogResult.OK))
{
MessageBoxMidle.Show(this, okMsg, ResourceCulture.GetString("提示"), MessageBoxButtons.OK, MessageBoxIcon.Information);
}
});
return result;
}
} }
} }
此文件的差异太大,无法显示。
...@@ -2553,4 +2553,19 @@ ...@@ -2553,4 +2553,19 @@
<data name="CreateNew" xml:space="preserve"> <data name="CreateNew" xml:space="preserve">
<value>新建</value> <value>新建</value>
</data> </data>
<data name="FrmWork_lblPause_Text" xml:space="preserve">
<value>已暂停</value>
</data>
<data name="SelectModeMsg" xml:space="preserve">
<value>料塔加载失败,是否进入过板模式</value>
</data>
<data name="SelectModeMsgOK" xml:space="preserve">
<value>您已选择流水线过板模式</value>
</data>
<data name="加载AOI失败" xml:space="preserve">
<value>加载AOI失败</value>
</data>
<data name="GuobanMode" xml:space="preserve">
<value>操作失败,当前为过板模式</value>
</data>
</root> </root>
\ No newline at end of file \ No newline at end of file
...@@ -189,6 +189,7 @@ ...@@ -189,6 +189,7 @@
<Compile Include="FrmBoardPutCom.Designer.cs"> <Compile Include="FrmBoardPutCom.Designer.cs">
<DependentUpon>FrmBoardPutCom.cs</DependentUpon> <DependentUpon>FrmBoardPutCom.cs</DependentUpon>
</Compile> </Compile>
<Compile Include="messageBox\MessageBoxMidle.cs" />
<Compile Include="projector\FrmProjectorScreen.cs"> <Compile Include="projector\FrmProjectorScreen.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>
......
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace TSA_V
{
/***
* Title:"三维可视化" 项目
* 主题:【视图层】将MessageBox显示控制
* Description:
* 功能:
* 1、将MessageBox.Show显示在窗体中间
* Date:2020
* Version:1.2版本
* Author:Coffee
* Modify Recoder:
*/
public class MessageBoxMidle
{
private static IWin32Window _owner;
private static HookProc _hookProc;
private static IntPtr _hHook;
public static DialogResult Show(string text)
{
Initialize();
return MessageBox.Show(text);
}
public static DialogResult Show(string text, string caption)
{
Initialize();
return MessageBox.Show(text, caption);
}
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons)
{
Initialize();
return MessageBox.Show(text, caption, buttons);
}
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon)
{
Initialize();
return MessageBox.Show(text, caption, buttons, icon);
}
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defButton)
{
Initialize();
return MessageBox.Show(text, caption, buttons, icon, defButton);
}
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defButton, MessageBoxOptions options)
{
Initialize();
return MessageBox.Show(text, caption, buttons, icon, defButton, options);
}
public static DialogResult Show(IWin32Window owner, string text)
{
_owner = owner;
Initialize();
return MessageBox.Show(owner, text);
}
public static DialogResult Show(IWin32Window owner, string text, string caption)
{
_owner = owner;
Initialize();
return MessageBox.Show(owner, text, caption);
}
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons)
{
_owner = owner;
Initialize();
return MessageBox.Show(owner, text, caption, buttons);
}
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon)
{
_owner = owner;
Initialize();
return MessageBox.Show(owner, text, caption, buttons, icon);
}
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defButton)
{
_owner = owner;
Initialize();
return MessageBox.Show(owner, text, caption, buttons, icon, defButton);
}
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defButton, MessageBoxOptions options)
{
_owner = owner;
Initialize();
return MessageBox.Show(owner, text, caption, buttons, icon,
defButton, options);
}
public delegate IntPtr HookProc(int nCode, IntPtr wParam, IntPtr lParam);
public delegate void TimerProc(IntPtr hWnd, uint uMsg, UIntPtr nIDEvent, uint dwTime);
public const int WH_CALLWNDPROCRET = 12;
public enum CbtHookAction : int
{
HCBT_MOVESIZE = 0,
HCBT_MINMAX = 1,
HCBT_QS = 2,
HCBT_CREATEWND = 3,
HCBT_DESTROYWND = 4,
HCBT_ACTIVATE = 5,
HCBT_CLICKSKIPPED = 6,
HCBT_KEYSKIPPED = 7,
HCBT_SYSCOMMAND = 8,
HCBT_SETFOCUS = 9
}
[DllImport("user32.dll")]
private static extern bool GetWindowRect(IntPtr hWnd, ref Rectangle lpRect);
[DllImport("user32.dll")]
private static extern int MoveWindow(IntPtr hWnd, int X, int Y, int nWidth, int nHeight, bool bRepaint);
[DllImport("User32.dll")]
public static extern UIntPtr SetTimer(IntPtr hWnd, UIntPtr nIDEvent, uint uElapse, TimerProc lpTimerFunc);
[DllImport("User32.dll")]
public static extern IntPtr SendMessage(IntPtr hWnd, int Msg, IntPtr wParam, IntPtr lParam);
[DllImport("user32.dll")]
public static extern IntPtr SetWindowsHookEx(int idHook, HookProc lpfn, IntPtr hInstance, int threadId);
[DllImport("user32.dll")]
public static extern int UnhookWindowsHookEx(IntPtr idHook);
[DllImport("user32.dll")]
public static extern IntPtr CallNextHookEx(IntPtr idHook, int nCode, IntPtr wParam, IntPtr lParam);
[DllImport("user32.dll")]
public static extern int GetWindowTextLength(IntPtr hWnd);
[DllImport("user32.dll")]
public static extern int GetWindowText(IntPtr hWnd, StringBuilder text, int maxLength);
[DllImport("user32.dll")]
public static extern int EndDialog(IntPtr hDlg, IntPtr nResult);
[StructLayout(LayoutKind.Sequential)]
public struct CWPRETSTRUCT
{
public IntPtr lResult;
public IntPtr lParam;
public IntPtr wParam;
public uint message;
public IntPtr hwnd;
};
static MessageBoxMidle()
{
_hookProc = new HookProc(MessageBoxHookProc);
_hHook = IntPtr.Zero;
}
private static void Initialize()
{
if (_hHook != IntPtr.Zero)
{
throw new NotSupportedException("multiple calls are not supported");
}
if (_owner != null)
{
_hHook = SetWindowsHookEx(WH_CALLWNDPROCRET, _hookProc, IntPtr.Zero, AppDomain.GetCurrentThreadId());
}
}
private static IntPtr MessageBoxHookProc(int nCode, IntPtr wParam, IntPtr lParam)
{
if (nCode < 0)
{
return CallNextHookEx(_hHook, nCode, wParam, lParam);
}
CWPRETSTRUCT msg = (CWPRETSTRUCT)Marshal.PtrToStructure(lParam, typeof(CWPRETSTRUCT));
IntPtr hook = _hHook;
if (msg.message == (int)CbtHookAction.HCBT_ACTIVATE)
{
try
{
CenterWindow(msg.hwnd);
}
finally
{
UnhookWindowsHookEx(_hHook);
_hHook = IntPtr.Zero;
}
}
return CallNextHookEx(hook, nCode, wParam, lParam);
}
private static void CenterWindow(IntPtr hChildWnd)
{
Rectangle recChild = new Rectangle(0, 0, 0, 0);
bool success = GetWindowRect(hChildWnd, ref recChild);
int width = recChild.Width - recChild.X;
int height = recChild.Height - recChild.Y;
Rectangle recParent = new Rectangle(0, 0, 0, 0);
success = GetWindowRect(_owner.Handle, ref recParent);
Point ptCenter = new Point(0, 0);
ptCenter.X = recParent.X + ((recParent.Width - recParent.X) / 2);
ptCenter.Y = recParent.Y + ((recParent.Height - recParent.Y) / 2);
Point ptStart = new Point(0, 0);
ptStart.X = (ptCenter.X - (width / 2));
ptStart.Y = (ptCenter.Y - (height / 2));
ptStart.X = (ptStart.X < 0) ? 0 : ptStart.X;
ptStart.Y = (ptStart.Y < 0) ? 0 : ptStart.Y;
int result = MoveWindow(hChildWnd, ptStart.X, ptStart.Y, width, height, false);
}
}//Class_end
}
...@@ -36,7 +36,7 @@ namespace TSA_V ...@@ -36,7 +36,7 @@ namespace TSA_V
txtCode.Focus(); txtCode.Focus();
SetScreen(); SetScreen();
if (!IOBase.NoLine) if (!IOBase.NoLine)
timer1.Start(); timer1.Start();
IsInitOk = true; IsInitOk = true;
} }
private void LoadCom() private void LoadCom()
...@@ -61,6 +61,20 @@ namespace TSA_V ...@@ -61,6 +61,20 @@ namespace TSA_V
{ {
chbWorkSingleStart.Checked = true; chbWorkSingleStart.Checked = true;
} }
modePro();
}
private void modePro()
{
if (WorkModeUtil.OnlyGuoBan)
{
chbOffLine.Checked = false;
chbWorkSingleStart.Checked = false;
chbGuoban.Checked = true;
LogUtil.info("默认进入过板模式,其他模式不可选");
}
} }
int preIndex = -1; int preIndex = -1;
private void cmbBoardList_SelectedIndexChanged(object sender, EventArgs e) private void cmbBoardList_SelectedIndexChanged(object sender, EventArgs e)
...@@ -326,6 +340,13 @@ namespace TSA_V ...@@ -326,6 +340,13 @@ namespace TSA_V
} }
else else
{ {
//如果是过板模式,直接取消
if (WorkModeUtil.OnlyGuoBan)
{
chbGuoban.Checked = true;
return;
}
chbWorkSingleStart.Visible = true; chbWorkSingleStart.Visible = true;
chbOffLine.Visible = true; chbOffLine.Visible = true;
} }
......
...@@ -36,12 +36,14 @@ ...@@ -36,12 +36,14 @@
this.btnCodeTest = new System.Windows.Forms.Button(); this.btnCodeTest = new System.Windows.Forms.Button();
this.btnWorkInfo = new System.Windows.Forms.Button(); this.btnWorkInfo = new System.Windows.Forms.Button();
this.groupBox3 = new System.Windows.Forms.GroupBox(); this.groupBox3 = new System.Windows.Forms.GroupBox();
this.lblPause = new System.Windows.Forms.Label();
this.label8 = new System.Windows.Forms.Label(); this.label8 = new System.Windows.Forms.Label();
this.label7 = new System.Windows.Forms.Label(); this.label7 = new System.Windows.Forms.Label();
this.btnUpdateAutoTime = new System.Windows.Forms.Button(); this.btnUpdateAutoTime = new System.Windows.Forms.Button();
this.txtAuToTime = new System.Windows.Forms.TextBox(); this.txtAuToTime = new System.Windows.Forms.TextBox();
this.radioButton2 = new System.Windows.Forms.RadioButton(); this.radioButton2 = new System.Windows.Forms.RadioButton();
this.radioButton1 = new System.Windows.Forms.RadioButton(); this.radioButton1 = new System.Windows.Forms.RadioButton();
this.lblGuoBan = new System.Windows.Forms.Label();
this.btnTest = new System.Windows.Forms.Button(); this.btnTest = new System.Windows.Forms.Button();
this.btnStart = new System.Windows.Forms.Button(); this.btnStart = new System.Windows.Forms.Button();
this.groupBox1 = new System.Windows.Forms.GroupBox(); this.groupBox1 = new System.Windows.Forms.GroupBox();
...@@ -160,6 +162,8 @@ ...@@ -160,6 +162,8 @@
// //
// groupBox3 // groupBox3
// //
this.groupBox3.Controls.Add(this.lblGuoBan);
this.groupBox3.Controls.Add(this.lblPause);
this.groupBox3.Controls.Add(this.label8); this.groupBox3.Controls.Add(this.label8);
this.groupBox3.Controls.Add(this.label7); this.groupBox3.Controls.Add(this.label7);
this.groupBox3.Controls.Add(this.btnUpdateAutoTime); this.groupBox3.Controls.Add(this.btnUpdateAutoTime);
...@@ -174,11 +178,22 @@ ...@@ -174,11 +178,22 @@
this.groupBox3.TabStop = false; this.groupBox3.TabStop = false;
this.groupBox3.Text = "工作方式"; this.groupBox3.Text = "工作方式";
// //
// lblPause
//
this.lblPause.AutoSize = true;
this.lblPause.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblPause.Location = new System.Drawing.Point(179, 61);
this.lblPause.Name = "lblPause";
this.lblPause.Size = new System.Drawing.Size(74, 21);
this.lblPause.TabIndex = 284;
this.lblPause.Text = "暂停工作";
this.lblPause.Visible = false;
//
// label8 // label8
// //
this.label8.AutoSize = true; this.label8.AutoSize = true;
this.label8.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label8.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label8.Location = new System.Drawing.Point(508, 24); this.label8.Location = new System.Drawing.Point(584, 21);
this.label8.Name = "label8"; this.label8.Name = "label8";
this.label8.Size = new System.Drawing.Size(23, 20); this.label8.Size = new System.Drawing.Size(23, 20);
this.label8.TabIndex = 283; this.label8.TabIndex = 283;
...@@ -187,7 +202,7 @@ ...@@ -187,7 +202,7 @@
// label7 // label7
// //
this.label7.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label7.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label7.Location = new System.Drawing.Point(226, 24); this.label7.Location = new System.Drawing.Point(302, 21);
this.label7.Name = "label7"; this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(222, 21); this.label7.Size = new System.Drawing.Size(222, 21);
this.label7.TabIndex = 282; this.label7.TabIndex = 282;
...@@ -198,7 +213,7 @@ ...@@ -198,7 +213,7 @@
// //
this.btnUpdateAutoTime.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnUpdateAutoTime.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnUpdateAutoTime.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnUpdateAutoTime.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnUpdateAutoTime.Location = new System.Drawing.Point(421, 55); this.btnUpdateAutoTime.Location = new System.Drawing.Point(497, 52);
this.btnUpdateAutoTime.Name = "btnUpdateAutoTime"; this.btnUpdateAutoTime.Name = "btnUpdateAutoTime";
this.btnUpdateAutoTime.Size = new System.Drawing.Size(71, 32); this.btnUpdateAutoTime.Size = new System.Drawing.Size(71, 32);
this.btnUpdateAutoTime.TabIndex = 281; this.btnUpdateAutoTime.TabIndex = 281;
...@@ -210,7 +225,7 @@ ...@@ -210,7 +225,7 @@
// txtAuToTime // txtAuToTime
// //
this.txtAuToTime.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.txtAuToTime.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.txtAuToTime.Location = new System.Drawing.Point(453, 20); this.txtAuToTime.Location = new System.Drawing.Point(529, 17);
this.txtAuToTime.MaxLength = 5; this.txtAuToTime.MaxLength = 5;
this.txtAuToTime.Name = "txtAuToTime"; this.txtAuToTime.Name = "txtAuToTime";
this.txtAuToTime.Size = new System.Drawing.Size(47, 29); this.txtAuToTime.Size = new System.Drawing.Size(47, 29);
...@@ -242,6 +257,19 @@ ...@@ -242,6 +257,19 @@
this.radioButton1.UseVisualStyleBackColor = true; this.radioButton1.UseVisualStyleBackColor = true;
this.radioButton1.CheckedChanged += new System.EventHandler(this.radioButton1_CheckedChanged); this.radioButton1.CheckedChanged += new System.EventHandler(this.radioButton1_CheckedChanged);
// //
// lblGuoBan
//
this.lblGuoBan.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.lblGuoBan.Font = new System.Drawing.Font("微软雅黑", 21.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblGuoBan.Location = new System.Drawing.Point(11, 17);
this.lblGuoBan.Name = "lblGuoBan";
this.lblGuoBan.Size = new System.Drawing.Size(618, 71);
this.lblGuoBan.TabIndex = 285;
this.lblGuoBan.Text = "过板模式";
this.lblGuoBan.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// btnTest // btnTest
// //
this.btnTest.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); this.btnTest.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
...@@ -934,5 +962,7 @@ ...@@ -934,5 +962,7 @@
private System.Windows.Forms.Button btnWorkInfo; private System.Windows.Forms.Button btnWorkInfo;
private System.Windows.Forms.Button btnCodeTest; private System.Windows.Forms.Button btnCodeTest;
private System.Windows.Forms.Button btnIo; private System.Windows.Forms.Button btnIo;
private System.Windows.Forms.Label lblPause;
private System.Windows.Forms.Label lblGuoBan;
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -37,7 +37,25 @@ namespace TSA_V ...@@ -37,7 +37,25 @@ namespace TSA_V
if (board != null) if (board != null)
{ {
this.Text = "Neo Station:" + board.boardName; string modeStr = "";
lblGuoBan.Visible = false;
if (TSAVBean.OnlyGuoBan)
{
modeStr = "-" + ResourceCulture.GetString("FrmBoardSelect_chbGuoban_Text", "过板模式");
lblGuoBan.Text = ResourceCulture.GetString("FrmBoardSelect_chbGuoban_Text", "过板模式");
lblGuoBan.Visible = true;
}
else if (TSAVBean.OpenOfflineMode)
{
modeStr = "-" + ResourceCulture.GetString("FrmBoardSelect_chbOffLine_Text", "离线工作模式");
}
else if (TSAVBean.WorkSingleStart)
{
modeStr = "-" + ResourceCulture.GetString("FrmBoardSelect_chbWorkSingleStart_Text", "工作区检测开始工作");
}
this.Text = "Neo Station:" + board.boardName + modeStr;
workSmtList = board.GetSmtList(); workSmtList = board.GetSmtList();
preIndex = -1; preIndex = -1;
smtPoint = new SMTPointInfo(); smtPoint = new SMTPointInfo();
...@@ -63,11 +81,13 @@ namespace TSA_V ...@@ -63,11 +81,13 @@ namespace TSA_V
radioButton2.Checked = true; radioButton2.Checked = true;
AutoVisiable(true); AutoVisiable(true);
} }
} }
else else
{ {
LogUtil.info("配置程序之后才能工作!"); LogUtil.info("配置程序之后才能工作!");
this.Close(); this.Close();
} }
if (TSAVBean.IsNeedAOI && !string.IsNullOrEmpty(board.AOIProName)) if (TSAVBean.IsNeedAOI && !string.IsNullOrEmpty(board.AOIProName))
...@@ -76,7 +96,7 @@ namespace TSA_V ...@@ -76,7 +96,7 @@ namespace TSA_V
if (CurrProject == null) if (CurrProject == null)
{ {
LogUtil.info("没有读取到AOI,结束,IsNeedAOI=true!"); LogUtil.info("没有读取到AOI,结束,IsNeedAOI=true!");
MessageBox.Show(ResourceCulture.GetString("加载AOI失败.")); MessageBox.Show(ResourceCulture.GetString("加载AOI失败"));
//this.Close(); //this.Close();
} }
} }
...@@ -270,6 +290,12 @@ namespace TSA_V ...@@ -270,6 +290,12 @@ namespace TSA_V
{ {
ShowAOI(); ShowAOI();
} }
lblPause.Visible = TSAVBean.WorkPause;
}
else
{
lblPause.Visible = false;
} }
} }
catch (Exception ex) catch (Exception ex)
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!