Commit 9cf6fb80 LN

扫码时报错可以继续扫码

1 个父辈 e299a231
......@@ -96,7 +96,7 @@
this.lblWarnMsg = new System.Windows.Forms.Label();
this.lblThisSta = new System.Windows.Forms.Label();
this.groupInout = new System.Windows.Forms.GroupBox();
this.lblTemp = new System.Windows.Forms.Label();
this.lblTempStr = new System.Windows.Forms.Label();
this.lblMsg = new System.Windows.Forms.Label();
this.btnSavePosition = new System.Windows.Forms.Button();
this.btnStartAuTo = new System.Windows.Forms.Button();
......@@ -1011,7 +1011,7 @@
//
// groupInout
//
this.groupInout.Controls.Add(this.lblTemp);
this.groupInout.Controls.Add(this.lblTempStr);
this.groupInout.Controls.Add(this.lblMsg);
this.groupInout.Controls.Add(this.btnSavePosition);
this.groupInout.Controls.Add(this.btnStartAuTo);
......@@ -1060,16 +1060,16 @@
this.groupInout.TabStop = false;
this.groupInout.Text = "料仓操作";
//
// lblTemp
// lblTempStr
//
this.lblTemp.AutoSize = true;
this.lblTemp.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblTemp.ForeColor = System.Drawing.Color.Black;
this.lblTemp.Location = new System.Drawing.Point(11, 475);
this.lblTemp.Name = "lblTemp";
this.lblTemp.Size = new System.Drawing.Size(159, 20);
this.lblTemp.TabIndex = 270;
this.lblTemp.Text = "当前温度--,当前湿度--";
this.lblTempStr.AutoSize = true;
this.lblTempStr.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblTempStr.ForeColor = System.Drawing.Color.Black;
this.lblTempStr.Location = new System.Drawing.Point(11, 475);
this.lblTempStr.Name = "lblTempStr";
this.lblTempStr.Size = new System.Drawing.Size(81, 20);
this.lblTempStr.TabIndex = 270;
this.lblTempStr.Text = "10%,23℃";
//
// lblMsg
//
......@@ -2064,7 +2064,7 @@
private System.Windows.Forms.ToolStripMenuItem 关闭仓门ToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem 回待机点ToolStripMenuItem;
private System.Windows.Forms.GroupBox groupBox3;
private System.Windows.Forms.Label lblTemp;
private System.Windows.Forms.Label lblTempStr;
private System.Windows.Forms.CheckBox chbAuto;
private System.Windows.Forms.ContextMenuStrip contextMenuStrip1;
private System.Windows.Forms.ToolStripMenuItem 显示ToolStripMenuItem;
......
......@@ -183,7 +183,7 @@ namespace OnlineStore.ACSingleStore
{
return;
}
lblTemp.Text = store.currTempStr;
lblTempStr.Text = store.currTempStr;
//ReadPosistion();
if (store.storeRunStatus > StoreRunStatus.Wait)
......
......@@ -47,6 +47,7 @@ namespace OnlineStore
{
ResourceControl.GetChinaStringEvent += GetChinaString;
ResourceControl.GetEnglishStringEvent += GetEnglishString;
ResourceControl.GetStrEvent += GetString;
ResourceControl.GetStringEvent += GetString;
CSVResourceControl.GetStrEvent += GetString;
CSVResourceControl.GetStringEvent += GetString;
......
......@@ -1053,7 +1053,7 @@ namespace OnlineStore.DeviceLibrary
//判断料门口是否有料
if ((checkIO.Equals(IO_VALUE.HIGH)) && height > 0 && IOManager.IOValue(IO_Type.TrayCheck_Fixture).Equals(IO_VALUE.LOW)&&IsDebug.Equals(false))
{
if (IsScanCode)
if (!CanStartCode())
{
return;
}
......@@ -1469,20 +1469,21 @@ namespace OnlineStore.DeviceLibrary
public void GetCameraCode()
{
TimeSpan span = DateTime.Now - LastScanTime;
if ( IsScanCode && (span.TotalSeconds < 12))
if (CanStartCode())
{
LogUtil.info("上次扫码还未执行完毕,请稍后!");
return;
}
IOManager.IOMove(IO_Type.Camera_Led, IO_VALUE.HIGH);
LastScanTime = DateTime.Now;
dlScanSocket.BeginScan();
}
else
{
LogUtil.info("GetCameraCode()开始扫码失败,请等待上次扫码结束");
}
}
private bool CanStartCode()
{
TimeSpan span = DateTime.Now - LastScanTime;
if (IsScanCode && span.TotalSeconds < 12)
if (IsScanCode && span.TotalSeconds < 10)
{
return false;
}
......@@ -1660,7 +1661,8 @@ namespace OnlineStore.DeviceLibrary
{
humidity = param.Humidity;
temp = param.Temperate;
currTempStr = ("当前湿度:" + humidity.ToString() + ",当前温度:" + temp);
currTempStr = humidity + " %," + temp + "℃" ;
// currTempStr = ("当前湿度:" + humidity.ToString() + ",当前温度:" + temp);
}
//double currMaxHumidity = HumitureServer.GetMaxHumidity(Config.GetTempAddrList());
double currMaxHumidity = param.Humidity;
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!