Commit 73d3babc LN

出库是否等待仓门口信号增加配置

1 个父辈 b64dc0ba
......@@ -49,6 +49,7 @@
this.label4 = new System.Windows.Forms.Label();
this.cmbPosition7 = new System.Windows.Forms.ComboBox();
this.label21 = new System.Windows.Forms.Label();
this.chbEmptyNeedAlarm = new System.Windows.Forms.CheckBox();
this.groupBox1.SuspendLayout();
this.groupBox2.SuspendLayout();
this.SuspendLayout();
......@@ -68,7 +69,7 @@
this.btnNext.Anchor = System.Windows.Forms.AnchorStyles.Top;
this.btnNext.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnNext.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnNext.Location = new System.Drawing.Point(317, 179);
this.btnNext.Location = new System.Drawing.Point(419, 189);
this.btnNext.Name = "btnNext";
this.btnNext.Size = new System.Drawing.Size(120, 45);
this.btnNext.TabIndex = 275;
......@@ -155,7 +156,7 @@
this.chbDebug.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.chbDebug.AutoSize = true;
this.chbDebug.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.chbDebug.Location = new System.Drawing.Point(152, 190);
this.chbDebug.Location = new System.Drawing.Point(29, 199);
this.chbDebug.Name = "chbDebug";
this.chbDebug.Size = new System.Drawing.Size(93, 25);
this.chbDebug.TabIndex = 282;
......@@ -164,6 +165,7 @@
//
// groupBox1
//
this.groupBox1.Controls.Add(this.chbEmptyNeedAlarm);
this.groupBox1.Controls.Add(this.chbDebug);
this.groupBox1.Controls.Add(this.label1);
this.groupBox1.Controls.Add(this.btnReset);
......@@ -175,7 +177,7 @@
this.groupBox1.Controls.Add(this.label3);
this.groupBox1.Location = new System.Drawing.Point(12, 12);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(577, 243);
this.groupBox1.Size = new System.Drawing.Size(577, 262);
this.groupBox1.TabIndex = 283;
this.groupBox1.TabStop = false;
this.groupBox1.Text = "料仓配置";
......@@ -191,7 +193,7 @@
this.groupBox2.Controls.Add(this.label4);
this.groupBox2.Controls.Add(this.cmbPosition7);
this.groupBox2.Controls.Add(this.label21);
this.groupBox2.Location = new System.Drawing.Point(12, 264);
this.groupBox2.Location = new System.Drawing.Point(12, 280);
this.groupBox2.Name = "groupBox2";
this.groupBox2.Size = new System.Drawing.Size(577, 244);
this.groupBox2.TabIndex = 284;
......@@ -323,6 +325,18 @@
this.label21.Text = "库位号-7寸盘定位:";
this.label21.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
//
// chbEmptyNeedAlarm
//
this.chbEmptyNeedAlarm.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.chbEmptyNeedAlarm.AutoSize = true;
this.chbEmptyNeedAlarm.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.chbEmptyNeedAlarm.Location = new System.Drawing.Point(153, 199);
this.chbEmptyNeedAlarm.Name = "chbEmptyNeedAlarm";
this.chbEmptyNeedAlarm.Size = new System.Drawing.Size(237, 25);
this.chbEmptyNeedAlarm.TabIndex = 283;
this.chbEmptyNeedAlarm.Text = "出库时仓门口信号不亮时报警";
this.chbEmptyNeedAlarm.UseVisualStyleBackColor = true;
//
// FrmIdConfig
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 17F);
......@@ -367,5 +381,6 @@
private System.Windows.Forms.ComboBox cmbPosition11;
public System.Windows.Forms.Label label4;
private System.Windows.Forms.Button btnSavePosID;
private System.Windows.Forms.CheckBox chbEmptyNeedAlarm;
}
}
\ No newline at end of file
......@@ -30,6 +30,7 @@ namespace OnlineStore.ACSingleStore
this.DialogResult = DialogResult.None;
txthttpAddr.Text = ConfigAppSettings.GetValue(Setting_Init.http_server);
txtLineAddr.Text = ConfigAppSettings.GetValue(Setting_Init.LineServerIp);
chbEmptyNeedAlarm.Checked = ConfigAppSettings.GetIntValue(Setting_Init.EmptyOutNeedAlarm).Equals(1);
cmbId.Items.Clear();
for(int i = 1; i <= 26; i++)
{
......@@ -97,6 +98,9 @@ namespace OnlineStore.ACSingleStore
ConfigAppSettings.SaveValue(Setting_Init.LineServerIp, lineStr);
StoreManager.Store.IsDebug = chbDebug.Checked;
ConfigAppSettings.SaveValue(Setting_Init.IsInDebug, chbDebug.Checked ? 1 : 0);
bool emptyNeedAlarm = chbEmptyNeedAlarm.Checked;
ConfigAppSettings.SaveValue(Setting_Init.EmptyOutNeedAlarm, emptyNeedAlarm ? 1 : 0);
LogUtil.info($"cid {storeCID} ,storeId{storeId} ,debug {StoreManager.Store.IsDebug} emptyNeedAlarm {emptyNeedAlarm}");
MessageBox.Show("保存成功,请重启客户端");
this.DialogResult = DialogResult.OK;
}
......
......@@ -105,6 +105,10 @@ namespace OnlineStore.Common
public static string Location_PosID_ = "Location_PosID_";
public static string VisionConfigFile = "VisionConfigFile";
/// <summary>
/// 出库仓门口和料叉都空出时,报警等待仓门口信号
/// </summary>
public static string EmptyOutNeedAlarm = "EmptyOutNeedAlarm";
}
}
......@@ -1548,6 +1548,7 @@ namespace OnlineStore.DeviceLibrary
private float StartBlowValue = (float)ConfigAppSettings.GetNumValue(Setting_Init.StartBlowValue);
private float StopBlowValue = (float)ConfigAppSettings.GetNumValue(Setting_Init.StopBlowValue);
private bool EmptyOutNeedAlarm = ConfigAppSettings.GetIntValue(Setting_Init.EmptyOutNeedAlarm).Equals(1);
public string currTempStr = "";
private void HumidityProcess()
{
......
......@@ -896,11 +896,19 @@ namespace OnlineStore.DeviceLibrary
else if (StoreMove.MoveStep == StoreMoveStep.SO_28_CloseDoor)
{
StoreMove.NextMoveStep(StoreMoveStep.SO_29_CheckTray);
if (EmptyOutNeedAlarm)
{
OutStoreLog("出库:检测料仓门口料盘信号 , EmptyOutAlarm=true, 需要等待 TrayCheck_Door=HIGH");
StoreMove.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.TrayCheck_Door, IO_VALUE.HIGH));
}
else
{
OutStoreLog("出库:检测料仓门口料盘信号 ,最多1000");
StoreMove.OneWaitCanEndStep = true;
StoreMove.WaitList.Add(WaitResultInfo.WaitTime(1000));
StoreMove.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.TrayCheck_Door, IO_VALUE.HIGH));
}
}
else if (StoreMove.MoveStep.Equals(StoreMoveStep.SO_29_CheckTray))
{
if (IOManager.IOValue(IO_Type.TrayCheck_Door).Equals(IO_VALUE.LOW))
......@@ -916,7 +924,14 @@ namespace OnlineStore.DeviceLibrary
}
else
{
if (EmptyOut)
if (EmptyOutNeedAlarm)
{
StoreMove.NextMoveStep(StoreMoveStep.SO_29_CheckTray);
OutStoreLog("出库:检测料仓门口料盘信号 , EmptyOutAlarm=true, 需要一直等待");
StoreMove.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.TrayCheck_Door, IO_VALUE.HIGH));
return;
}
else if (EmptyOut)
{
CodeMsg = "" + posId + "_" + barcode + "_空出";
LogUtil.error(CodeMsg + ",取消出库任务");
......@@ -952,7 +967,7 @@ namespace OnlineStore.DeviceLibrary
string posId = StoreMove.MoveParam != null ? StoreMove.MoveParam.PosInfo.PosId : "";
storeStatus = StoreStatus.StoreOnline;
LogUtil.info( StoreName + " 【" + posId + "】 整个出库流程结束,耗时【" + FormUtil.GetSpanStr(span) + "】!");
LogUtil.info(StoreName + " 【" + posId + "】 整个出库流程结束,耗时【" + FormUtil.GetSpanStr(span) + "】!");
StoreMove.EndMove();
storeRunStatus = StoreRunStatus.Runing;
InOutEndProcess(StoreMoveType.OutStore);
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!