Commit 8e235319 刘韬

1

1 个父辈 048920f6
...@@ -49,10 +49,13 @@ namespace OnlineStore.AutoInOutStore ...@@ -49,10 +49,13 @@ namespace OnlineStore.AutoInOutStore
this.tableLayoutPanel1.RowCount = boxBean.Config.DILIst.Count; this.tableLayoutPanel1.RowCount = boxBean.Config.DILIst.Count;
foreach (ConfigIO ioValue in boxBean.Config.DILIst.Values) foreach (ConfigIO ioValue in boxBean.Config.DILIst.Values)
{ {
if (ioValue.ProVale == "11")//屏蔽DI12的显示, DI12没用了
continue;
this.tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 26)); this.tableLayoutPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 26));
IOTextControl control = new IOTextControl(ioValue.ElectricalDefinition + "_" + ResourceCulture.GetString(ioValue.ElectricalDefinition, ioValue.Explain), ioValue.ProName,355); IOTextControl control = new IOTextControl(ioValue.ElectricalDefinition + "_" + ResourceCulture.GetString(ioValue.ElectricalDefinition, ioValue.Explain), ioValue.ProName,355);
this.tableLayoutPanel1.Controls.Add(control, 0, roleindex); this.tableLayoutPanel1.Controls.Add(control, 0, roleindex);
roleindex++; roleindex++;
DIControlList.Add(ioValue.ProName, control); DIControlList.Add(ioValue.ProName, control);
} }
......
...@@ -53,6 +53,7 @@ namespace OnlineStore.AutoInOutStore ...@@ -53,6 +53,7 @@ namespace OnlineStore.AutoInOutStore
[STAThread] [STAThread]
static void Main(string[] Args) static void Main(string[] Args)
{ {
var xx = DeviceLibrary.ACServerManager.SpeedToStr(32767, 4);
Environment.CurrentDirectory = Application.StartupPath; Environment.CurrentDirectory = Application.StartupPath;
Application.ThreadException += new System.Threading.ThreadExceptionEventHandler(Application_ThreadException); Application.ThreadException += new System.Threading.ThreadExceptionEventHandler(Application_ThreadException);
AppDomain.CurrentDomain.UnhandledException += new UnhandledExceptionEventHandler(CurrentDomain_UnhandledException); AppDomain.CurrentDomain.UnhandledException += new UnhandledExceptionEventHandler(CurrentDomain_UnhandledException);
......
...@@ -175,9 +175,9 @@ namespace OnlineStore.DeviceLibrary ...@@ -175,9 +175,9 @@ namespace OnlineStore.DeviceLibrary
public static void InitSlvAddr(string portName, int slvAddr,int targetSpeed,int addSpeed,int delSpeed ) public static void InitSlvAddr(string portName, int slvAddr,int targetSpeed,int addSpeed,int delSpeed )
//public static void InitSlvAddr(string portName, int slvAddr,int targetSpeed,int addSpeed,int delSpeed,int homeHighSpeed,int homeLowSpeed,int homeAddSpeed) //public static void InitSlvAddr(string portName, int slvAddr,int targetSpeed,int addSpeed,int delSpeed,int homeHighSpeed,int homeLowSpeed,int homeAddSpeed)
{ {
LogUtil.info("开始初始化伺服【" + portName + "】【" + slvAddr + "】"); LogUtil.info($"开始初始化伺服【{portName}】【{slvAddr}】targetSpeed:{targetSpeed},addSpeed:{addSpeed},delSpeed:{delSpeed}");
//写入block //写入block
int sleep = 20; int sleep = 50;
string slvAddrStr = string.Format(strFromat, slvAddr); string slvAddrStr = string.Format(strFromat, slvAddr);
//block0=原点返回,正方向 //block0=原点返回,正方向
string str0 = slvAddrStr + "104800 000408 00000420 00000000 ffff"; string str0 = slvAddrStr + "104800 000408 00000420 00000000 ffff";
......
...@@ -171,13 +171,13 @@ PRO,(轴五)上料轴P3点(上料目标位置),BatchAxis_P3,1724717,,,,,,, ...@@ -171,13 +171,13 @@ PRO,(轴五)上料轴P3点(上料目标位置),BatchAxis_P3,1724717,,,,,,,
PRO,(轴二)升降轴单盘入库抬升料盘的高度,UpdownAxis_UpPosition,10000,,,,,,, PRO,(轴二)升降轴单盘入库抬升料盘的高度,UpdownAxis_UpPosition,10000,,,,,,,
PRO,(轴五)上料轴出库上升最大高度,BatchAxis_OutMaxValue,1491390,,,,,,, PRO,(轴五)上料轴出库上升最大高度,BatchAxis_OutMaxValue,1491390,,,,,,,
,,,,,,,,,, ,,,,,,,,,,
PRO,(轴四)压紧轴目标速度,CompAxis_TargetSpeed,200,,,,,,, PRO,(轴四)压紧轴目标速度,CompAxis_TargetSpeed,330000,,,,,,,
PRO,(轴四)压紧轴加速度,CompAxis_AddSpeed,2000,,,,,,, PRO,(轴四)压紧轴加速度,CompAxis_AddSpeed,930000,,,,,,,
PRO,(轴四)压紧轴减速度,CompAxis_DelSpeed,2000,,,,,,, PRO,(轴四)压紧轴减速度,CompAxis_DelSpeed,930000,,,,,,,
PRO,(轴四)压紧轴原点低速,CompAxis_HomeLowSpeed,200,,,,,,, PRO,(轴四)压紧轴原点低速,CompAxis_HomeLowSpeed,200,,,,,,,
PRO,(轴四)压紧轴原点高速,CompAxis_HomeHighSpeed,200,,,,,,, PRO,(轴四)压紧轴原点高速,CompAxis_HomeHighSpeed,200,,,,,,,
PRO,(轴四)压紧轴原点加速度,CompAxis_HomeAddSpeed,2000,,,,,,, PRO,(轴四)压紧轴原点加速度,CompAxis_HomeAddSpeed,2000,,,,,,,
PRO,(轴四)压紧轴P1速度,CompAxis_P1_Speed,1100,,,,,,, PRO,(轴四)压紧轴P1速度,CompAxis_P1_Speed,1100,,,,,,,
PRO,(轴四)压紧轴P2速度,CompAxis_P2_Speed,1100,,,,,,, PRO,(轴四)压紧轴P2速度,CompAxis_P2_Speed,330000,,,,,,,
PRO,(轴四)压紧轴P3速度,CompAxis_P3_Speed,1100,,,,,,, PRO,(轴四)压紧轴P3速度,CompAxis_P3_Speed,1100,,,,,,,
PRO,特殊二维码尺寸配置,CodeSizeConfig,T;PartNum;1=330x81,,,,,,, PRO,特殊二维码尺寸配置,CodeSizeConfig,T;PartNum;1=330x81,,,,,,,
...@@ -169,7 +169,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -169,7 +169,7 @@ namespace OnlineStore.DeviceLibrary
int timeOutMs = Config.IOSingle_TimerOut; int timeOutMs = Config.IOSingle_TimerOut;
if (StoreMove.MoveStep == StoreMoveStep.SO_14_WaitTake) if (StoreMove.MoveStep == StoreMoveStep.SO_14_WaitTake)
{ {
timeOutMs = 650000; timeOutMs = 100000;
} }
TimeSpan rwSpan = DateTime.Now - preRWTime; TimeSpan rwSpan = DateTime.Now - preRWTime;
......
...@@ -754,9 +754,10 @@ namespace OnlineStore.DeviceLibrary ...@@ -754,9 +754,10 @@ namespace OnlineStore.DeviceLibrary
//若X12亮,先匀速下降到X12不亮,再开门。 //若X12亮,先匀速下降到X12不亮,再开门。
if (StoreMove.MoveStep.Equals(StoreMoveStep.AUTO_O00_Wait)) if (StoreMove.MoveStep.Equals(StoreMoveStep.AUTO_O00_Wait))
{ {
if (IOManager.IOValue(IO_Type.OutCheck).Equals(IO_VALUE.LOW) && IOManager.IOValue(IO_Type.TrayCheck_LoadMaterial).Equals(IO_VALUE.LOW)) //if (IOManager.IOValue(IO_Type.OutCheck).Equals(IO_VALUE.LOW) && IOManager.IOValue(IO_Type.TrayCheck_LoadMaterial).Equals(IO_VALUE.LOW))
if (IOManager.IOValue(IO_Type.TrayCheck_LoadMaterial).Equals(IO_VALUE.LOW))
{ {
OutStoreLog("OutCheck=LOW ,直接打开门锁 "); OutStoreLog("TrayCheck_LoadMaterial=LOW ,直接打开门锁 ");
StoreMove.NextMoveStep(StoreMoveStep.AUTO_O02_WaitDoorOpen); StoreMove.NextMoveStep(StoreMoveStep.AUTO_O02_WaitDoorOpen);
BatchDoorOpen(true); BatchDoorOpen(true);
StoreMove.WaitList.Add(WaitResultInfo.WaitTime(2000)); StoreMove.WaitList.Add(WaitResultInfo.WaitTime(2000));
......
...@@ -132,7 +132,7 @@ namespace OnlineStore.DeviceLibrary ...@@ -132,7 +132,7 @@ namespace OnlineStore.DeviceLibrary
// } // }
//} //}
TimeSpan rwSpan = DateTime.Now - preRWTime; TimeSpan rwSpan = DateTime.Now - preRWTime;
if (wait.IsEnd.Equals(false) && rwSpan.TotalSeconds > 5 && span.TotalSeconds > 6 && span.TotalSeconds < 30 && StoreManager.Store.Config.DOList.ContainsKey(wait.IoType)) if (wait.IsEnd.Equals(false) && rwSpan.TotalSeconds > 9 && span.TotalSeconds > 10 && span.TotalSeconds < 30 && StoreManager.Store.Config.DOList.ContainsKey(wait.IoType))
{ {
preRWTime = DateTime.Now; preRWTime = DateTime.Now;
string msg = " [" + StoreMove.MoveType + "][" + StoreMove.MoveStep + "] " + NotOkMsg + "已等待 " + Math.Round(span.TotalSeconds, 1) + "秒,重写DO:"; string msg = " [" + StoreMove.MoveType + "][" + StoreMove.MoveStep + "] " + NotOkMsg + "已等待 " + Math.Round(span.TotalSeconds, 1) + "秒,重写DO:";
......
...@@ -984,7 +984,7 @@ namespace OnlineStore.LoadCSVLibrary ...@@ -984,7 +984,7 @@ namespace OnlineStore.LoadCSVLibrary
MustHaveDIList.Add(IO_Type.WidthCheck1); MustHaveDIList.Add(IO_Type.WidthCheck1);
MustHaveDIList.Add(IO_Type.WidthCheck2); MustHaveDIList.Add(IO_Type.WidthCheck2);
MustHaveDIList.Add(IO_Type.TrayCheck_LoadMaterial); MustHaveDIList.Add(IO_Type.TrayCheck_LoadMaterial);
MustHaveDIList.Add(IO_Type.OutCheck); //MustHaveDIList.Add(IO_Type.OutCheck);
MustHaveDIList.Add(IO_Type.BatchDoor_Open); MustHaveDIList.Add(IO_Type.BatchDoor_Open);
MustHaveDIList.Add(IO_Type.BatchDoor_Close); MustHaveDIList.Add(IO_Type.BatchDoor_Close);
MustHaveDIList.Add(IO_Type.TrayCheck_Fixture); MustHaveDIList.Add(IO_Type.TrayCheck_Fixture);
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!