Commit 39de335a 刘韬

NA

1 个父辈 ef9490c0
正在显示 42 个修改的文件 包含 1025 行增加385 行删除
......@@ -105,8 +105,9 @@ namespace OnlineStore.Common
public static string HasT4Axis = "HasT4Axis";
public static string AgvServerIp = "AgvServerIp";
public static string AgvServerPort = "AgvServerPort";
public static string code_block_size_list = "code_block_size_list";
}
}
......@@ -9,7 +9,7 @@ namespace OnlineStore.Common
{
public class FormUtil
{
public static int GetIntValue(TextBox txt)
public static int GetIntValue(Control txt)
{
int value = 0;
try
......
<?xml version="1.0"?>
<configuration>
<configSections>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net" />
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net"/>
</configSections>
<appSettings>
<!--是否开机自动启动料仓-->
<add key="App_AutoRun" value="0" />
<add key="App_Title" value="DUO料仓" />
<add key="App_AutoRun" value="0"/>
<add key="App_Title" value="DUO料仓"/>
<!-- 开始吹气的判断值(配置值=服务器发送的湿度值-开始吹气值)-->
<add key="StartBlowValue" value="4" />
<add key="StartBlowValue" value="4"/>
<!-- 停止吹气的判断值(配置值=服务器发送的湿度值-停止吹气值)-->
<add key="StopBlowValue" value="4" />
<add key="StopBlowValue" value="4"/>
<!--Server address-->
<add key="http.server" value="http://localhost/myproject/" />
<add key="http.server" value="http://localhost/myproject/"/>
<!--storeType-->
<add key="store_count" value="2" />
<add key="Store_ConfigPath" value="\StoreConfig\StoreConfig.csv" />
<add key="store_count" value="2"/>
<add key="Store_ConfigPath" value="\StoreConfig\StoreConfig.csv"/>
<!--start one store config-->
<add key="Store_Position_Config" value="\StoreConfig\linePositions.csv" />
<add key="BOX_ConfigPath" value="\StoreConfig\BoxConfig.csv" />
<add key="Store_Type" value="RC_AC_PA" />
<add key="Store_CID" value="duo-store" />
<add key="Store_CID_1" value="duo-1" />
<add key="Store_CID_2" value="duo-2" />
<add key="Store_Position_Config" value="\StoreConfig\linePositions.csv"/>
<add key="BOX_ConfigPath" value="\StoreConfig\BoxConfig.csv"/>
<add key="Store_Type" value="RC_AC_PA"/>
<add key="Store_CID" value="duo-store"/>
<add key="Store_CID_1" value="duo-1"/>
<add key="Store_CID_2" value="duo-2"/>
<add key="Store_CID_1_disabled" value="1" />
<add key="Store_CID_2_disabled" value="1" />
<add key="Store_CID_1_disabled" value="1"/>
<add key="Store_CID_2_disabled" value="1"/>
<!--end one store config-->
<add key="ACBaudRate" value="115200" />
<add key="Config_Pwd" value="123456" />
<add key="ACBaudRate" value="115200"/>
<add key="Config_Pwd" value="123456"/>
<!--二维码类型列表配置,用#分割,一维码=Barcode 二维码: QR Code#Data Matrix ECC 200#Micro QR Code-->
<add key="CodeType" value="QR Code#Data Matrix ECC 200" />
<add key="CodeType" value="QR Code#Data Matrix ECC 200"/>
<!--二维码参数文件所在路径,文件名与二维码类型名一样-->
<add key="CodeParamPath" value="\CodeParam\" />
<add key="CodeParamPath" value="\CodeParam\"/>
<!--出库等待料盘拿走的时间,秒-->
<add key="OutStoreWaitSeconds" value="1" />
<add key="OutStoreWaitSeconds" value="1"/>
<!--温控器类型,0=壁挂王字壳温湿度变送器,1=妙昕温湿度记录仪-->
<add key="HumitureControllerType" value="0" />
<add key="HumitureControllerType" value="0"/>
<add key="UseBuzzer" value="0" />
<add key="UseBuzzer" value="0"/>
<!--IO模块是否主动上传-->
<add key="AIOAutoUpload" value="0" />
<add key="CodeCount" value="3" />
<add key="Tool_P3_Offset" value="70" />
<add key="Tool_P4_Offset" value="-20" />
<add key="Tool_P5_Offset" value="-20" />
<add key="Tool_P6_Offset" value="70" />
<add key="Tool_TargetSpeed" value="20" />
<add key="Tool_TargetPosition" value="10420" />
<add key="AIOAutoUpload" value="0"/>
<add key="CodeCount" value="3"/>
<add key="Tool_P3_Offset" value="70"/>
<add key="Tool_P4_Offset" value="-20"/>
<add key="Tool_P5_Offset" value="-20"/>
<add key="Tool_P6_Offset" value="70"/>
<add key="Tool_TargetSpeed" value="20"/>
<add key="Tool_TargetPosition" value="10420"/>
<add key="Agv_Log_Open" value="1" />
<add key="Agv_Log_Open" value="1"/>
<!--进出轴位置-->
<add key ="InOutDefaultPosition" value ="3000"/>
<add key="InOutDefaultPosition" value="3000"/>
<!--当前料架信息-料架号-->
<add key ="CurrShelfNum" value ="-1"/>
<add key="CurrShelfNum" value="-1"/>
<!--当前料架信息-料架类型,0=空料架,1=入库料架,2=出库料架-->
<add key ="CurrShelfType" value ="-1"/>
<add key ="HasT4Axis" value ="true"/>
<add key ="AgvServerIp" value ="192.168.11.11"/>
<add key="CurrShelfType" value="-1"/>
<add key="HasT4Axis" value="true"/>
<add key="AgvServerIp" value="192.168.11.11"/>
<add key="Code_Block_Size_List" value="17,19"/>
</appSettings>
<log4net>
<appender name="RollingLogFileAppender" type="log4net.Appender.RollingFileAppender">
<file value="logs/duoStore.log" />
<param name="Encoding" value="UTF-8" />
<appendToFile value="true" />
<rollingStyle value="Date" />
<datePattern value="yyyy-MM-dd" />
<file value="logs/duoStore.log"/>
<param name="Encoding" value="UTF-8"/>
<appendToFile value="true"/>
<rollingStyle value="Date"/>
<datePattern value="yyyy-MM-dd"/>
<layout type="log4net.Layout.PatternLayout">
<conversionPattern value="[%date][%t]%-5p %m%n" />
<conversionPattern value="[%date][%t]%-5p %m%n"/>
</layout>
</appender>
<appender name="Rmaxis" type="log4net.Appender.RollingFileAppender">
<file value="logs/Rmaxis.log" />
<param name="Encoding" value="UTF-8" />
<appendToFile value="true" />
<rollingStyle value="Date" />
<datePattern value="yyyy-MM-dd" />
<file value="logs/Rmaxis.log"/>
<param name="Encoding" value="UTF-8"/>
<appendToFile value="true"/>
<rollingStyle value="Date"/>
<datePattern value="yyyy-MM-dd"/>
<layout type="log4net.Layout.PatternLayout">
<conversionPattern value="[%date][%t]%-5p %m%n" />
<conversionPattern value="[%date][%t]%-5p %m%n"/>
</layout>
</appender>
<appender name="AIOBOX" type="log4net.Appender.RollingFileAppender">
<file value="logs/aio/AIOBOX.log" />
<param name="Encoding" value="UTF-8" />
<appendToFile value="true" />
<rollingStyle value="Date" />
<datePattern value="yyyy-MM-dd" />
<file value="logs/aio/AIOBOX.log"/>
<param name="Encoding" value="UTF-8"/>
<appendToFile value="true"/>
<rollingStyle value="Date"/>
<datePattern value="yyyy-MM-dd"/>
<layout type="log4net.Layout.PatternLayout">
<conversionPattern value="[%date][%t]%-5p %m%n" />
<conversionPattern value="[%date][%t]%-5p %m%n"/>
</layout>
</appender>
<appender name="HCBOARD" type="log4net.Appender.RollingFileAppender">
<file value="logs/HCBOARD.log"/>
<param name="Encoding" value="UTF-8"/>
<appendToFile value="true"/>
<rollingStyle value="Date"/>
<datePattern value="yyyy-MM-dd"/>
<layout type="log4net.Layout.PatternLayout">
<conversionPattern value="[%date][%t] %m%n"/>
</layout>
</appender>
<logger name="RollingLogFileAppender">
<level value="Info" />
<appender-ref ref="RollingLogFileAppender" />
<level value="Info"/>
<appender-ref ref="RollingLogFileAppender"/>
</logger>
<logger name="AIOBOX">
<level value="Info" />
<appender-ref ref="AIOBOX" />
<level value="Info"/>
<appender-ref ref="AIOBOX"/>
</logger>
<logger name="Rmaxis">
<level value="ALL" />
<appender-ref ref="Rmaxis" />
<level value="ALL"/>
<appender-ref ref="Rmaxis"/>
</logger>
<logger name="HCBOARD" additivity="false">
<level value="ALL"/>
<appender-ref ref="HCBOARD"/>
</logger>
<!--<root>
<level value="Info" />
......@@ -108,6 +123,6 @@
</root>-->
</log4net>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1" />
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2"/>
</startup>
</configuration>
\ No newline at end of file
</configuration>
......@@ -9,7 +9,7 @@
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>OnlineStore.DUOStore</RootNamespace>
<AssemblyName>DUOStore</AssemblyName>
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile />
</PropertyGroup>
......
......@@ -11,7 +11,7 @@ using System.Windows.Forms;
namespace OnlineStore.DUOStore
{
public class FormManager
{
{
private static FrmAxisDebug debug = null;
public static void CloseAxisDebug()
......
......@@ -65,6 +65,8 @@ namespace OnlineStore.DUOStore
this.btnMiddleP3 = new System.Windows.Forms.Button();
this.axisMoveControl1 = new OnlineStore.DUOStore.AxisMoveControl();
this.btnSotreReset = new System.Windows.Forms.Button();
this.txtInOutP6 = new System.Windows.Forms.TextBox();
this.btnInOutP6 = new System.Windows.Forms.Button();
this.groupInout.SuspendLayout();
this.SuspendLayout();
//
......@@ -75,6 +77,8 @@ namespace OnlineStore.DUOStore
//
// groupInout
//
this.groupInout.Controls.Add(this.txtInOutP6);
this.groupInout.Controls.Add(this.btnInOutP6);
this.groupInout.Controls.Add(this.btnSaveP);
this.groupInout.Controls.Add(this.txtT2P4);
this.groupInout.Controls.Add(this.btnT2P4);
......@@ -121,7 +125,7 @@ namespace OnlineStore.DUOStore
// btnSaveP
//
this.btnSaveP.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnSaveP.Location = new System.Drawing.Point(372, 357);
this.btnSaveP.Location = new System.Drawing.Point(372, 404);
this.btnSaveP.Name = "btnSaveP";
this.btnSaveP.Size = new System.Drawing.Size(128, 39);
this.btnSaveP.TabIndex = 313;
......@@ -181,7 +185,7 @@ namespace OnlineStore.DUOStore
// btnAxisOff
//
this.btnAxisOff.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnAxisOff.Location = new System.Drawing.Point(372, 277);
this.btnAxisOff.Location = new System.Drawing.Point(372, 324);
this.btnAxisOff.Name = "btnAxisOff";
this.btnAxisOff.Size = new System.Drawing.Size(128, 39);
this.btnAxisOff.TabIndex = 276;
......@@ -211,7 +215,7 @@ namespace OnlineStore.DUOStore
// btnAxisOn
//
this.btnAxisOn.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnAxisOn.Location = new System.Drawing.Point(372, 232);
this.btnAxisOn.Location = new System.Drawing.Point(372, 279);
this.btnAxisOn.Name = "btnAxisOn";
this.btnAxisOn.Size = new System.Drawing.Size(128, 39);
this.btnAxisOn.TabIndex = 275;
......@@ -713,6 +717,40 @@ namespace OnlineStore.DUOStore
this.btnSotreReset.UseVisualStyleBackColor = true;
this.btnSotreReset.Click += new System.EventHandler(this.btnSotreReset_Click);
//
// txtInOutP6
//
this.txtInOutP6.AcceptsReturn = true;
this.txtInOutP6.BackColor = System.Drawing.SystemColors.Window;
this.txtInOutP6.Cursor = System.Windows.Forms.Cursors.IBeam;
this.txtInOutP6.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.txtInOutP6.ForeColor = System.Drawing.SystemColors.WindowText;
this.txtInOutP6.Location = new System.Drawing.Point(583, 185);
this.txtInOutP6.MaxLength = 0;
this.txtInOutP6.Name = "txtInOutP6";
this.txtInOutP6.RightToLeft = System.Windows.Forms.RightToLeft.No;
this.txtInOutP6.Size = new System.Drawing.Size(89, 23);
this.txtInOutP6.TabIndex = 316;
this.txtInOutP6.Text = "999999";
//
// btnInOutP6
//
this.btnInOutP6.AutoSize = true;
this.btnInOutP6.BackColor = System.Drawing.SystemColors.Control;
this.btnInOutP6.Cursor = System.Windows.Forms.Cursors.Default;
this.btnInOutP6.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnInOutP6.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnInOutP6.ForeColor = System.Drawing.Color.DarkGoldenrod;
this.btnInOutP6.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.btnInOutP6.Location = new System.Drawing.Point(372, 180);
this.btnInOutP6.Name = "btnInOutP6";
this.btnInOutP6.RightToLeft = System.Windows.Forms.RightToLeft.No;
this.btnInOutP6.Size = new System.Drawing.Size(205, 33);
this.btnInOutP6.TabIndex = 315;
this.btnInOutP6.Text = "T4_进出轴13寸取料点进入前点P6";
this.btnInOutP6.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.btnInOutP6.UseVisualStyleBackColor = false;
this.btnInOutP6.Click += new System.EventHandler(this.btnInOutP6_Click);
//
// FrmAxisMove
//
this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
......@@ -775,6 +813,8 @@ namespace OnlineStore.DUOStore
public System.Windows.Forms.TextBox txtInOutP3;
public System.Windows.Forms.Button btnInOutP3;
private System.Windows.Forms.Button btnSotreReset;
public System.Windows.Forms.TextBox txtInOutP6;
public System.Windows.Forms.Button btnInOutP6;
}
}
......@@ -65,8 +65,7 @@ namespace OnlineStore.DUOStore
txtInOutP2.Text = StoreManager.Store.Config.InOutAxis_P2.ToString();
txtInOutP3.Text = StoreManager.Store.Config.InOutAxis_P3.ToString();
txtInOutP4.Text = StoreManager.Store.Config.InOutAxis_P4.ToString();
txtInOutP6.Text = StoreManager.Store.Config.InOutAxis_P6.ToString();
}
internal void DebugStatus(bool isDebug)
......@@ -167,6 +166,11 @@ namespace OnlineStore.DUOStore
{
AxisABSMove(StoreManager.Store.T4_InOut_Axis, txtInOutP4, StoreManager.Store.Config.InOutAxis_P4Speed);
}
private void btnInOutP6_Click(object sender, EventArgs e)
{
AxisABSMove(StoreManager.Store.T4_InOut_Axis, txtInOutP6, StoreManager.Store.Config.InOutAxis_P3Speed);
}
private void btnSaveP_Click(object sender, EventArgs e)
{
Store_Config config = StoreManager.Config;
......@@ -187,7 +191,7 @@ namespace OnlineStore.DUOStore
config.InOutAxis_P2 = FormUtil.GetIntValue(txtInOutP2);
config.InOutAxis_P3 = FormUtil.GetIntValue(txtInOutP3);
config.InOutAxis_P4 = FormUtil.GetIntValue(txtInOutP4);
config.InOutAxis_P6 = FormUtil.GetIntValue(txtInOutP6);
bool result = StoreManager.UpdateStoreConfig(config);
if (result)
{
......@@ -228,5 +232,7 @@ namespace OnlineStore.DUOStore
//btnSotreReset.Enabled = false;
}
}
}
}
......@@ -111,6 +111,7 @@ namespace OnlineStore.DUOStore
this.lblWarnMsg = new System.Windows.Forms.Label();
this.lblThisSta = new System.Windows.Forms.Label();
this.chbDisable = new System.Windows.Forms.CheckBox();
this.cmbHight = new System.Windows.Forms.ComboBox();
this.groupBox4.SuspendLayout();
this.groupBox1.SuspendLayout();
this.tabControl1.SuspendLayout();
......@@ -131,7 +132,7 @@ namespace OnlineStore.DUOStore
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("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.chbDebug.Location = new System.Drawing.Point(10, 597);
this.chbDebug.Location = new System.Drawing.Point(157, 480);
this.chbDebug.Name = "chbDebug";
this.chbDebug.Size = new System.Drawing.Size(84, 24);
this.chbDebug.TabIndex = 271;
......@@ -241,6 +242,7 @@ namespace OnlineStore.DUOStore
//
this.groupInout.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.groupInout.Controls.Add(this.cmbHight);
this.groupInout.Controls.Add(this.btnNgPro);
this.groupInout.Controls.Add(this.btnAxisP);
this.groupInout.Controls.Add(this.btnSingleOut);
......@@ -302,7 +304,7 @@ namespace OnlineStore.DUOStore
this.btnNgPro.BackColor = System.Drawing.Color.White;
this.btnNgPro.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnNgPro.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnNgPro.Location = new System.Drawing.Point(658, 21);
this.btnNgPro.Location = new System.Drawing.Point(754, 21);
this.btnNgPro.Name = "btnNgPro";
this.btnNgPro.Size = new System.Drawing.Size(128, 39);
this.btnNgPro.TabIndex = 310;
......@@ -326,7 +328,7 @@ namespace OnlineStore.DUOStore
this.btnSingleOut.BackColor = System.Drawing.Color.White;
this.btnSingleOut.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnSingleOut.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnSingleOut.Location = new System.Drawing.Point(522, 21);
this.btnSingleOut.Location = new System.Drawing.Point(618, 21);
this.btnSingleOut.Name = "btnSingleOut";
this.btnSingleOut.Size = new System.Drawing.Size(128, 39);
this.btnSingleOut.TabIndex = 309;
......@@ -966,7 +968,7 @@ namespace OnlineStore.DUOStore
this.btnSavePosition.BackColor = System.Drawing.Color.White;
this.btnSavePosition.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnSavePosition.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnSavePosition.Location = new System.Drawing.Point(658, 64);
this.btnSavePosition.Location = new System.Drawing.Point(754, 64);
this.btnSavePosition.Name = "btnSavePosition";
this.btnSavePosition.Size = new System.Drawing.Size(128, 39);
this.btnSavePosition.TabIndex = 217;
......@@ -979,7 +981,7 @@ namespace OnlineStore.DUOStore
this.btnStartAuTo.BackColor = System.Drawing.Color.White;
this.btnStartAuTo.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnStartAuTo.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnStartAuTo.Location = new System.Drawing.Point(522, 64);
this.btnStartAuTo.Location = new System.Drawing.Point(618, 64);
this.btnStartAuTo.Name = "btnStartAuTo";
this.btnStartAuTo.Size = new System.Drawing.Size(128, 39);
this.btnStartAuTo.TabIndex = 222;
......@@ -1003,7 +1005,7 @@ namespace OnlineStore.DUOStore
this.txtJiange.Name = "txtJiange";
this.txtJiange.Size = new System.Drawing.Size(52, 26);
this.txtJiange.TabIndex = 221;
this.txtJiange.Text = "0";
this.txtJiange.Text = "3";
//
// cmbPosition
//
......@@ -1021,7 +1023,7 @@ namespace OnlineStore.DUOStore
this.btnInStore.BackColor = System.Drawing.Color.White;
this.btnInStore.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnInStore.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnInStore.Location = new System.Drawing.Point(250, 21);
this.btnInStore.Location = new System.Drawing.Point(346, 21);
this.btnInStore.Name = "btnInStore";
this.btnInStore.Size = new System.Drawing.Size(128, 39);
this.btnInStore.TabIndex = 102;
......@@ -1034,7 +1036,7 @@ namespace OnlineStore.DUOStore
this.btnOutStore.BackColor = System.Drawing.Color.White;
this.btnOutStore.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnOutStore.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnOutStore.Location = new System.Drawing.Point(386, 21);
this.btnOutStore.Location = new System.Drawing.Point(482, 21);
this.btnOutStore.Name = "btnOutStore";
this.btnOutStore.Size = new System.Drawing.Size(128, 39);
this.btnOutStore.TabIndex = 101;
......@@ -1337,7 +1339,7 @@ namespace OnlineStore.DUOStore
this.chbDisable.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.chbDisable.AutoSize = true;
this.chbDisable.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.chbDisable.Location = new System.Drawing.Point(10, 617);
this.chbDisable.Location = new System.Drawing.Point(153, 510);
this.chbDisable.Name = "chbDisable";
this.chbDisable.Size = new System.Drawing.Size(84, 24);
this.chbDisable.TabIndex = 274;
......@@ -1345,6 +1347,22 @@ namespace OnlineStore.DUOStore
this.chbDisable.UseVisualStyleBackColor = true;
this.chbDisable.CheckedChanged += new System.EventHandler(this.chbDisable_CheckedChanged);
//
// cmbHight
//
this.cmbHight.FormattingEnabled = true;
this.cmbHight.Items.AddRange(new object[] {
"8",
"12",
"16",
"24",
"32",
"56"});
this.cmbHight.Location = new System.Drawing.Point(252, 25);
this.cmbHight.Name = "cmbHight";
this.cmbHight.Size = new System.Drawing.Size(88, 28);
this.cmbHight.TabIndex = 311;
this.cmbHight.Text = "8";
//
// FrmBox
//
this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
......@@ -1470,6 +1488,7 @@ namespace OnlineStore.DUOStore
private System.Windows.Forms.Button btnNgPro;
private System.Windows.Forms.Label lblCanOut;
private System.Windows.Forms.CheckBox chbDisable;
private System.Windows.Forms.ComboBox cmbHight;
}
}
......@@ -76,7 +76,7 @@ namespace OnlineStore.DUOStore
chbDebug.Checked = BoxBean.IsDebug;
this.ShowInTaskbar = true;
txtTempPort.Text = BoxBean.Config.Humiture_Port;
txtTempPort.Text = BoxBean.Config.Humiture_Port;
timer1.Start();
}
#endregion
......@@ -227,7 +227,7 @@ namespace OnlineStore.DUOStore
{
string selectPositionNum = cmbPosition.Text;
LineMoveP ktk = LoadPostion();
BoxBean.StartInStoreMove(new InOutParam(MoveType.InStore, "", selectPositionNum, ktk));
BoxBean.StartInStoreMove(new InOutParam(MoveType.InStore, "#test#", selectPositionNum, ktk));
}
else
{
......@@ -239,7 +239,8 @@ namespace OnlineStore.DUOStore
{
LineMoveP ktk = new LineMoveP();
ktk.ComPress_P1 = FormUtil.GetIntValue(txtComP1);
ktk.ComPress_P2 = FormUtil.GetIntValue(txtComP2);
//ktk.ComPress_P2 = FormUtil.GetIntValue(txtComP2);
ktk.ComPress_P2 = BoxBean.Config.GetComP2(FormUtil.GetIntValue(cmbHight));
ktk.ComPress_P3 = FormUtil.GetIntValue(txtComP3);
ktk.InOut_P1 = FormUtil.GetIntValue(txtInOutP1);
ktk.InOut_P2 = FormUtil.GetIntValue(txtInOutP2);
......@@ -298,7 +299,7 @@ namespace OnlineStore.DUOStore
acPosition.UpdownAxis_IL_P4 = FormUtil.GetIntValue(txtUpDownP4);
acPosition.UpdownAxis_OH_P5 = FormUtil.GetIntValue(txtUpDownP5);
acPosition.UpdownAxis_OL_P6 = FormUtil.GetIntValue(txtUpDownP6);
acPosition.ComAxis_P2 = FormUtil.GetIntValue(txtComP2);
//acPosition.ComAxis_P2 = FormUtil.GetIntValue(txtComP2);
acPosition.ComAxis_P3 = FormUtil.GetIntValue(txtComP3);
}
//位置配置
......@@ -423,7 +424,7 @@ namespace OnlineStore.DUOStore
private void AxisAbsMove(ConfigMoveAxis moveAxis, TextBox txtValue, int targetSpeed)
{
if (moveAxis.IsSameAxis(BoxBean.Config.UpDown_Axis) || moveAxis.IsSameAxis(BoxBean.Config.UpDown_Axis))
if (moveAxis.IsSameAxis(BoxBean.Config.UpDown_Axis) || moveAxis.IsSameAxis(BoxBean.Config.Middle_Axis))
{
if (!InOutIsIsP1())
{
......
......@@ -32,7 +32,10 @@
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmStore));
this.tabControl1 = new System.Windows.Forms.TabControl();
this.tabPage1 = new System.Windows.Forms.TabPage();
this.pictureBox2 = new System.Windows.Forms.PictureBox();
this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.panel1 = new System.Windows.Forms.Panel();
this.BTN_ReleaseShelf = new System.Windows.Forms.Button();
this.chbInstoreEnd = new System.Windows.Forms.CheckBox();
this.chkDebug = new System.Windows.Forms.CheckBox();
this.lblMoveInfo = new System.Windows.Forms.Label();
......@@ -75,6 +78,8 @@
this.timer1 = new System.Windows.Forms.Timer(this.components);
this.tabControl1.SuspendLayout();
this.tabPage1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox2)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
this.panel1.SuspendLayout();
this.menuStrip1.SuspendLayout();
this.contextMenuStrip1.SuspendLayout();
......@@ -99,6 +104,8 @@
//
// tabPage1
//
this.tabPage1.Controls.Add(this.pictureBox2);
this.tabPage1.Controls.Add(this.pictureBox1);
this.tabPage1.Controls.Add(this.panel1);
this.tabPage1.Controls.Add(this.listView1);
this.tabPage1.Controls.Add(this.lblServerMsg);
......@@ -110,10 +117,29 @@
this.tabPage1.Text = " 日志信息 ";
this.tabPage1.UseVisualStyleBackColor = true;
//
// pictureBox2
//
this.pictureBox2.Location = new System.Drawing.Point(703, 374);
this.pictureBox2.Name = "pictureBox2";
this.pictureBox2.Size = new System.Drawing.Size(376, 236);
this.pictureBox2.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
this.pictureBox2.TabIndex = 273;
this.pictureBox2.TabStop = false;
//
// pictureBox1
//
this.pictureBox1.Location = new System.Drawing.Point(703, 126);
this.pictureBox1.Name = "pictureBox1";
this.pictureBox1.Size = new System.Drawing.Size(376, 242);
this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
this.pictureBox1.TabIndex = 272;
this.pictureBox1.TabStop = false;
//
// panel1
//
this.panel1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Right)));
this.panel1.Controls.Add(this.BTN_ReleaseShelf);
this.panel1.Controls.Add(this.chbInstoreEnd);
this.panel1.Controls.Add(this.chkDebug);
this.panel1.Controls.Add(this.lblMoveInfo);
......@@ -128,6 +154,19 @@
this.panel1.Size = new System.Drawing.Size(182, 623);
this.panel1.TabIndex = 271;
//
// BTN_ReleaseShelf
//
this.BTN_ReleaseShelf.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.BTN_ReleaseShelf.BackColor = System.Drawing.Color.White;
this.BTN_ReleaseShelf.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BTN_ReleaseShelf.Location = new System.Drawing.Point(12, 366);
this.BTN_ReleaseShelf.Name = "BTN_ReleaseShelf";
this.BTN_ReleaseShelf.Size = new System.Drawing.Size(140, 35);
this.BTN_ReleaseShelf.TabIndex = 272;
this.BTN_ReleaseShelf.Text = "强制释放料架";
this.BTN_ReleaseShelf.UseVisualStyleBackColor = false;
this.BTN_ReleaseShelf.Click += new System.EventHandler(this.BTN_ReleaseShelf_Click);
//
// chbInstoreEnd
//
this.chbInstoreEnd.AutoSize = true;
......@@ -509,6 +548,8 @@
this.tabControl1.ResumeLayout(false);
this.tabPage1.ResumeLayout(false);
this.tabPage1.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox2)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
this.menuStrip1.ResumeLayout(false);
......@@ -564,6 +605,9 @@
private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.CheckBox chbInstoreEnd;
private System.Windows.Forms.ToolStripMenuItem 显示日志ToolStripMenuItem;
private System.Windows.Forms.Button BTN_ReleaseShelf;
private System.Windows.Forms.PictureBox pictureBox1;
private System.Windows.Forms.PictureBox pictureBox2;
}
}
......@@ -57,7 +57,8 @@ namespace OnlineStore.DUOStore
AddForm(" 取料提升机构 ", new FrmAxisMove());
AddForm(" IO状态查看 ", new FrmIOStatus());
chbAutoRun.Checked = store.UseBuzzer;
chbUseBuzzer.Checked = (ConfigAppSettings.GetIntValue(Setting_Init.UseBuzzer).Equals(1));
//store.UseBuzzer = chbUseBuzzer.Checked;
this.Text = ConfigAppSettings.GetValue(Setting_Init.App_Title);
chbAutoRun.Checked = (ConfigAppSettings.GetIntValue(Setting_Init.App_AutoRun).Equals(1));
LoadListView();
......@@ -65,7 +66,8 @@ namespace OnlineStore.DUOStore
chbOutstoreEnd.Checked = store.OutstoreEndSendShelf;
LoadOk = true;
//LogUtil.logBox = this.logBox;
store.BoxMap[1].camera_event += FrmStore_camera_event;
store.BoxMap[2].camera_event += FrmStore_camera_event2;
this.timer1.Start();
}
catch (Exception ex)
......@@ -75,6 +77,14 @@ namespace OnlineStore.DUOStore
}
}
private void FrmStore_camera_event(object sender, Bitmap e)
{
pictureBox1.Image = e;
}
private void FrmStore_camera_event2(object sender, Bitmap e)
{
pictureBox2.Image = e;
}
private void LogUtil_showLogEvent(string msg, Color color)
{
this.Invoke(new Action(() => {
......@@ -738,5 +748,12 @@ namespace OnlineStore.DUOStore
btnClearLog.Visible = logBox.Visible;
}
private void BTN_ReleaseShelf_Click(object sender, EventArgs e)
{
if (!StoreManager.Store.ReleaseShelf()) {
MessageBox.Show("料串正在出入库中,不满足释放条件");
}
}
}
}
......@@ -94,6 +94,7 @@ namespace OnlineStore.DUOStore
}
}
}
System.Environment.CurrentDirectory = Application.StartupPath;
if (!isShow)
{
XmlConfigurator.Configure();
......
......@@ -19,7 +19,7 @@ namespace OnlineStore.DUOStore.Properties {
// 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
// 若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen
// (以 /str 作为命令选项),或重新生成 VS 项目。
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "15.0.0.0")]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources {
......@@ -47,8 +47,8 @@ namespace OnlineStore.DUOStore.Properties {
}
/// <summary>
/// 重写当前线程的 CurrentUICulture 属性
/// 重写当前线程的 CurrentUICulture 属性
/// 重写当前线程的 CurrentUICulture 属性,对
/// 使用此强类型资源类的所有资源查找执行重写
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture {
......
......@@ -12,7 +12,7 @@ namespace OnlineStore.DUOStore.Properties {
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.9.0.0")]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.8.1.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
......
......@@ -19,12 +19,12 @@ namespace OnlineStore.DeviceLibrary
{
return HCBoardManager.CloseCard();
}
public override void AbsMove(string portName, short slvAddr, int targetPosition, int targetSpeed,int ptpAcc,int ptpDec)
public override void AbsMove(string portName, short slvAddr, int targetPosition, int targetSpeed, int ptpAcc, int ptpDec)
{
HCLogUtil.LOGGER.Info($"slvAddr={slvAddr},targetPosition={targetPosition},targetSpeed={targetSpeed},ptpAcc={ptpAcc},ptpDec={ptpDec}");
HCBoardManager.AbsMove((short)slvAddr, targetPosition, targetSpeed, ptpAcc, ptpDec);
}
public override void AlarmClear(string portName, short slvAddr)
{
HCBoardManager.ClearAxisSts((short)slvAddr);
......@@ -34,15 +34,15 @@ namespace OnlineStore.DeviceLibrary
return true;
}
public override void ClearSpeed()
{
{
}
public override void CloseAllPort()
{
{
}
public override void ColsePort(string portName)
{
{
}
......@@ -58,7 +58,7 @@ namespace OnlineStore.DeviceLibrary
public override int GetAlarmStatus(string portName, short slvAddr)
{
AxisSts axisS= HCBoardManager.GetAxisSts(slvAddr);
AxisSts axisS = HCBoardManager.GetAxisSts(slvAddr);
return axisS.ALM;
}
......@@ -70,7 +70,7 @@ namespace OnlineStore.DeviceLibrary
public override int GetHomeEndStatus(string portName, short slvAddr)
{
return (int) HCBoardManager.GetHomeStatus(slvAddr);
return (int)HCBoardManager.GetHomeStatus(slvAddr);
}
public override int GetHomeSingle(string portName, short slvAddr)
......@@ -83,7 +83,7 @@ namespace OnlineStore.DeviceLibrary
{
AxisSts axisS = HCBoardManager.GetAxisSts(slvAddr);
return axisS.NEL;
}
}
public override int GetLimitPositiveSingle(string portName, short slvAddr)
{
AxisSts axisS = HCBoardManager.GetAxisSts(slvAddr);
......@@ -97,22 +97,22 @@ namespace OnlineStore.DeviceLibrary
public override void HomeMove(string portName, short slvAddr, int highVel, int lowVel, int acc)
{
HCBoardManager.StartHomeMove(slvAddr,(uint) highVel, (uint)lowVel, (uint)acc);
}
HCBoardManager.StartHomeMove(slvAddr, (uint)highVel, (uint)lowVel, (uint)acc);
}
public override bool IsHomeMoveEnd(string portName, short slvAddr)
{
return HCBoardManager.HomeingIsEnd(slvAddr);
return HCBoardManager.HomeingIsEnd(slvAddr);
}
public override bool isInPosition(string portName, short slvAddr, int PPosition, int canErrorCount, bool isLog = false)
{
return HCBoardManager.IsInPosition(slvAddr, PPosition,canErrorCount );
}
public override void RelMove(string portName, short slvAddr, int position, int targetSpeed, int ptpAcc , int ptpDec )
return HCBoardManager.IsInPosition(slvAddr, PPosition, canErrorCount);
}
public override void RelMove(string portName, short slvAddr, int position, int targetSpeed, int ptpAcc, int ptpDec)
{
HCBoardManager.RelMove(slvAddr, position, targetSpeed, ptpAcc, ptpDec);
}
public override bool IsServeoOn(string portName, short slvAddr)
{
AxisSts axisS = HCBoardManager.GetAxisSts(slvAddr);
......@@ -132,7 +132,7 @@ namespace OnlineStore.DeviceLibrary
public override void SpeedMove(string portName, short slvAddr, int speed)
{
HCBoardManager.SpeedMove(slvAddr, speed);
}
}
public override void SuddenStop(string portName, short slvAddr)
{
HCBoardManager.AxisStop(slvAddr);
......@@ -154,8 +154,10 @@ namespace OnlineStore.DeviceLibrary
}
return false;
}
public override short GetErrorCode(string portName, short slvAddr)
public override short GetErrorCode(string portName, short slvAddr)
{
AxisSts axisS = HCBoardManager.GetAxisSts(slvAddr);
HCLogUtil.LOGGER.Info(axisS.ToStr());
return HCBoardManager.GetAxErrCode(slvAddr);
}
}
......
using Asa;
using Agv;
using OnlineStore.Common;
using System;
using System.Collections.Generic;
......@@ -10,35 +10,36 @@ namespace OnlineStore.DeviceLibrary
{
public class AgvClient
{
public static bool CurrCancelState = false;
private static string ServerIp = ConfigAppSettings.GetValue(Setting_Init.AgvServerIp);
private static Asa.AgvClient agvClient;
public static Dictionary<string, Asa.ClientAction> actionMap = new Dictionary<string, Asa.ClientAction>();
private static int ServerPort = ConfigAppSettings.GetIntValue(Setting_Init.AgvServerPort);
private static Agv.AgvClient agvClient;
public static Dictionary<string, Agv.ClientAction> actionMap = new Dictionary<string, Agv.ClientAction>();
public static List<string> NodeList = new List<string>();
private static bool isInit = false;
public static void Init()
{
try
{
// LogUtil.info("开始 Init agvclient");
if (!isInit)
{
isInit = true;
agvClient = new Asa.AgvClient(ServerIp);
agvClient.CancelState = true;
agvClient.Log += AgvClient_Log;
agvClient.Arrive += AgvClient_Arrive;
agvClient.Ready += AgvClient_Ready;
agvClient.CloseDoor += AgvClient_CloseDoor;
agvClient = new Agv.AgvClient();
agvClient.Received += AgvClient_Received;
NodeList.Add(StoreManager.Config.AgvInName);
NodeList.Add(StoreManager.Config.AgvOutName);
}
actionMap = new Dictionary<string, Asa.ClientAction>();
LogUtil.info(" 开始 agvClient.Connect");
agvClient.Connect();
actionMap = new Dictionary<string, Agv.ClientAction>();
foreach (string key in NodeList)
{
actionMap.Add(key, Agv.ClientAction.None);
}
agvClient.Connect(ServerIp, ServerPort);
foreach (string str in NodeList)
{
SetStatus(str);
SetStatus(str,"");
LogUtil.info("agv init ,SetStatus[" + str + "]=none ");
}
SetCancelState(false);
}
catch (Exception ex)
{
......@@ -46,43 +47,46 @@ namespace OnlineStore.DeviceLibrary
}
}
public static void SetCancelState(bool isCancel)
private static void AgvClient_Connected(bool status)
{
LogUtil.info($"AgvClient_Connected:{status}");
}
CurrCancelState = isCancel;
if (agvClient != null)
{
agvClient.CancelState = isCancel;
}
private static void AgvClient_Received(Node node)
{
/*var nodename = node.Name;
if (nodename == StoreManager.Config.AgvInName) {
SetStatus(nodename, "", ClientAction.MayEnter);
_ = StoreManager.Store.AgvSendShelfIn();
}
else if (nodename == StoreManager.Config.AgvOutName) {
SetStatus(nodename, "", ClientAction.MayLeave);
StoreManager.Store.OneShelfOutProcess();
}*/
AgvClient_Ready(node.Name, node.RFID);
}
public static void SetCancelState(bool cancel)
{
agvClient.CancelState = cancel;
}
public static void SetStatus(string id, string shelfId = "", ClientAction action = ClientAction.None, ClientLevel level = ClientLevel.Low, bool isMust = false)
public static void SetStatus(string id, string shelfId, ClientAction action = ClientAction.None, ClientLevel level = ClientLevel.Low, bool isMust = false)
{
if (agvClient == null)
return;
if (!isMust)
{
if (actionMap.ContainsKey(id))
{
ClientAction currA = actionMap[id]; //相同状态就设置一次
if (currA.Equals(action))
{
return;
}
}
}
string mark = "";
if (shelfId != "")
if (actionMap.ContainsKey(id))
{
int index = shelfId.IndexOf(',');
if (index > 0)
Agv.ClientAction currA = actionMap[id]; //相同状态就设置一次
if (currA.Equals(action))
{
//紧急出料模块,料串离开时,mark=紧急料或者分配料,rfid=料串号
mark = shelfId.Substring(index + 1, shelfId.Length - index - 1);
shelfId = shelfId.Substring(0, index);
return;
}
}
agvClient.SetStatus(id, mark, shelfId, action, level);
agvClient.SetStatus(id, "", shelfId, action, level);
UpdateAction(id, action);
LogUtil.info("AgvClient SetStatus id:" + id + ",mark:" + mark + ",shelfId:" + shelfId + ",action:" + action.ToString() + ",level:" + level.ToString());
LogUtil.info("AgvClient SetStatus id:" + id + ",shelfId:" + shelfId + ",action:" + action.ToString() + ",level:" + level.ToString());
}
......@@ -95,7 +99,7 @@ namespace OnlineStore.DeviceLibrary
if (GetAction(id) == ClientAction.NeedEnter || id == StoreManager.Config.AgvInName)
{
SetStatus(id, "", ClientAction.MayEnter);
_ = StoreManager.Store.AgvSendShelfIn();
_=StoreManager.Store.AgvSendShelfIn();
}
else if (GetAction(id) == ClientAction.NeedLeave || id == StoreManager.Config.AgvOutName)
{
......@@ -112,15 +116,6 @@ namespace OnlineStore.DeviceLibrary
LogUtil.error("AgvClient_Ready [" + id + "] [" + rfid + "] 处理出错:" + ex.ToString());
}
}
private static void AgvClient_CloseDoor(string id, string rfid)
{
LogUtil.info("收到 AgvClient_CloseDoor [" + id + "] [" + rfid + "] 暂无需处理 ");
}
private static void AgvClient_Arrive(string id, string rfid)
{
// UpdateAction(id, ClientAction.Arrive);
LogUtil.info("收到 AgvClient_Arrive [" + id + "] [" + rfid + "]暂无需处理 ");
}
internal static bool ISConnected()
{
......@@ -133,60 +128,44 @@ namespace OnlineStore.DeviceLibrary
public static bool SetToNone(string id, string shelfId = "")
{
ClientAction currA = GetAction(id);
if (currA.Equals(ClientAction.None) || currA.Equals(ClientAction.NeedLeave) || currA.Equals(ClientAction.NeedEnter))
Agv.ClientAction currA = GetAction(id);
if (currA.Equals(Agv.ClientAction.None) || currA.Equals(Agv.ClientAction.NeedLeave) || currA.Equals(Agv.ClientAction.NeedEnter))
{
SetStatus(id, shelfId, ClientAction.None);
SetStatus(id, shelfId, Agv.ClientAction.None);
return true;
}
return false;
}
public static bool NeedEnter(string id, string shelfId = "", ClientLevel level = ClientLevel.Low)
public static bool NeedEnter(string id, string shelfId)
{
ClientAction currA = GetAction(id);
if (currA.Equals(ClientAction.None) || currA.Equals(ClientAction.NeedLeave) || currA.Equals(ClientAction.NeedEnter))
Agv.ClientAction currA = GetAction(id);
if (currA.Equals(Agv.ClientAction.None) || currA.Equals(Agv.ClientAction.NeedLeave) || currA.Equals(Agv.ClientAction.NeedEnter))
{
SetStatus(id, shelfId, ClientAction.NeedEnter, level);
SetStatus(id, shelfId, Agv.ClientAction.NeedEnter);
return true;
}
return false;
}
public static bool NeedLeave(string id, string shelfId = "", ClientLevel level = ClientLevel.Low)
public static bool NeedLeave(string id, string shelfId)
{
ClientAction currA = GetAction(id);
if (currA.Equals(ClientAction.None) || currA.Equals(ClientAction.NeedLeave) || currA.Equals(ClientAction.NeedEnter))
Agv.ClientAction currA = GetAction(id);
if (currA.Equals(Agv.ClientAction.None) || currA.Equals(Agv.ClientAction.NeedLeave) || currA.Equals(Agv.ClientAction.NeedEnter))
{
SetStatus(id, shelfId, ClientAction.NeedLeave, level);
SetStatus(id, shelfId, Agv.ClientAction.NeedLeave);
return true;
}
return false;
}
private static bool isLog = true;//ConfigAppSettings.GetIntValue(Setting_Init.Agv_Log_Open).Equals(1);
private static void AgvClient_Log(string s)
{
try
{
if (isLog)
{
LogUtil.info(" AGV " + ServerIp + " Log : " + s);
}
}
catch (Exception ex)
{
LogUtil.error("AgvClient_Log 出错:" + ex.ToString());
}
}
public static Asa.ClientAction GetAction(string NodeName)
public static Agv.ClientAction GetAction(string NodeName)
{
if (actionMap.ContainsKey(NodeName))
{
return actionMap[NodeName];
}
return Asa.ClientAction.None;
return Agv.ClientAction.None;
}
public static void UpdateAction(string name, Asa.ClientAction action)
public static void UpdateAction(string name, Agv.ClientAction action)
{
if (actionMap.ContainsKey(name))
{
......@@ -203,12 +182,13 @@ namespace OnlineStore.DeviceLibrary
{
if (agvClient != null)
{
SetCancelState(true);
agvClient.Close();
}
}
catch (Exception ex)
{
LogUtil.error("释放 agvClient " + ServerIp + " 出错:", ex);
LogUtil.error("agvClient.Close " + ServerIp + " 出错:", ex);
}
}
}
......
......@@ -9,7 +9,7 @@
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>OnlineStore.DeviceLibrary</RootNamespace>
<AssemblyName>DeviceLibrary</AssemblyName>
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile />
</PropertyGroup>
......@@ -36,13 +36,24 @@
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="Agv">
<HintPath>..\..\..\775-AGVClientTest\Agv.dll</HintPath>
</Reference>
<Reference Include="Agv.Client">
<HintPath>..\..\..\775-AGVClientTest\Agv.Client.dll</HintPath>
</Reference>
<Reference Include="Asa.HIK.IPCamera">
<HintPath>..\..\..\camera\Asa.HIK.IPCamera.dll</HintPath>
</Reference>
<Reference Include="Asa.IOModule.AIOBOX, Version=2.4.0.7, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\AIOBOX\AIOBOX\bin\Debug\Asa.IOModule.AIOBOX.dll</HintPath>
</Reference>
<Reference Include="Client, Version=1.0.0.1, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\dll\Client.dll</HintPath>
<Reference Include="Asa.RFID.HiStation">
<HintPath>..\..\..\..\work\RFID\Asa.RFID.HiStation.dll</HintPath>
</Reference>
<Reference Include="Asa.RFID.IReadAll">
<HintPath>..\..\..\..\work\RFID\Asa.RFID.IReadAll.dll</HintPath>
</Reference>
<Reference Include="CodeLibrary, Version=1.0.7380.18241, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
......@@ -81,6 +92,8 @@
<Compile Include="AXIS\PanasonicServo\ACServerManager.cs" />
<Compile Include="AXIS\PanasonicServo\ACServerManager_Partial.cs" />
<Compile Include="device\IO\HCIOManager.cs" />
<Compile Include="device\RFIDManagercs.cs" />
<Compile Include="duoStore\BoxBean_Camera.cs" />
<Compile Include="duoStore\DUOStoreBean_RaiseStation.cs" />
<Compile Include="duoStore\AxisBean.cs" />
<Compile Include="duoStore\BoxBean.cs" />
......@@ -140,13 +153,13 @@
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
<None Include="StoreConfig\StoreConfig.csv">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Include="StoreConfig\BoxConfig_2.csv">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Include="StoreConfig\BoxConfig_1.csv">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
......
类型,分类编号,说明,名称,属性值,设备名称,电器定义,目标速度,加速时间,减速时间,原点低速度,原点高速,原点加速度,脉冲最小误差,脉冲最大误差,脉冲最小限位,脉冲最大限位
AXIS,,L1_旋转轴,Middle_Axis,0,HC,,800,2400,2400,50,250,3000,10,1000,0,0
AXIS,,L2_上下轴,UpDown_Axis,1,HC,,2000,6000,6000,50,250,3000,10,1000,0,0
AXIS,,L1_旋转轴,Middle_Axis,0,HC,,800,2400,2400,50,250,3000,5,20,0,0
AXIS,,L2_上下轴,UpDown_Axis,1,HC,,2000,3000,6000,50,250,3000,10,100,0,0
AXIS,,L3_进出轴,InOut_Axis,2,HC,,1000,5000,5000,50,300,8000,10,1000,0,0
AXIS,,L4_压紧轴,Comp_Axis,3,HC,,10000,25000,25000,3000,10000,20000,10,1000,0,0
AXIS,,L4_压紧轴,Comp_Axis,3,HC,,10000,60000,60000,3000,10000,20000,10,1000,0,0
,,,,,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,,L2_上下轴_P1待机点/入料口低点,UpDownAxis_P1,10,,,,,,,,,,,,
PRO,,L2_上下轴_P2入料口高点,UpDownAxis_P2,10,,,,,,,,,,,,
PRO,,L1_旋转轴_P1待机点/入料口位置,MiddleAxis_P1,10,,,,,,,,,,,,
PRO,,L3_进出轴_P1待机点,InOutAxis_P1,10,,,,,,,,,,,,
PRO,,L4_压紧轴_P1待机点,CompAxis_P1,10,,,,,,,,,,,,
PRO,,L4_压紧轴_P2压紧点范围对应值,CompAxis_P2_List,8=247455;12=383001;16=379001;,,,,,,,,,,,,
PRO,,L2_上下轴_P1待机点/入料口低点,UpDownAxis_P1,4510,,,,,,,,,,,,
PRO,,L2_上下轴_P2入料口高点,UpDownAxis_P2,4726,,,,,,,,,,,,
PRO,,L1_旋转轴_P1待机点/入料口位置,MiddleAxis_P1,8041,,,,,,,,,,,,
PRO,,L3_进出轴_P1待机点,InOutAxis_P1,0,,,,,,,,,,,,
PRO,,L4_压紧轴_P1待机点,CompAxis_P1,20000,,,,,,,,,,,,
PRO,,L4_压紧轴_P2压紧点范围对应值,CompAxis_P2_List,8=49514;12=44615;16=39596;,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,,L2_上下轴_P11-出料口-低点,UpDownAxis_P11,10,,,,,,,,,,,,
PRO,,L2_上下轴_P12-出料口-高点,UpDownAxis_P12,10,,,,,,,,,,,,
PRO,,L1_旋转轴_P11-出料口位置,MiddleAxis_P11,10,,,,,,,,,,,,
PRO,,L3_进出轴_P2-入料口取放料点,InOutAxis_P2,10,,,,,,,,,,,,
PRO,,L3_进出轴_P11-出料口取放料点,InOutAxis_P11,10,,,,,,,,,,,,
PRO,,L2_上下轴_P11-出料口-低点,UpDownAxis_P11,2815,,,,,,,,,,,,
PRO,,L2_上下轴_P12-出料口-高点,UpDownAxis_P12,2919,,,,,,,,,,,,
PRO,,L1_旋转轴_P11-出料口位置,MiddleAxis_P11,1237,,,,,,,,,,,,
PRO,,L3_进出轴_P2-入料口取放料点,InOutAxis_P2,4623,,,,,,,,,,,,
PRO,,L3_进出轴_P11-出料口取放料点,InOutAxis_P11,4497,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,,L2_上下轴_P1速度/高速,UpDownAxis_P1_Speed,2000,,,,,,,,,,,,
PRO,,L2_上下轴_P2速度/低速,UpDownAxis_P2_Speed,2000,,,,,,,,,,,,
PRO,,L2_上下轴_P1速度/高速,UpDownAxis_P1_Speed,1500,,,,,,,,,,,,
PRO,,L2_上下轴_P2速度/低速,UpDownAxis_P2_Speed,150,,,,,,,,,,,,
PRO,,L2_上下轴_P3速度,UpDownAxis_P3_Speed,2000,,, ,,,,,,,,,
PRO,,L2_上下轴_P4速度,UpDownAxis_P4_Speed,150,,,,,,,,,,,,
PRO,,L2_上下轴_P5速度,UpDownAxis_P5_Speed,2000,,,,,,,,,,,,
PRO,,L2_上下轴_P6速度,UpDownAxis_P6_Speed,150,,,,,,,,,,,,
PRO,,L2_上下轴_P7速度,UpDownAxis_P7_Speed,2000,,,,,,,,,,,,
PRO,,L2_上下轴_P8速度,UpDownAxis_P8_Speed,100,,,,,,,,,,,,
PRO,,L1_旋转轴_P1速度,MiddleAxis_P1_Speed,800,,,,,,,,,,,,
PRO,,L1_旋转轴_P2速度,MiddleAxis_P2_Speed,800,,,,,,,,,,,,
PRO,,L3_进出轴_P1速度,InOutAxis_P1_Speed,1600,,,,,,,,,,,,
PRO,,L3_进出轴_P2速度,InOutAxis_P2_Speed,1800,,,,,,,,,,,,
PRO,,L3_进出轴_P3速度,InOutAxis_P3_Speed,1800,,,,,,,,,,,,
PRO,,L4_压紧轴_P1速度,CompAxis_P1_Speed,5000,,,,,,,,,,,,
PRO,,L4_压紧轴_P2速度,CompAxis_P2_Speed,8500,,,,,,,,,,,,
PRO,,L4_压紧轴_P3速度,CompAxis_P3_Speed,8500,,,,,,,,,,,,
PRO,,L1_旋转轴_P1速度,MiddleAxis_P1_Speed,1000,,,,,,,,,,,,
PRO,,L1_旋转轴_P2速度,MiddleAxis_P2_Speed,1000,,,,,,,,,,,,
PRO,,L3_进出轴_P1速度,InOutAxis_P1_Speed,3000,,,,,,,,,,,,
PRO,,L3_进出轴_P2速度,InOutAxis_P2_Speed,3000,,,,,,,,,,,,
PRO,,L3_进出轴_P3速度,InOutAxis_P3_Speed,3000,,,,,,,,,,,,
PRO,,L4_压紧轴_P1速度,CompAxis_P1_Speed,8000,,,,,,,,,,,,
PRO,,L4_压紧轴_P2速度,CompAxis_P2_Speed,30000,,,,,,,,,,,,
PRO,,L4_压紧轴_P3速度,CompAxis_P3_Speed,10000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,,L2_上下轴_P11速度/低速,UpDownAxis_P11_Speed,1000,,,,,,,,,,,,
PRO,,L2_上下轴_P12速度/高速,UpDownAxis_P12_Speed,2000,,,,,,,,,,,,
PRO,,L3_进出轴_P11速度,InOutAxis_P11_Speed,1800,,,,,,,,,,,,
PRO,,L1_旋转轴_P11速度,MiddleAxis_P11_Speed,800,,,,,,,,,,,,
PRO,,L2_上下轴_P11速度/低速,UpDownAxis_P11_Speed,150,,,,,,,,,,,,
PRO,,L2_上下轴_P12速度/高速,UpDownAxis_P12_Speed,1500,,,,,,,,,,,,
PRO,,L3_进出轴_P11速度,InOutAxis_P11_Speed,3000,,,,,,,,,,,,
PRO,,L1_旋转轴_P11速度,MiddleAxis_P11_Speed,1000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,,温湿度端口号,Humiture_Port,COM5,,,,,,,,,,,,
PRO,,是否是调试状态,IsInDebug,0,,,,,,,,,,,,
PRO,,是否使用料叉盘检测信号,IsUse_Tray_Check,0,,,,,,,,,,,,
PRO,,旋转轴反转点位补偿,MiddleAxis_Reverse_Offset,11,,,,,,,,,,,,
类型,分类编号,说明,名称,属性值,设备名称,电器定义,目标速度,加速时间,减速时间,原点低速度,原点高速,原点加速度,脉冲最小误差,脉冲最大误差,脉冲最小限位,脉冲最大限位
AXIS,,R1_旋转轴,Middle_Axis,8,HC,,800,2400,2400,50,250,3000,10,1000,0,0
AXIS,,R2_上下轴,UpDown_Axis,9,HC,,2000,6000,6000,50,250,3000,10,1000,0,0
AXIS,,R2_上下轴,UpDown_Axis,9,HC,,2000,3000,6000,50,250,3000,10,1000,0,0
AXIS,,R3_进出轴,InOut_Axis,10,HC,,1000,5000,5000,50,300,8000,10,1000,0,0
AXIS,,R4_压紧轴,Comp_Axis,11,HC,,10000,25000,25000,3000,10000,20000,10,1000,0,0
,,,,,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,,R2_上下轴_P1待机点/扫码放料低点,UpDownAxis_P1,10,,,,,,,,,,,,
PRO,,R2_上下轴_P2扫码放料高点缓冲点,UpDownAxis_P2,10,,,,,,,,,,,,
PRO,,R1_旋转轴_P1待机点/扫码放料点,MiddleAxis_P1,10,,,,,,,,,,,,
PRO,,R3_进出轴_P1待机点,InOutAxis_P1,10,,,,,,,,,,,,
PRO,,R4_压紧轴_P1待机点,CompAxis_P1,10,,,,,,,,,,,,
PRO,,L4_压紧轴_P2压紧点范围对应值,CompAxis_P2_List,8=247455;12=383001;16=379001;,,,,,,,,,,,,
PRO,,R2_上下轴_P1待机点/扫码放料低点,UpDownAxis_P1,4542,,,,,,,,,,,,
PRO,,R2_上下轴_P2扫码放料高点缓冲点,UpDownAxis_P2,4759,,,,,,,,,,,,
PRO,,R1_旋转轴_P1待机点/扫码放料点,MiddleAxis_P1,1806,,,,,,,,,,,,
PRO,,R3_进出轴_P1待机点,InOutAxis_P1,0,,,,,,,,,,,,
PRO,,R4_压紧轴_P1待机点,CompAxis_P1,20000,,,,,,,,,,,,
PRO,,L4_压紧轴_P2压紧点范围对应值,CompAxis_P2_List,8=49514;12=44615;16=39596;,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,,R2_上下轴_P11-出料口-低点,UpDownAxis_P11,10,,,,,,,,,,,,
PRO,,R2_上下轴_P12-出料口-高点,UpDownAxis_P12,10,,,,,,,,,,,,
PRO,,R1_旋转轴_P11-出料口位置,MiddleAxis_P11,10,,,,,,,,,,,,
PRO,,R3_进出轴_P2-入料口取放料点,InOutAxis_P2,10,,,,,,,,,,,,
PRO,,R3_进出轴_P11-出料口取放料点,InOutAxis_P11,10,,,,,,,,,,,,
PRO,,R2_上下轴_P11-出料口-低点,UpDownAxis_P11,2849,,,,,,,,,,,,
PRO,,R2_上下轴_P12-出料口-高点,UpDownAxis_P12,2979,,,,,,,,,,,,
PRO,,R1_旋转轴_P11-出料口位置,MiddleAxis_P11,8607,,,,,,,,,,,,
PRO,,R3_进出轴_P2-入料口取放料点,InOutAxis_P2,4623,,,,,,,,,,,,
PRO,,R3_进出轴_P11-出料口取放料点,InOutAxis_P11,4497,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,,R2_上下轴_P1速度/高速,UpDownAxis_P1_Speed,2000,,,,,,,,,,,,
PRO,,R2_上下轴_P2速度/低速,UpDownAxis_P2_Speed,2000,,,,,,,,,,,,
PRO,,R2_上下轴_P1速度/高速,UpDownAxis_P1_Speed,1500,,,,,,,,,,,,
PRO,,R2_上下轴_P2速度/低速,UpDownAxis_P2_Speed,150,,,,,,,,,,,,
PRO,,R2_上下轴_P3速度,UpDownAxis_P3_Speed,2000,,, ,,,,,,,,,
PRO,,R2_上下轴_P4速度,UpDownAxis_P4_Speed,150,,,,,,,,,,,,
PRO,,R2_上下轴_P5速度,UpDownAxis_P5_Speed,2000,,,,,,,,,,,,
PRO,,R2_上下轴_P6速度,UpDownAxis_P6_Speed,150,,,,,,,,,,,,
PRO,,R2_上下轴_P7速度,UpDownAxis_P7_Speed,2000,,,,,,,,,,,,
PRO,,R2_上下轴_P8速度,UpDownAxis_P8_Speed,100,,,,,,,,,,,,
PRO,,R1_旋转轴_P1速度,MiddleAxis_P1_Speed,800,,,,,,,,,,,,
PRO,,R1_旋转轴_P2速度,MiddleAxis_P2_Speed,800,,,,,,,,,,,,
PRO,,R3_进出轴_P1速度,InOutAxis_P1_Speed,1600,,,,,,,,,,,,
PRO,,R3_进出轴_P2速度,InOutAxis_P2_Speed,1800,,,,,,,,,,,,
PRO,,R3_进出轴_P3速度,InOutAxis_P3_Speed,1800,,,,,,,,,,,,
PRO,,R4_压紧轴_P1速度,CompAxis_P1_Speed,5000,,,,,,,,,,,,
PRO,,R4_压紧轴_P2速度,CompAxis_P2_Speed,8500,,,,,,,,,,,,
PRO,,R4_压紧轴_P3速度,CompAxis_P3_Speed,8500,,,,,,,,,,,,
PRO,,R1_旋转轴_P1速度,MiddleAxis_P1_Speed,1000,,,,,,,,,,,,
PRO,,R1_旋转轴_P2速度,MiddleAxis_P2_Speed,1000,,,,,,,,,,,,
PRO,,R3_进出轴_P1速度,InOutAxis_P1_Speed,3000,,,,,,,,,,,,
PRO,,R3_进出轴_P2速度,InOutAxis_P2_Speed,3000,,,,,,,,,,,,
PRO,,R3_进出轴_P3速度,InOutAxis_P3_Speed,3000,,,,,,,,,,,,
PRO,,R4_压紧轴_P1速度,CompAxis_P1_Speed,6000,,,,,,,,,,,,
PRO,,R4_压紧轴_P2速度,CompAxis_P2_Speed,9500,,,,,,,,,,,,
PRO,,R4_压紧轴_P3速度,CompAxis_P3_Speed,9500,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,,R2_上下轴_P11速度/低速,UpDownAxis_P11_Speed,1000,,,,,,,,,,,,
PRO,,R2_上下轴_P12速度/高速,UpDownAxis_P12_Speed,2000,,,,,,,,,,,,
PRO,,R3_进出轴_P11速度,InOutAxis_P11_Speed,1800,,,,,,,,,,,,
PRO,,R1_旋转轴_P11速度,MiddleAxis_P11_Speed,800,,,,,,,,,,,,
PRO,,R2_上下轴_P11速度/低速,UpDownAxis_P11_Speed,150,,,,,,,,,,,,
PRO,,R2_上下轴_P12速度/高速,UpDownAxis_P12_Speed,1500,,,,,,,,,,,,
PRO,,R3_进出轴_P11速度,InOutAxis_P11_Speed,3000,,,,,,,,,,,,
PRO,,R1_旋转轴_P11速度,MiddleAxis_P11_Speed,1000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,,温湿度端口号,Humiture_Port,COM5,,,,,,,,,,,,
PRO,,是否是调试状态,IsInDebug,0,,,,,,,,,,,,
PRO,,是否使用料叉盘检测信号,IsUse_Tray_Check,0,,,,,,,,,,,,
PRO,,旋转轴反转点位补偿,MiddleAxis_Reverse_Offset,6,,,,,,,,,,,,
\ No newline at end of file
类型,分类编号,说明,名称,属性值,设备名称,电器定义,目标速度,加速时间,减速时间,原点低速度,原点高速,原点加速度,脉冲最小误差,脉冲最大误差,脉冲最小限位,脉冲最大限位
AXIS,,T1_提升机构升降轴,T1_Batch_Axis,4,HC,,250,500,500,100,200,1000,10,1000,0,0
AXIS,,T2_取料机构旋转轴,T2_Middle_Axis,5,HC,,1000,1000,1000,200,500,500,10,1000,0,0
AXIS,,T3_取料机构上下轴,T3_Updown_Axis,6,HC,,800,1000,1000,200,500,500,10,1000,0,0
AXIS,,T4_取料机构进出轴,T4_InOut_Axis,7,HC,,800,1000,1000,200,500,500,10,1000,0,0
AXIS,,T1_提升机构升降轴,T1_Batch_Axis,4,HC,,18000,60000,60000,8000,18000,40000,1000,1000,0,0
AXIS,,T2_取料机构旋转轴,T2_Middle_Axis,6,HC,,1500,3000,3000,100,500,3000,10,1000,0,0
AXIS,,T3_取料机构上下轴,T3_Updown_Axis,5,HC,,20000,60000,60000,2000,7000,21000,10,1000,0,0
AXIS,,T4_取料机构进出轴,T4_InOut_Axis,7,HC,,600,1500,1500,50,300,1500,10,1000,0,0
,,,,,,,,,,,,,,,,
PRO,,IO模块对应的DI数量,IO_DILength,192.168.201.21#16;192.168.201.22#16;192.168.200.23#8,,,,,,,,,,,,
PRO,,IO模块对应的DO数量,IO_DOLength,192.168.201.21#16;192.168.201.22#16;192.168.200.23#8,,,,,,,,,,,,
......@@ -39,7 +39,7 @@ DI,2,右侧料叉激光定位,Fixture_Laser,24,HC,X24,*,,,,,,,,,
DI,0,取料气缸料盘检测,ClampCylinder_Check,25,HC,X25,,,,,,,,,,
DI,0,提升工位料盘定位检测,BatchAxis_Check,26,HC,X26,,,,,,,,,,
DI,0,7寸料盘宽度检测,TrayCheck_7,27,HC,X27,*,,,,,,,,,
DI,0,11/13/15寸料盘宽度检测,TrayCheck_11to15,28,HC,X28,*,,,,,,,,,
DI,0,11/13寸料盘宽度检测,TrayCheck_11to13,28,HC,X28,*,,,,,,,,,
DI,0,提升工位前端料串检测,RaiseStation_FrontCheck,29,HC,X29,*,,,,,,,,,
DI,0,提升工位末端料串检测,RaiseStation_BackendCheck,30,HC,X30,*,,,,,,,,,
DI,0,提升工位定位1上升端,RaiseStation_UpLocation1,31,HC,X31,*,,,,,,,,,
......@@ -50,6 +50,14 @@ DI,0,设备左侧防护门打开端,LeftDoor_Open,35,HC,X35,*,,,,,,,,,
DI,0,设备左侧防护门关闭端,LeftDoor_Close,36,HC,X36,*,,,,,,,,,
DI,0,设备右侧防护门打开端,RightDoor_Open,37,HC,X37,*,,,,,,,,,
DI,0,设备右侧防护门关闭端,RightDoor_Close,38,HC,X38,*,,,,,,,,,
DI,0,15寸料盘宽度检测,TrayCheck_15,39,HC,X39,*,,,,,,,,,
DI,0,卡爪范围确认,Clamp_InRange,40,HC,X40,*,,,,,,,,,
DI,0,卡爪动作中,Clamp_Busy,41,HC,X41,*,,,,,,,,,
DI,0,卡爪异常代码1,Clamp_Abnormal1,42,HC,X42,*,,,,,,,,,
DI,0,卡爪异常代码2,Clamp_Abnormal2,43,HC,X43,*,,,,,,,,,
DI,0,卡爪物件辨识1,Clamp_ObjRecognize1,44,HC,X44,*,,,,,,,,,
DI,0,卡爪物件辨识2,Clamp_ObjRecognize2,45,HC,X45,*,,,,,,,,,
DI,0,卡爪物件辨识3,Clamp_ObjRecognize3,46,HC,X46,*,,,,,,,,,
,,,,,,,,,,,,,,,,
DO,0,自动指示灯,AutoRun_HddLed,0,HC,Y00,,,,,,,,,,
DO,0,故障指示灯,Alarm_HddLed,1,HC,Y01,,,,,,,,,,
......@@ -74,7 +82,7 @@ DO,0,线体横移顶升上升,TopCylinder_Up,19,HC,Y19,,,,,,,,,,
DO,0,线体横移顶升下降,TopCylinder_Down,20,HC,Y20,,,,,,,,,,
DO,0,提升工位定位上升,RaiseStation_LocationUp,21,HC,Y21,*,,,,,,,,,
DO,0,提升工位定位下降,RaiseStation_LocationDown,22,HC,Y22,*,,,,,,,,,
,0,设备左侧防护门打开,LeftDoor_Open,23,HC,Y23,*,,,,,,,,,
DO,0,设备左侧防护门打开,LeftDoor_Open,23,HC,Y23,*,,,,,,,,,
DO,0,设备左侧防护门关闭,LeftDoor_Close,24,HC,Y24,*,,,,,,,,,
DO,1,左侧出料口门上升,OutDoor_Up,25,HC,Y25,,,,,,,,,,
DO,1,左侧出料口门下降,OutDoor_Down,26,HC,Y26,,,,,,,,,,
......@@ -82,44 +90,52 @@ DO,0,设备右侧防护门打开,RightDoor_Open,27,HC,Y27,*,,,,,,,,,
DO,0,设备右侧防护门关闭,RightDoor_Close,28,HC,Y28,*,,,,,,,,,
DO,2,右侧出料口门上升,OutDoor_Up,29,HC,Y29,,,,,,,,,,
DO,2,右侧出料口门下降,OutDoor_Down,30,HC,Y30,,,,,,,,,,
DO,0,卡爪指令编码0,Clamp_SetPos0,31,HC,Y31,*,,,,,,,,,
DO,1,卡爪指令编码1,Clamp_SetPos1,32,HC,Y32,*,,,,,,,,,
DO,2,卡爪指令编码2,Clamp_SetPos2,33,HC,Y33,*,,,,,,,,,
DO,3,卡爪指令编码3,Clamp_SetPos3,34,HC,Y34,*,,,,,,,,,
DO,4,卡爪指令编码4,Clamp_SetPos4,35,HC,Y35,*,,,,,,,,,
DO,5,卡爪动作指令,Clamp_DoAction,36,HC,Y36,*,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,T1_提升轴待机点 P1,BatchAxis_P1,5000,,,,, ,,,,,,,
PRO,0,T1_提升轴上升目标点_P2,BatchAxis_P2,4000,,,,, ,,,,,,,
PRO,0,T1_提升轴P1速度,BatchAxis_P1Speed,4000,,,,,,,,,,,,
PRO,0,T1_提升轴P2速度,BatchAxis_P2Speed,500,,,,, ,,,,,,,
PRO,0,T1_提升轴高度转换系数(1mm对应的脉冲),BatchAxis_ChangeValue,11000,,,,,,,,,,,,
PRO,0,T1_提升轴待机点 P1,BatchAxis_P1,500,,,,, ,,,,,,,
PRO,0,T1_提升轴上升目标点_P2,BatchAxis_P2,562083,,,,, ,,,,,,,
PRO,0,T1_提升轴P1速度,BatchAxis_P1Speed,18000,,,,,,,,,,,,
PRO,0,T1_提升轴P2速度,BatchAxis_P2Speed,12000,,,,, ,,,,,,,
PRO,0,T1_提升轴高度转换系数(1mm对应的脉冲),BatchAxis_ChangeValue,996,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,T2_旋转轴待机点/取放料点 P1,MiddleAxis_P1,5000,,,,,,,,,,,,
PRO,0,T2_旋转轴左侧料仓取放料点_P2,MiddleAxis_P2,59002,,,,,,,,,,,,
PRO,0,T2_旋转轴右侧料仓取放料点_P3,MiddleAxis_P3,59003,,,,,,,,,,,,
PRO,0,T2_旋转轴_料串取放料点_P4,MiddleAxis_P4,59004,,,,,,,,,,,,
PRO,0,T2_旋转轴P1速度,MiddleAxis_P1Speed,500,,,,,,,,,,,,
PRO,0,T2_旋转轴P2速度,MiddleAxis_P2Speed,500,,,,,,,,,,,,
PRO,0,T2_旋转轴P3速度,MiddleAxis_P3Speed,500,,,,,,,,,,,,
PRO,0,T2_旋转轴P4速度,MiddleAxis_P4Speed,500,,,,,,,,,,,,
PRO,0,T2_旋转轴待机点/取放料点 P1,MiddleAxis_P1,500,,,,,,,,,,,,
PRO,0,T2_旋转轴左侧料仓取放料点_P2,MiddleAxis_P2,4774,,,,,,,,,,,,
PRO,0,T2_旋转轴右侧料仓取放料点_P3,MiddleAxis_P3,-24,,,,,,,,,,,,
PRO,0,T2_旋转轴_料串取放料点_P4,MiddleAxis_P4,2354,,,,,,,,,,,,
PRO,0,T2_旋转轴P1速度,MiddleAxis_P1Speed,1500,,,,,,,,,,,,
PRO,0,T2_旋转轴P2速度,MiddleAxis_P2Speed,1500,,,,,,,,,,,,
PRO,0,T2_旋转轴P3速度,MiddleAxis_P3Speed,1500,,,,,,,,,,,,
PRO,0,T2_旋转轴P4速度,MiddleAxis_P4Speed,1500,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,T3_升降轴料串取放料低点 P1,UpdownAxis_P1,5000,,,,,,,,,,,,
PRO,0,T3_升降轴料串取放料高点/待机点 P2,UpdownAxis_P2,5001,,,,,,,,,,,,
PRO,0,T3_升降轴左侧料仓取放料低点 P3,UpdownAxis_P3,5002,,,,,,,,,,,,
PRO,0,T3_升降轴左侧料仓取放料高点 P4,UpdownAxis_P4,5003,,,,,,,,,,,,
PRO,0,T3_升降轴右侧料仓取放料低点 P5,UpdownAxis_P5,5004,,,,,,,,,,,,
PRO,0,T3_升降轴右侧料仓取放料高点 P6,UpdownAxis_P6,5005,,,,,,,,,,,,
PRO,0,T3_升降轴P1速度/慢速度,UpdownAxis_P1Speed,500,,,,,,,,,,,,
PRO,0,T3_升降轴P2速度/快速度,UpdownAxis_P2Speed,501,,,,,,,,,,,,
PRO,0,T3_升降轴P3速度/慢速度,UpdownAxis_P3Speed,502,,,,,,,,,,,,
PRO,0,T3_升降轴P4速度/快速度,UpdownAxis_P4Speed,503,,,,,,,,,,,,
PRO,0,T3_升降轴P5速度/慢速度,UpdownAxis_P5Speed,504,,,,,,,,,,,,
PRO,0,T3_升降轴P6速度/快速度,UpdownAxis_P6Speed,505,,,,,,,,,,,,
PRO,0,T3_升降轴高度转换系数(1mm对应的脉冲),UpdownAxis_ChangeValue,11000,,,,,,,,,,,,
PRO,0,T3_升降轴料串取放料低点 P1,UpdownAxis_P1,129763,,,,,,,,,,,,
PRO,0,T3_升降轴料串取放料高点/待机点 P2,UpdownAxis_P2,0,,,,,,,,,,,,
PRO,0,T3_升降轴左侧料仓取放料低点 P3,UpdownAxis_P3,74285,,,,,,,,,,,,
PRO,0,T3_升降轴左侧料仓取放料高点 P4,UpdownAxis_P4,22181,,,,,,,,,,,,
PRO,0,T3_升降轴右侧料仓取放料低点 P5,UpdownAxis_P5,71798,,,,,,,,,,,,
PRO,0,T3_升降轴右侧料仓取放料高点 P6,UpdownAxis_P6,22181,,,,,,,,,,,,
PRO,0,T3_升降轴P1速度/慢速度,UpdownAxis_P1Speed,50000,,,,,,,,,,,,
PRO,0,T3_升降轴P2速度/快速度,UpdownAxis_P2Speed,70000,,,,,,,,,,,,
PRO,0,T3_升降轴P3速度/慢速度,UpdownAxis_P3Speed,50000,,,,,,,,,,,,
PRO,0,T3_升降轴P4速度/快速度,UpdownAxis_P4Speed,70000,,,,,,,,,,,,
PRO,0,T3_升降轴P5速度/慢速度,UpdownAxis_P5Speed,50000,,,,,,,,,,,,
PRO,0,T3_升降轴P6速度/快速度,UpdownAxis_P6Speed,70000,,,,,,,,,,,,
PRO,0,T3_升降轴高度转换系数(1mm对应的脉冲),UpdownAxis_ChangeValue,10041,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,T4_进出轴待机点 P1,InOutAxis_P1,5000,,,,,,,,,,,,
PRO,0,T4_进出轴7寸取料点P2,InOutAxis_P2,5000,,,,,,,,,,,,
PRO,0,T4_进出轴13寸取料点P3,InOutAxis_P3,5000,,,,,,,,,,,,
PRO,0,T4_进出轴放料点P4,InOutAxis_P4,5000,,,,,,,,,,,,
PRO,0,T4_进出轴待机点 P1,InOutAxis_P1,500,,,,,,,,,,,,
PRO,0,T4_进出轴7寸取料点P2,InOutAxis_P2,500,,,,,,,,,,,,
PRO,0,T4_进出轴13寸取料点P3,InOutAxis_P3,500,,,,,,,,,,,,
PRO,0,T4_进出轴放料点P4,InOutAxis_P4,500,,,,,,,,,,,,
PRO,0,T4_进出轴待机点 P1Speed,InOutAxis_P1Speed,5000,,,,,,,,,,,,
PRO,0,T4_进出轴7寸取料点P2Speed,InOutAxis_P2Speed,5000,,,,,,,,,,,,
PRO,0,T4_进出轴13寸取料点P3Speed,InOutAxis_P3Speed,5000,,,,,,,,,,,,
PRO,0,T4_进出轴放料点P4Speed,InOutAxis_P4Speed,5000,,,,,,,,,,,,
PRO,0,T4_进出轴右侧缓冲点P6,InOutAxis_P6,500,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,AgvInName,AgvInName,D1,,,,,,,,,,,,
PRO,0,AgvOutName,AgvOutName,D2,,,,,,,,,,,,
......@@ -138,5 +154,8 @@ PRO,,两次吹气间隔(分钟),BlowAir_Interval,10,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,是否调试状态(1=调试,0=正常),IsDebug,1,,,,,,,,,,,,
PRO,,气压检测IO关闭需要持续的时间,AirCheckSeconds,3,,,,,,,,,,,,
PRO,,所有料仓的CID(用#号分隔),All_CIDs,packing-1#packing-2,,,,,,,,,,,,
PRO,,扫码的相机名称(多个用#分隔),CameraNameList,GigE:MV-CE200-10GC (00E96448339),,,,,,,,,,,,
PRO,,所有料仓的CID(用#号分隔),All_CIDs,duo-2,,,,,,,,,,,,
PRO,,扫码的相机名称(多个用#分隔),CameraNameList,GigE:MV-CE200-10GC (00E96448339)#,,,,,,,,,,,,
PRO,,最后一盘料需要补充的高度,LastTrayAddHeight,10,,,,,,,,,,,,
PRO,,入料Rfid_IP,In_Rfid_IP,192.168.202.21,,,,,,,,,,,,
PRO,,出料Rfid IP,Out_Rfid_IP,192.168.201.21,,,,,,,,,,,,
......@@ -24,7 +24,7 @@ namespace OnlineStore.DeviceLibrary.IO
{
if (dIODeviceNameList.Count > 0 && dIODeviceNameList.Contains("HC"))
{
HCBoardManager.InitConfig();
HCBoardManager.InitConfig("", "", "HCBOARD");
if (!HCBoardManager.CardInitOk())
{
HCBoardManager.OpenCard();
......

using Asa.RFID;
using OnlineStore.Common;
using OnlineStore.LoadCSVLibrary;
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace OnlineStore.DeviceLibrary
{
public class RFIDManager
{
private static int DefaultTrayNum = 0; //ConfigAppSettings.GetIntValue(Setting_Init.DefaultTrayNum);
public static ReadAll readAll = new ReadAll("TheRFID");
private static bool IsOpen = false;
private static ConcurrentDictionary<string, string> LastRfidMap = new ConcurrentDictionary<string, string>();
public static void Open()
{
if (IsOpen)
{
return;
}
try
{
int port = 0;
if (port <= 0)
{
port = 13000;
}
LogUtil.info("RFID Server Open,port=" + port);
readAll.Received += ReadAll_Received;
readAll.Start(port);
//GetTrayNum("123",0);
IsOpen = true;
}
catch (Exception ex)
{
LogUtil.error("Open 出错:" + ex.ToString());
}
}
private static void ReadAll_Received(string ip, string id)
{
LogUtil.info($"ip={ip},id={id}");
}
public static RFIDData GetShelfId(string deviceIp)
{
return ReadRFID(deviceIp, true);
}
public static RFIDData ReadRFID(string ip, bool isClear = false)
{
try
{
if (String.IsNullOrEmpty(ip).Equals(false))
{
string outValue = readAll.Read(ip);
if (isClear)
{
readAll.Clear(ip);
}
if (outValue.Equals("000"))
{
// LogUtil.error("ReadRFID[" + ip + "]=" + outValue);
}
RFIDData data = new RFIDData(outValue);
return data;
}
}
catch (Exception ex)
{
LogUtil.error("ReadRFID[" + ip + "] [" + isClear + "] 出错:" + ex.ToString());
}
return new RFIDData();
}
public static void Close()
{
try
{
if (IsOpen)
{
readAll.Stop();
IsOpen = false;
}
}
catch (Exception ex)
{
LogUtil.error("关闭RFID出错:" + ex.ToString());
}
}
}
public class RFIDData
{
public string StrData = "";
public char RFType
{
get
{
char[] charArray = StrData.ToCharArray();
if (charArray.Length > 0)
{
return charArray[0];
}
return '0';
}
}
public int Num
{
get
{
try
{
if (StrData.Length >= 2)
{
return Convert.ToInt32(StrData.Substring(1, StrData.Length - 1));
}
}
catch (Exception ex)
{
}
return 0;
}
}
public RFIDData(string data = "00")
{
if (String.IsNullOrEmpty(data))
{
data = "00";
}
this.StrData = data;
}
public string NumStr()
{
return StrData;
}
internal static bool IsRealRfid(string shelfRfid)
{
//判断料架号是否是真实的料架号
if (shelfRfid.StartsWith("A") || shelfRfid.StartsWith("B"))
{
int num = -1;
try
{
num = Convert.ToInt32(shelfRfid.Substring(1, shelfRfid.Length - 1));
}
catch (Exception ex)
{
}
if (num > 0)
{
return true;
}
}
return false;
}
}
}
......@@ -17,6 +17,10 @@ namespace OnlineStore.DeviceLibrary
/// 正常工作过程中判断位置是否到达时使用
/// </summary>
public int LastPosition = 0;
/// <summary>
/// 伺服反转误差值
/// </summary>
public int Reverse_Offset = 0;
public string AxisName;
public AxisBean(ConfigMoveAxis axisConfig, string deviceName)
......@@ -112,6 +116,16 @@ namespace OnlineStore.DeviceLibrary
/// </summary>
public void AbsMove(StoreMoveInfo MoveInfo, int targetPosition, int targetSpeed)
{
//if (Reverse_Offset != 0 && targetPosition < GetAclPosition())
//{
// LogUtil.info($"倒转点位补偿targetPosition={targetPosition}-Reverse_Offset={Reverse_Offset}={targetPosition - Reverse_Offset}");
// targetPosition = targetPosition - Reverse_Offset;
//
// }
if (MoveInfo == null)
{
AbsMove(targetPosition, targetSpeed);
......
......@@ -64,10 +64,11 @@ namespace OnlineStore.DeviceLibrary
}
InoutAxis = new AxisBean(config.InOut_Axis, Name);
MiddleAxis = new AxisBean(config.Middle_Axis, Name);
MiddleAxis.Reverse_Offset = config.MiddleAxis_Reverse_Offset;
UpdownAxis = new AxisBean(config.UpDown_Axis, Name);
ComAxis = new AxisBean(config.Comp_Axis, Name);
mainTimer.Enabled = false;
LoadCameraConfig(config.Id.ToString());
}
private void IoCheckTimer_Elapsed(object sender, System.Timers.ElapsedEventArgs e)
......@@ -261,6 +262,7 @@ namespace OnlineStore.DeviceLibrary
ComAxis.AbsMove(MoveInfo, Config.CompAxis_P1, Config.CompAxis_P1_Speed);
break;
case StoreMoveStep.BOX_H04_OtherAxisBack:
HuichuanLibrary.HCBoardManager.SetAxBacklash(MiddleAxis.Config.GetAxisValue(),Config.MiddleAxis_Reverse_Offset, MiddleAxis.Config.HomeLowSpeed,-1);
LogInfo(MoveInfo.MoveType + ": 完成");
MoveEndP();
break;
......@@ -346,12 +348,26 @@ namespace OnlineStore.DeviceLibrary
OutDoorCloseCountDown = 5;
}
}
private void AutoResetProcess()
{
try
{
bool noInStore = MoveInfo.MoveType.Equals(MoveType.None) && alarmType.Equals(AlarmType.None);
bool middleinpos;
if (noInStore)
{
if (Config.Id == 1)
{
middleinpos = StoreManager.Store.T2_MiddleAxis.IsInPosition(StoreManager.Store.Config.MiddleAxis_P2);
}
else
{
middleinpos = StoreManager.Store.T2_MiddleAxis.IsInPosition(StoreManager.Store.Config.MiddleAxis_P3);
}
if (middleinpos)
noInStore = StoreManager.Store.T3_UpdownAxis.GetAclPosition() < (StoreManager.Store.Config.UpdownAxis_P3 - StoreManager.Store.Config.UpdownAxis_P4) / 2;
}
//LogInfo($"OutDoor_Check:{IOValue(IO_Type.OutDoor_Check)},InDoor_Check:{IOValue(IO_Type.InDoor_Check)},waitInStoreParam is null:{waitInStoreParam==null},waitOutStoreList.Count:{waitOutStoreList.Count},noInStore:{noInStore}");
if (AutoInout.CurrInOutACount >= StoreManager.Config.Box_ResetACount && noInStore)
{
if (runStatus < StoreRunStatus.Runing || MoveInfo.MoveType == MoveType.InStore || MoveInfo.MoveType == MoveType.OutStore)
......@@ -402,6 +418,21 @@ namespace OnlineStore.DeviceLibrary
StartExecuctOut(param);
}
}
else if (false && IOValue(IO_Type.InDoor_Check).Equals(IO_VALUE.HIGH) && noInStore && IsDebug.Equals(false))
{
LogInfo("发现入口有无信息料");
InOutParam inOutParam = new InOutParam(MoveType.InStore);
inOutParam.InStoreNg = true;
inOutParam.TargetPosition = 1;
inOutParam.moveType = MoveType.InStore;
inOutParam.PlateH = 56;
StoreManager.LoadInoutParam(inOutParam, MoveType.InStore, true, this);
runStatus = StoreRunStatus.Busy;
storeStatus = StoreStatus.InStoreExecute;
MoveInfo.NewMove(MoveType.InStore, inOutParam);
MoveInfo.NextMoveStep(StoreMoveStep.SI_01_InoutToP1);
}
}
catch (Exception ex)
{
......
using OnlineStore.Common;
using System;
using System.Collections.Generic;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
namespace OnlineStore.DeviceLibrary
{
partial class BoxBean
{
Thread camerathread;
Asa.HIK.IPCamera camera;
public event EventHandler<Bitmap> camera_event;
void LoadCameraConfig(string id) {
string path = @".\StoreConfig\box_"+id+"_Camera.json";
if (!File.Exists(path))
{
LogUtil.error(Name + "找不到监控相机配置文件"+ path);
}
camera = new Asa.HIK.IPCamera(path);
bool rtn = camera.Load();
if (!rtn)
LogUtil.error(Name + "加载监控相机配置文件失败");
camerathread = new Thread(new ThreadStart(startCamera));
camerathread.Start();
//pictureBox1.Image = bmp;
}
void startCamera() {
var rtn = camera.Open(0);
if (!rtn)
LogUtil.error(Name + "打开监控相机失败");
while (camera.IsOpen[0])
{
rtn = camera.GrabOne(0, out Bitmap bmp);
if (rtn)
{
camera_event?.Invoke(this, bmp);
}
Thread.Sleep(1000/10);
}
camera.Close(0);
camera.Dispose();
}
}
}
......@@ -240,6 +240,9 @@ namespace OnlineStore.DeviceLibrary
LogUtil.info(logName + " 成功");
return true;
}
else {
LogUtil.info(logName + "服务器反馈 :" + JsonHelper.SerializeObject(resultOperation));
}
break;
}
}
......@@ -250,7 +253,7 @@ namespace OnlineStore.DeviceLibrary
}
return false;
}
public string LastVisualRfid = "";
private void ReviceOutStoreProcess(Operation resultOperation)
{
DateTime time = DateTime.Now;
......@@ -262,7 +265,15 @@ namespace OnlineStore.DeviceLibrary
string[] posIdArray = data[ParamDefine.posId].Split(splitChar);
string[] plateWArray = data[ParamDefine.plateW].Split(splitChar);
string[] plateHArray = data[ParamDefine.plateH].Split(splitChar);
if (string.IsNullOrEmpty(LastVisualRfid))
{
LastVisualRfid = data[ParamDefine.rfid];
}
else if (LastVisualRfid != data[ParamDefine.rfid])
{
LogUtil.error(Name + $" 上一个工单还未结束LastVisualRfid={LastVisualRfid}, CurrentVisualRfid={data[ParamDefine.rfid]}");
return;
}
bool urgentReel = FormUtil.GetBoolData(data, ParamDefine.urgentReel);
//bool cutReel = FormUtil.GetBoolData(data, ParamDefine.cutReel);
//bool smallReel = FormUtil.GetBoolData(data, ParamDefine.smallReel);
......@@ -331,9 +342,7 @@ namespace OnlineStore.DeviceLibrary
}
}
}
#endregion
#endregion
}
}
......@@ -102,20 +102,22 @@ namespace OnlineStore.DeviceLibrary
IOManager.Init();
CodeManager.LoadConfig();
CurrShelfNum = ConfigAppSettings.GetIntValue(Setting_Init.CurrShelfNum);
CurrShelfNum = ConfigAppSettings.GetValue(Setting_Init.CurrShelfNum);
CurrShelfType = ConfigAppSettings.GetIntValue(Setting_Init.CurrShelfType);
UpdateShelfNum(CurrShelfNum, CurrShelfType);
HasT4Axis = Convert.ToBoolean(ConfigAppSettings.GetValue(Setting_Init.HasT4Axis));
Task.Factory.StartNew(delegate
{
//RFIDManager.RfidReader.Open(rfidList.ToArray());
RFIDManager.Open();
IOManager.instance.ConnectionIOList(ioList);
AxisManager.Init();
//AgvClient.Init();
IOMove(IO_Type.Alarm_HddLed, IO_VALUE.LOW);
IOMove(IO_Type.AutoRun_HddLed, IO_VALUE.LOW);
IOMove(IO_Type.RunSign_HddLed, IO_VALUE.LOW);
IOMove(IO_Type.Device_Led, IO_VALUE.HIGH);
mainTimer.Enabled = true;
if (!electricClamp.OpenPort(Config.Clamp1Port))
{
......@@ -183,6 +185,7 @@ namespace OnlineStore.DeviceLibrary
return false;
}
LogUtil.info(Name + "开始启动 ,启动时间:" + StartTime.ToString());
IOMove(IO_Type.Device_Led, IO_VALUE.HIGH);
runStatus = StoreRunStatus.HomeMoving;
StartTime = DateTime.Now;
StartResetMove();
......@@ -277,6 +280,8 @@ namespace OnlineStore.DeviceLibrary
LogUtil.info(Name + "复位 " + MoveInfo.MoveStep + " :流水线转动3秒");
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(3000));
LineRun(MoveInfo);
IOMove(IO_Type.Line_Run, IO_VALUE.HIGH, false, 5000);
}
else if (MoveInfo.IsStep(StoreMoveStep.LR_02_LineRun))
{
......@@ -287,11 +292,14 @@ namespace OnlineStore.DeviceLibrary
T1_BatchAxis.HomeMove(MoveInfo);
T3_UpdownAxis.HomeMove(MoveInfo);
LineStop(MoveInfo);
// LineStop(MoveInfo);
}
else if (MoveInfo.IsStep(StoreMoveStep.LR_03_BatchAxisHome_wait))
{
MoveInfo.NextMoveStep(StoreMoveStep.LR_03_BatchAxisHome);
if (HasT4Axis)
T4_InOut_Axis.HomeMove(MoveInfo);
MoveInfo.WaitList.Add(WaitResultInfo.WaitTime(500));
}
else if (MoveInfo.IsStep(StoreMoveStep.LR_03_BatchAxisHome))
......@@ -401,7 +409,8 @@ namespace OnlineStore.DeviceLibrary
equip.StopRun();
}
runStatus = StoreRunStatus.Wait;
// RFIDManager.Close();
IOMove(IO_Type.Device_Led, IO_VALUE.LOW);
RFIDManager.Close();
TimeSpan span = DateTime.Now - StartTime;
LogUtil.info(Name + ",停止运行,总运行时间:" + span.ToString());
}
......@@ -480,17 +489,28 @@ namespace OnlineStore.DeviceLibrary
{
if (IsDoValue(IO_Type.Alarm_HddLed, IO_VALUE.LOW))
{
IOMove(IO_Type.Alarm_HddLed, IO_VALUE.HIGH);
CheckAndMove(IO_Type.Alarm_HddLed, IO_VALUE.HIGH);
}
else
{
IOMove(IO_Type.Alarm_HddLed, IO_VALUE.LOW);
CheckAndMove(IO_Type.Alarm_HddLed, IO_VALUE.LOW);
}
}
else if (IsDoValue(IO_Type.Alarm_HddLed, IO_VALUE.HIGH))
{
IOMove(IO_Type.Alarm_HddLed, IO_VALUE.LOW);
CheckAndMove(IO_Type.Alarm_HddLed, IO_VALUE.LOW);
}
if (isNeedAlarmLed && StoreManager.Store.UseBuzzer)
{
CheckAndMove(IO_Type.Alarm_Buzzer, IO_VALUE.HIGH);
}
else
{
CheckAndMove(IO_Type.Alarm_Buzzer, IO_VALUE.LOW);
}
if (IOValue(IO_Type.Line_OutCheck).Equals(IO_VALUE.HIGH))
{
//IOMove(IO_Type.LineOut_Led, IO_VALUE.HIGH);
......@@ -597,7 +617,18 @@ namespace OnlineStore.DeviceLibrary
//急停按钮
if (IOValue(IO_Type.SuddenStop_BTN).Equals(IO_VALUE.LOW))
{
return;
if (IOManager.IOValue(IO_Type.SuddenStop_BTN, 0).Equals(IO_VALUE.LOW))
{
if (isInSuddenDown.Equals(false))
{
isInSuddenDown = true;
LogUtil.error(Name + "收到急停信号,报警急停");
WarnMsg = Name + "收到急停信号,报警急停";
//报警时会关闭所有轴
Alarm(AlarmType.SuddenStop, "1", WarnMsg, MoveType.None);
}
}
}
else if (IOValue(IO_Type.Reset_BTN).Equals(IO_VALUE.HIGH))
{
......@@ -659,6 +690,10 @@ namespace OnlineStore.DeviceLibrary
if (runStatus.Equals(StoreRunStatus.Runing) || runStatus.Equals(StoreRunStatus.Busy))
{
if (IOValue(IO_Type.Line_InCheck).Equals(IO_VALUE.HIGH) && IOValue(IO_Type.Line_WaitCheck).Equals(IO_VALUE.LOW) && (!InShelfInProcess))
{
ShelfEnterProcess();
}
ShelfOutProcess();
IOMinoitor();
ShowTimeLog("ShelfOutProcess");
......@@ -748,27 +783,54 @@ namespace OnlineStore.DeviceLibrary
#endregion
void IOMinoitor() {
if (IOValue(IO_Type.Line_WaitCheck).Equals(IO_VALUE.LOW) && AgvClient.GetAction(Config.AgvInName) == ClientAction.None)
if (IOValue(IO_Type.Line_WaitCheck).Equals(IO_VALUE.LOW) && AgvClient.GetAction(Config.AgvInName) == Agv.ClientAction.None)
{
AgvClient.NeedEnter(Config.AgvInName);
AgvClient.NeedEnter(Config.AgvInName,"");
}
if (IOValue(IO_Type.Line_OutCheck).Equals(IO_VALUE.HIGH) && AgvClient.GetAction(Config.AgvOutName) == ClientAction.None)
if (IOValue(IO_Type.Line_OutCheck).Equals(IO_VALUE.HIGH) && AgvClient.GetAction(Config.AgvOutName) == Agv.ClientAction.None)
{
AgvClient.NeedLeave(Config.AgvOutName);
var rfiddevice = RFIDManager.GetShelfId(Config.Out_Rfid_IP);
var rfid = rfiddevice.NumStr();
AgvClient.NeedLeave(Config.AgvOutName, rfid);
}
}
public int GetShelfNum()
public bool ReleaseShelf()
{
int ShelfCheck1 = 0;// (int)IOValue(IO_Type.ShelfCheck1);
int ShelfCheck2 = 0;//(int)IOValue(IO_Type.ShelfCheck2);
int ShelfCheck3 = 0;//(int)IOValue(IO_Type.ShelfCheck3);
int ShelfCheck4 = 0;//(int)IOValue(IO_Type.ShelfCheck4);
string dStr = ShelfCheck4.ToString()+ShelfCheck3.ToString() + ShelfCheck2.ToString() + ShelfCheck1.ToString();
int num = Convert.ToInt32(dStr, 2);
return num;
if (IOValue(IO_Type.Line_OutCheck).Equals(IO_VALUE.HIGH))
{
IOMove(IO_Type.Line_Run, IO_VALUE.HIGH, false, 4000);
IOMove(IO_Type.Line_Stop4_Out, IO_VALUE.HIGH, false, 1000);
LogUtil.info(Name + "料串手动出库,放行区放行");
return true;
}
//if (IOValue(IO_Type.RaiseStation_FrontCheck).Equals(IO_VALUE.LOW))
if (IOValue(IO_Type.Line_OutCheck).Equals(IO_VALUE.LOW)
&& IOValue(IO_Type.Line_BufferCheck).Equals(IO_VALUE.LOW)
&& IOValue(IO_Type.Line_WorkCheck).Equals(IO_VALUE.HIGH)
&& IOValue(IO_Type.TopCylinder_Down).Equals(IO_VALUE.HIGH)
)
{
IOMove(IO_Type.Line_Run, IO_VALUE.HIGH, false, 3000);
IOMove(IO_Type.Line_Stop2_Work, IO_VALUE.HIGH, false, 2000);
LogUtil.info(Name + "料串手动出库, 工作区放行");
return true;
}
bool box1stay = BoxMap[1].runStatus == StoreRunStatus.Runing || BoxMap[1].runStatus == StoreRunStatus.Wait;
bool box2stay = BoxMap[2].runStatus == StoreRunStatus.Runing || BoxMap[2].runStatus == StoreRunStatus.Wait;
bool shelfstay = StoreManager.Store.MoveInfo.MoveStep.Equals(StoreMoveStep.LO_09_WaitOut);
if (box1stay && box2stay && shelfstay)
{
//OutstoreEndSendShelf = true;
LO_31_BatchAxisToP1();
LogUtil.info(Name + "料串手动出库,强制放行");
return true;
}
LogUtil.info(Name + "不符合料串放行条件");
return false;
}
public void LineRun(StoreMoveInfo move=null )
......
......@@ -22,12 +22,20 @@ namespace OnlineStore.DeviceLibrary
public void ClosePort() {
axis.ClosePort();
}
public void Clamp(StoreMoveInfo moveInfo = null)
public void Clamp(StoreMoveInfo moveInfo = null,int plateW=7)
{
GripperType = GripperTypeE.Gripper;
if (!IsBusy)
{
axis.Push(30, 7, 500);
//if (plateW > 7)
if (true)
{
axis.Push(99, 7, 500);
}
else
{
axis.Push(50, 7, 500);
}
if (moveInfo!=null)
moveInfo.WaitList.Add(WaitResultInfo.WaitTime(100));
}
......@@ -63,12 +71,14 @@ namespace OnlineStore.DeviceLibrary
}
public bool IsBusy {
get {
axis.GetPosition();
return !axis.IsReached;
}
}
public bool IsClamp {
get
{
return !axis.IsPushEmpty;
}
}
......
......@@ -157,6 +157,7 @@ namespace OnlineStore.DeviceLibrary
if (value == 1)
{
WarnMsg = Name + " 运动轴" + axisInfo.Config.Explain + "报警";
LogUtil.error(WarnMsg);
Alarm(AlarmType.AxisAlarm, GetAlarmCodeByAxis(axisInfo.Config).ToString(), WarnMsg, MoveType.None);
isInAlarm = true;
}
......@@ -168,6 +169,14 @@ namespace OnlineStore.DeviceLibrary
{
return IOValue(ioType).Equals(ioValue);
}
public void CheckAndMove(string IoType, IO_VALUE value)
{
if (!IOValue(IoType).Equals(value))
{
IOMove(IoType, value);
}
}
internal void MoveEndP()
{
MoveInfo.EndMove();
......
......@@ -201,43 +201,40 @@ namespace OnlineStore.DeviceLibrary
p.UpDown_P2 = box.Config.UpDownAxis_P2;
// p.UpDown_P7 = box.Config.UpDownAxis_DoorOBPosition_P7;
if (param.TargetPosition == 1)
{
p.ComPress_P2 = box.Config.GetComP2(param.PlateH);
p.ComPress_P3 = box.Config.CompAxis_P1;
}
else
p.ComPress_P2 = box.Config.GetComP2(param.PlateH);
p.ComPress_P3 = box.Config.CompAxis_P1;
ACBoxPosition position = CSVPositionReader<ACBoxPosition>.GetPositon(param.PosID);
if (position == null)
{
ACBoxPosition position = CSVPositionReader<ACBoxPosition>.GetPositon(param.PosID);
if (position == null)
{
if (movetype.Equals(MoveType.InStore) && param.TargetPosition.Equals(1))
{
return true;
}
LogUtil.error(box.Name + "GetPositon[" + param.PosID + "]=null,没有库位不能执行出入库");
return false;
}
if (param.PlateH <= 0)
{
param.PlateH = position.BagHigh;
}
if (param.PlateW <= 0)
if (movetype.Equals(MoveType.InStore) && param.TargetPosition.Equals(1))
{
param.PlateW = position.BagWidth;
param.MoveP = p;
return true;
}
//p.ComPress_P2 = box.Config.GetComP2(position.BagHigh);
//p.ComPress_P3 = box.Config.CompAxis_P3;
p.ComPress_P2 = position.ComAxis_P2;
p.ComPress_P3 = position.ComAxis_P3;
p.InOut_P3 = position.InoutAxis_P3;
p.Middle_P2 = position.MiddleAxis_P2;
p.UpDown_P3 = position.UpdownAxis_IH_P3;
p.UpDown_P4 = position.UpdownAxis_IL_P4;
p.UpDown_P5 = position.UpdownAxis_OH_P5;
p.UpDown_P6 = position.UpdownAxis_OL_P6;
LogUtil.error(box.Name + "GetPositon[" + param.PosID + "]=null,没有库位不能执行出入库");
return false;
}
if (param.PlateH <= 0)
{
param.PlateH = position.BagHigh;
}
if (param.PlateW <= 0)
{
param.PlateW = position.BagWidth;
}
//p.ComPress_P2 = box.Config.GetComP2(position.BagHigh);
//p.ComPress_P3 = box.Config.CompAxis_P3;
p.ComPress_P3 = position.ComAxis_P3;
p.InOut_P3 = position.InoutAxis_P3;
p.Middle_P2 = position.MiddleAxis_P2;
p.UpDown_P3 = position.UpdownAxis_IH_P3;
p.UpDown_P4 = position.UpdownAxis_IL_P4;
p.UpDown_P5 = position.UpdownAxis_OH_P5;
p.UpDown_P6 = position.UpdownAxis_OL_P6;
param.MoveP = p;
......@@ -307,7 +304,7 @@ namespace OnlineStore.DeviceLibrary
// 取消任务地址: /cancelPutInTask //参数: barcode
private static string Addr_cancelPutInTask = "/rest/api/qisda/device/cancelPutInTask";
private static string Addr_cancelPutInTask = "/service/store/cancelPutInTask";
public static string cancelPutInTask(string deviceName, string barcode)
{
string msg = "";
......@@ -343,7 +340,7 @@ namespace OnlineStore.DeviceLibrary
}
private static string spiltStr = "##";
private static string Addr_PosForPutin = "/service/store/emptyPosForPutin";
public static GetPosResult GetPosId(string deviceName, List<string> codeList, int height, int width, int shelfNum)
public static GetPosResult GetPosId(string deviceName, List<string> codeList, int height, int width, string shelfNum)
{
GetPosResult result = new GetPosResult();
try
......@@ -377,7 +374,7 @@ namespace OnlineStore.DeviceLibrary
paramMap.Add("cids", cids);
paramMap.Add("code", codeStr);
paramMap.Add(ParamDefine.rfid, shelfNum.ToString());
paramMap.Add(ParamDefine.rfid, shelfNum);
string server = GetAddr(Addr_PosForPutin, paramMap);
DateTime startTime = DateTime.Now;
......@@ -440,6 +437,85 @@ namespace OnlineStore.DeviceLibrary
}
return result;
}
private static readonly string Addr_putShelfFinished = "/rest/api/dcs/device/putShelfFinished";
public static string putShelfFinished(string deviceName,string shelfNum, string rfidLoc, string barcode)
{
string msg = "";
try
{
Dictionary<string, string> paramMap = new Dictionary<string, string>();
paramMap.Add("rfid", shelfNum);
paramMap.Add("rfidLoc", rfidLoc);
paramMap.Add("barcode", barcode);
string server = GetAddr(Addr_putShelfFinished, paramMap);
DateTime startTime = DateTime.Now;
string resultStr = HttpHelper.Post(server, "");
LogUtil.info(deviceName + "putShelfFinished" + FormUtil.GetSpanStr(DateTime.Now - startTime) + " 【" + server + "】【" + resultStr + "】");
var data = JsonHelper.DeserializeJsonToObject<CommData<string>>(resultStr);
if (data == null)
{
return msg = deviceName + " putShelfFinished【 " + barcode + "】 没有收到服务器反馈";
}
else if (data.code.Equals(0).Equals(false))
{
return msg = deviceName + " putShelfFinished【 " + barcode + "】 :" + data.msg;
}
return "";
}
catch (Exception ex)
{
LogUtil.error(deviceName + " " + ex.ToString());
}
return msg;
}
private static readonly string Addr_unfinishedTaskCount = "/rest/api/dcs/device/unfinishedTaskCount";
public static int unfinishedTaskCount(string deviceName, string shelfNum)
{
try
{
string cids = "";
foreach (int k in Store.BoxMap.Keys)
{
cids += Store.BoxMap[k].CID + ",";
}
cids = cids.TrimEnd(',');
Dictionary<string, string> paramMap = new Dictionary<string, string>();
paramMap.Add("rfid", shelfNum);
paramMap.Add("cids", cids);
string server = GetAddr(Addr_unfinishedTaskCount, paramMap);
DateTime startTime = DateTime.Now;
string resultStr = HttpHelper.Post(server, "");
LogUtil.info(deviceName + "unfinishedTaskCount" + FormUtil.GetSpanStr(DateTime.Now - startTime) + " 【" + server + "】【" + resultStr + "】");
var data = JsonHelper.DeserializeJsonToObject<CommData<int>>(resultStr);
if (data == null)
{
LogUtil.info(deviceName + "unfinishedTaskCount 没有收到服务器反馈");
return 99999;
}
else if (data.code.Equals(0).Equals(false))
{
LogUtil.info(deviceName + " unfinishedTaskCount【 " + shelfNum + cids + "】 :" + data.msg);
return 99999;
}
return data.data;
}
catch (Exception ex)
{
LogUtil.error(deviceName + " " + ex.ToString());
}
return 99999;
}
//public static void SendPosToStoreCheck(string deviceName, InOutParam param)
//{
// if (param == null || param.InStoreNg)
......@@ -509,7 +585,16 @@ namespace OnlineStore.DeviceLibrary
public string msg { get; set; }
public Dictionary<string, string> data { get; set; }
}
}
public class CommData<T>
{
//{"code":0,"msg":"ok","data":"7"}
public int code { get; set; }
public string msg { get; set; }
public T data { get; set; }
}
public class LineOperation
{
// //{"result":"0","msg":"","pos":"11#AC1_18_4_28","barcode":"R506072019102200414","cid":"line-ac-11"}
......
......@@ -19,7 +19,7 @@ namespace OnlineStore.DeviceLibrary
private int Jiange = 3;
private int positionIndex = 0;
public string autoMsg = "";
private int startIndex = -1;
private int startIndex = -1;
#region 出入库参数
/// <summary>
/// 当前出入库的次数,超过配置的数量时,需要自动重置一下,再进行出入库
......@@ -30,12 +30,12 @@ namespace OnlineStore.DeviceLibrary
public void StartAuto(int jiange, int currIndex )
public void StartAuto(int jiange, int currIndex)
{
autoNext = true;
Jiange = jiange;
positionIndex = currIndex;
startIndex = currIndex;
startIndex = currIndex;
}
public void StopAuto()
{
......@@ -55,7 +55,7 @@ namespace OnlineStore.DeviceLibrary
}
if (storeMoveType.Equals(MoveType.InStore))
{
int newIndex = positionIndex - Jiange;
int newIndex = positionIndex - 1;
if (newIndex < 0)
{
if (startIndex >= 0 && startIndex < boxBean.PositionNumList.Count)
......@@ -92,7 +92,7 @@ namespace OnlineStore.DeviceLibrary
}
else if (storeMoveType.Equals(MoveType.OutStore))
{
int newIndex = positionIndex;
int newIndex = positionIndex - Jiange;
if (newIndex < 0)
{
if (startIndex >= 0 && startIndex < boxBean.PositionNumList.Count)
......@@ -108,13 +108,13 @@ namespace OnlineStore.DeviceLibrary
return;
}
}
positionIndex = newIndex;
string posid = boxBean.PositionNumList[positionIndex];
//positionIndex = newIndex;
string posid = boxBean.PositionNumList[newIndex];
InOutParam param = new InOutParam(MoveType.InStore, "AutoIn", posid);
boxBean.LogInfo("自动进入下一个入库:posid=" + posid);
autoMsg = "自动入库:" + posid;
boxBean.StartInStoreMove(param);
boxBean.StartInStoreMove(param);
}
}
catch (Exception ex)
......
......@@ -24,7 +24,7 @@ namespace OnlineStore.DeviceLibrary
/// <param name="shefNum">料架编号</param>
/// <param name="IsNg">是否是入库NG料</param>
/// <param name="ngMsg">NG消息</param>
public InOutParam(MoveType type, string wareNo = "", string posId = "", int platew = 0, int plateh = 0, int targetP = 0, int shefNum=0, bool IsNg = false, string ngMsg = "")
public InOutParam(MoveType type, string wareNo = "", string posId = "", int platew = 0, int plateh = 0, int targetP = 0, string shefNum="0", bool IsNg = false, string ngMsg = "")
{
WareCode = wareNo;
PosID = posId;
......@@ -78,7 +78,7 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// 料架编号
/// </summary>
public int shelfNum = 0;
public string shelfNum = "0";
/// <summary>
/// 出入库目标位置,
......@@ -110,11 +110,11 @@ namespace OnlineStore.DeviceLibrary
string[] arr = posId.Split('#');
if (arr.Length >= 2)
{
return int.Parse(arr[0]);
return int.Parse(arr[1].Substring(2, 1));
}
else
{
return int.Parse(posId.Substring(2, 2));
return int.Parse(posId.Substring(2, 1));
}
}
catch (Exception ex)
......@@ -128,23 +128,23 @@ namespace OnlineStore.DeviceLibrary
{
if (InStoreNg)
{
return " 入库失败[BOX_" + TargetBox + "] [" + WareCode + "], [" + PlateW + "x" + PlateH + "] ";
return " 入库失败[BOX_" + TargetBox + "] [" + WareCode + "], [" + PlateW + "x" + PlateH + "] [" + TargetPosition + "] [isNG:" + InStoreNg + "]";
}
else
{
if (moveType.Equals(MoveType.InStore))
{
return " 入库 [" + PosID + "] [" + WareCode + "], [" + PlateW + "x" + PlateH + "] ";
return " 入库 [" + PosID + "] [" + WareCode + "], [" + PlateW + "x" + PlateH + "] [" + TargetPosition + "] [isNG:" + InStoreNg + "]";
}
else
{
if (TargetPosition.Equals(1))
{
return " 批量出库 [" + PosID + "] [" + WareCode + "], [" + PlateW + "x" + PlateH + "] ";
return " 批量出库 [" + PosID + "] [" + WareCode + "], [" + PlateW + "x" + PlateH + "] [" + TargetPosition + "] [isNG:" + InStoreNg + "]";
}
else
{
return " 单盘出库 [" + PosID + "] [" + WareCode + "], [" + PlateW + "x" + PlateH + "] ";
return " 单盘出库 [" + PosID + "] [" + WareCode + "], [" + PlateW + "x" + PlateH + "] [" + TargetPosition + "] [isNG:" + InStoreNg + "]";
}
}
}
......
......@@ -250,7 +250,7 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// 开始出库运动
/// </summary>
public abstract bool StartOutStoreMove(InOutParam param);
public abstract bool StartOutStoreMove(InOutParam param,bool shelfisready=false);
protected abstract void OutStoreProcess();
#endregion
......
......@@ -394,7 +394,7 @@ namespace OnlineStore.DeviceLibrary
/// 入料检测:扫码
/// </summary>
LI_09_ScanCode,
LI_11a_AxisToTray,
/// <summary>
/// 入料检测:有料盘:升降轴到料串高点P2,旋转轴到料串位置P4
/// </summary>
......@@ -433,7 +433,7 @@ namespace OnlineStore.DeviceLibrary
/// 料盘移栽:等待料仓门口无料盘信号
/// </summary>
LI_21_WaitToBox,
LI_22a_ToBoxDoor,
/// <summary>
/// 料盘移栽:获取库位号完成,升降轴到料门口高点,旋转轴到料仓门口
/// </summary>
......@@ -541,10 +541,11 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// 取放料:批量轴下降指定的高度
/// </summary>
LO_11_BatchAxisDown,
LO_11_BatchAxisDown,
/// <summary>
/// 取放料:旋转轴到料仓门口,升降轴到入料低点
/// </summary>
LO_12a_ToBoxDoor,
LO_12_ToBoxDoor,
/// <summary>
/// 取放料:升降轴下降到料门口低点
......@@ -557,6 +558,7 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// 取放料:升降轴上升到料门口高点
/// </summary>
LO_15a_UpdownUp,
LO_15_UpdownUp,
/// <summary>
/// 取放料:旋转轴到料仓位置P1
......
......@@ -210,6 +210,16 @@ namespace OnlineStore.LoadCSVLibrary
/// </summary>
[ConfigProAttribute("IsInDebug")]
public int IsInDebug { get; set; }
/// <summary>
/// PRO 是否使用料盘检测信号 IsUse_Tray_Check
/// </summary>
[ConfigProAttribute("IsUse_Tray_Check")]
public int IsUse_Tray_Check { get; set; }
/// <summary>
/// PRO 旋转轴伺服反转误差 MiddleAxis_Reverse_Offset
/// </summary>
[ConfigProAttribute("MiddleAxis_Reverse_Offset")]
public int MiddleAxis_Reverse_Offset { get; set; }
private Dictionary<int, int> ComP2Map = null;
public int GetComP2(int plateh)
......
......@@ -229,9 +229,9 @@ namespace OnlineStore.LoadCSVLibrary
/// </summary>
public static string TrayCheck_7 = "TrayCheck_7";
/// <summary>
///DI 0 11/13/15寸料盘宽度检测 X28
///DI 0 11/13寸料盘宽度检测 X28
/// </summary>
public static string TrayCheck_11to15 = "TrayCheck_11to15";
public static string TrayCheck_11to13 = "TrayCheck_11to13";
/// <summary>
///DI 0 提升工位前端料串检测 X29
/// </summary>
......@@ -256,6 +256,10 @@ namespace OnlineStore.LoadCSVLibrary
///DI 0 提升工位定位2下降端 X34
/// </summary>
public static string RaiseStation_DownLocation2 = "RaiseStation_DownLocation2";
/// <summary>
///DI 0 15寸料盘宽度检测 X39
/// </summary>
public static string TrayCheck_15 = "TrayCheck_15";
/*
/// <summary>
///DI 0 卡爪到位确认 X39
......
......@@ -282,6 +282,11 @@ namespace OnlineStore.LoadCSVLibrary
/// </summary>
[ConfigProAttribute("InOutAxis_P4")]
public int InOutAxis_P4 { get; set; }
/// <summary>
/// T4_进出轴13寸取料点进入前点P6
/// </summary>
[ConfigProAttribute("InOutAxis_P6")]
public int InOutAxis_P6 { get; set; }
[ConfigProAttribute("InOutAxis_P1Speed")]
public int InOutAxis_P1Speed { get; set; }
......@@ -298,6 +303,16 @@ namespace OnlineStore.LoadCSVLibrary
public string AgvOutName { get; set; }
[ConfigProAttribute("Clamp1Port")]
public string Clamp1Port { get; set; }
/// <summary>
/// PRO,最后一盘料需要补充的高度,LastTrayAddHeight,10,,,,,,,,,
/// </summary>
[ConfigProAttribute("LastTrayAddHeight")]
public int LastTrayAddHeight { get; set; }
[ConfigProAttribute("In_Rfid_IP")]
public string In_Rfid_IP { get; set; }
[ConfigProAttribute("Out_Rfid_IP")]
public string Out_Rfid_IP { get; set; }
private List<string> CameraList = null;
public List<string> GetCameraList()
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!