Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
ACSingleStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 41b47a48
由
LN
编写于
2020-06-10 13:49:29 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
原git更改内容提交
1 个父辈
b9088dc4
隐藏空白字符变更
内嵌
并排
正在显示
22 个修改的文件
包含
987 行增加
和
1076 行删除
dll/Asa.IOModule.AIOBOX.dll
dll/Asa.IOModule.AIOBOX.xml
source/ACSingleStore/FrmIDConfig.Designer.cs
source/ACSingleStore/FrmIDConfig.cs
source/ACSingleStore/FrmStoreBox.Designer.cs
source/ACSingleStore/FrmStoreBox.cs
source/ACSingleStore/记录.txt
source/Common/Setting_Init.cs
source/Common/util/HttpHelper.cs
source/Common/util/LogUtil.cs
source/DeviceLibrary/IO/AIOBOX/AIOBOXManager.cs
source/DeviceLibrary/StoreConfig/AC/StoreConfig.csv
source/DeviceLibrary/StoreConfig/AC/linePositions.csv
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean.cs
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean_Partial.cs
source/DeviceLibrary/acSingleStore/StoreManager.cs
source/DeviceLibrary/lineConnect/LineConnect.cs
source/DeviceLibrary/store/InOutParam.cs
source/DeviceLibrary/store/KTK_Store.cs
source/DeviceLibrary/store/StoreStep.cs
source/LoadCVSLibrary/position/ACStorePosition.cs
source/LoadCVSLibrary/position/CSVPositionReader.cs
dll/Asa.IOModule.AIOBOX.dll
查看文件 @
41b47a4
此文件类型无法预览
dll/Asa.IOModule.AIOBOX.xml
查看文件 @
41b47a4
...
@@ -9,12 +9,6 @@
...
@@ -9,12 +9,6 @@
AIOBOX操作类
AIOBOX操作类
</summary>
</summary>
</member>
</member>
<member
name=
"F:Asa.IOModule.AIOBOX._unrevdRemote"
>
<summary>
暂停次数
WriteDO 命令非常多时,暂停一次发送 ReadDI 或 ReadDO
</summary>
</member>
<member
name=
"F:Asa.IOModule.AIOBOX.SEND_SLEEP"
>
<member
name=
"F:Asa.IOModule.AIOBOX.SEND_SLEEP"
>
<summary>
<summary>
每条命令发送的间隔
每条命令发送的间隔
...
@@ -22,13 +16,12 @@
...
@@ -22,13 +16,12 @@
小于30时,会出现接收数据连包的情况
小于30时,会出现接收数据连包的情况
</summary>
</summary>
</member>
</member>
<member
name=
"F:Asa.IOModule.AIOBOX.
LISTEN_SLEEP
"
>
<member
name=
"F:Asa.IOModule.AIOBOX.
PORT
"
>
<summary>
<summary>
监听网络接收数据的间隔
ModBus端口
必须小于SEND_SLEEP
</summary>
</summary>
</member>
</member>
<member
name=
"T:Asa.IOModule.AIOBOX.DI_Changed"
>
<member
name=
"T:Asa.IOModule.AIOBOX.DI
O
_Changed"
>
<summary>
<summary>
自动读取DI委托
自动读取DI委托
</summary>
</summary>
...
@@ -40,19 +33,12 @@
...
@@ -40,19 +33,12 @@
自动读取DI事件触发
自动读取DI事件触发
</summary>
</summary>
</member>
</member>
<member
name=
"T:Asa.IOModule.AIOBOX.DO_Changed"
>
<summary>
自动读取DO委托
</summary>
<param
name=
"box"
>
AIOBOX
</param>
<param
name=
"sta"
>
所有DO状态
</param>
</member>
<member
name=
"E:Asa.IOModule.AIOBOX.DO_Changed_Event"
>
<member
name=
"E:Asa.IOModule.AIOBOX.DO_Changed_Event"
>
<summary>
<summary>
自动读取DO事件触发
自动读取DO事件触发
</summary>
</summary>
</member>
</member>
<member
name=
"T:Asa.IOModule.AIOBOX.AI_Changed"
>
<member
name=
"T:Asa.IOModule.AIOBOX.AI
O
_Changed"
>
<summary>
<summary>
自动读取AI委托
自动读取AI委托
</summary>
</summary>
...
@@ -64,13 +50,6 @@
...
@@ -64,13 +50,6 @@
自动读取AI事件触发
自动读取AI事件触发
</summary>
</summary>
</member>
</member>
<member
name=
"T:Asa.IOModule.AIOBOX.AO_Changed"
>
<summary>
自动读取AO委托
</summary>
<param
name=
"box"
>
AIOBOX
</param>
<param
name=
"val"
>
所有AO的值
</param>
</member>
<member
name=
"E:Asa.IOModule.AIOBOX.AO_Changed_Event"
>
<member
name=
"E:Asa.IOModule.AIOBOX.AO_Changed_Event"
>
<summary>
<summary>
自动读取AO事件触发
自动读取AO事件触发
...
@@ -86,11 +65,6 @@
...
@@ -86,11 +65,6 @@
IP地址
IP地址
</summary>
</summary>
</member>
</member>
<member
name=
"P:Asa.IOModule.AIOBOX.Port"
>
<summary>
ModBus端口
</summary>
</member>
<member
name=
"P:Asa.IOModule.AIOBOX.IsConn"
>
<member
name=
"P:Asa.IOModule.AIOBOX.IsConn"
>
<summary>
<summary>
是否连接
是否连接
...
@@ -101,35 +75,12 @@
...
@@ -101,35 +75,12 @@
错误信息
错误信息
</summary>
</summary>
</member>
</member>
<member
name=
"P:Asa.IOModule.AIOBOX.LogOutDir"
>
<member
name=
"M:Asa.IOModule.AIOBOX.LogPath(System.String,Asa.IOModule.LogType)"
>
<summary>
日志输出目录
</summary>
</member>
<member
name=
"P:Asa.IOModule.AIOBOX.LogOut"
>
<summary>
错误日志输出,默认true
</summary>
</member>
<member
name=
"P:Asa.IOModule.AIOBOX.InputCount"
>
<summary>
输入总数
</summary>
</member>
<member
name=
"P:Asa.IOModule.AIOBOX.OutputCount"
>
<summary>
输出总数
</summary>
</member>
<member
name=
"P:Asa.IOModule.AIOBOX.InputReadSleep"
>
<summary>
<summary>
自动读取DI间隔
日志路径,连接前设置路径会自动保存日志
</summary>
</member>
<member
name=
"P:Asa.IOModule.AIOBOX.OutputReadSleep"
>
<summary>
自动读取DO间隔
</summary>
</summary>
<param
name=
"path"
>
文件夹路径
</param>
<param
name=
"type"
>
输出类型
</param>
</member>
</member>
<member
name=
"M:Asa.IOModule.AIOBOX.SetInput(Asa.IOModule.Box_Type,System.Int32)"
>
<member
name=
"M:Asa.IOModule.AIOBOX.SetInput(Asa.IOModule.Box_Type,System.Int32)"
>
<summary>
<summary>
...
@@ -163,7 +114,6 @@
...
@@ -163,7 +114,6 @@
<summary>
<summary>
连接
连接
</summary>
</summary>
<returns></returns>
</member>
</member>
<member
name=
"M:Asa.IOModule.AIOBOX.Close"
>
<member
name=
"M:Asa.IOModule.AIOBOX.Close"
>
<summary>
<summary>
...
@@ -197,6 +147,12 @@
...
@@ -197,6 +147,12 @@
<param
name=
"sta"
></param>
<param
name=
"sta"
></param>
<returns></returns>
<returns></returns>
</member>
</member>
<member
name=
"M:Asa.IOModule.AIOBOX.ReverseStatus(Asa.IOModule.Box_Sta@)"
>
<summary>
相反状态(ON/OFF)
</summary>
<param
name=
"sta"
></param>
</member>
<member
name=
"M:Asa.IOModule.AIOBOX.ReadDI(System.Int32)"
>
<member
name=
"M:Asa.IOModule.AIOBOX.ReadDI(System.Int32)"
>
<summary>
<summary>
读取单个DI输入状态(ON/OFF)
读取单个DI输入状态(ON/OFF)
...
@@ -292,20 +248,17 @@
...
@@ -292,20 +248,17 @@
读取所有DO状态,功能码1
读取所有DO状态,功能码1
</summary>
</summary>
<param
name=
"buff"
></param>
<param
name=
"buff"
></param>
<returns></returns>
</member>
</member>
<member
name=
"M:Asa.IOModule.AIOBOX.ReadDI(System.Byte[])"
>
<member
name=
"M:Asa.IOModule.AIOBOX.ReadDI(System.Byte[])"
>
<summary>
<summary>
读取所有DI状态,功能码2
读取所有DI状态,功能码2
</summary>
</summary>
<returns></returns>
</member>
</member>
<member
name=
"M:Asa.IOModule.AIOBOX.ReadAI(System.Byte[])"
>
<member
name=
"M:Asa.IOModule.AIOBOX.ReadAI(System.Byte[])"
>
<summary>
<summary>
读取所有AI的值,功能码4
读取所有AI的值,功能码4
</summary>
</summary>
<param
name=
"buff"
></param>
<param
name=
"buff"
></param>
<returns></returns>
</member>
</member>
<member
name=
"M:Asa.IOModule.AIOBOX.Command"
>
<member
name=
"M:Asa.IOModule.AIOBOX.Command"
>
<summary>
<summary>
...
@@ -373,5 +326,62 @@
...
@@ -373,5 +326,62 @@
闭合,打开,高电平
闭合,打开,高电平
</summary>
</summary>
</member>
</member>
<member
name=
"T:Asa.IOModule.LogType"
>
<summary>
日志类型
</summary>
</member>
<member
name=
"F:Asa.IOModule.LogType.OnlyError"
>
<summary>
仅错误信息
</summary>
</member>
<member
name=
"F:Asa.IOModule.LogType.All"
>
<summary>
所有
</summary>
</member>
<member
name=
"T:Asa.IOModule.LogFile"
>
<summary>
日志操作类
</summary>
</member>
<member
name=
"M:Asa.IOModule.LogFile.#ctor(System.String,System.String)"
>
<summary>
日志
</summary>
<param
name=
"path"
>
文件夹路径
</param>
<param
name=
"ip"
></param>
</member>
<member
name=
"M:Asa.IOModule.LogFile.Close"
>
<summary>
关闭文件
</summary>
</member>
<member
name=
"M:Asa.IOModule.LogFile.OutError(System.String)"
>
<summary>
输出错误
</summary>
<param
name=
"s"
></param>
</member>
<member
name=
"M:Asa.IOModule.LogFile.OutInfo(System.String)"
>
<summary>
输出信息
</summary>
<param
name=
"s"
></param>
</member>
<member
name=
"M:Asa.IOModule.LogFile.OutData(System.String,System.Byte[])"
>
<summary>
输出数据
</summary>
<param
name=
"tr"
></param>
<param
name=
"buff"
></param>
</member>
<member
name=
"M:Asa.IOModule.LogFile.OutData(System.String)"
>
<summary>
输出数据
</summary>
<param
name=
"s"
></param>
</member>
</members>
</members>
</doc>
</doc>
source/ACSingleStore/FrmIDConfig.Designer.cs
查看文件 @
41b47a4
...
@@ -38,13 +38,26 @@
...
@@ -38,13 +38,26 @@
this
.
txthttpAddr
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
txthttpAddr
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
btnReset
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnReset
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
chbDebug
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
chbDebug
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
groupBox1
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
groupBox2
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
btnSavePosID
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
cmbPosition15
=
new
System
.
Windows
.
Forms
.
ComboBox
();
this
.
label6
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
cmbPosition13
=
new
System
.
Windows
.
Forms
.
ComboBox
();
this
.
label5
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
cmbPosition11
=
new
System
.
Windows
.
Forms
.
ComboBox
();
this
.
label4
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
cmbPosition7
=
new
System
.
Windows
.
Forms
.
ComboBox
();
this
.
label21
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
groupBox1
.
SuspendLayout
();
this
.
groupBox2
.
SuspendLayout
();
this
.
SuspendLayout
();
this
.
SuspendLayout
();
//
//
// label1
// label1
//
//
this
.
label1
.
AutoSize
=
true
;
this
.
label1
.
AutoSize
=
true
;
this
.
label1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label1
.
Location
=
new
System
.
Drawing
.
Point
(
37
,
165
);
this
.
label1
.
Location
=
new
System
.
Drawing
.
Point
(
25
,
134
);
this
.
label1
.
Name
=
"label1"
;
this
.
label1
.
Name
=
"label1"
;
this
.
label1
.
Size
=
new
System
.
Drawing
.
Size
(
121
,
20
);
this
.
label1
.
Size
=
new
System
.
Drawing
.
Size
(
121
,
20
);
this
.
label1
.
TabIndex
=
0
;
this
.
label1
.
TabIndex
=
0
;
...
@@ -54,12 +67,12 @@
...
@@ -54,12 +67,12 @@
//
//
this
.
btnNext
.
Anchor
=
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
;
this
.
btnNext
.
Anchor
=
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
;
this
.
btnNext
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnNext
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnNext
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
1
4.25
F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnNext
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
1
2
F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnNext
.
Location
=
new
System
.
Drawing
.
Point
(
283
,
277
);
this
.
btnNext
.
Location
=
new
System
.
Drawing
.
Point
(
317
,
179
);
this
.
btnNext
.
Name
=
"btnNext"
;
this
.
btnNext
.
Name
=
"btnNext"
;
this
.
btnNext
.
Size
=
new
System
.
Drawing
.
Size
(
120
,
45
);
this
.
btnNext
.
Size
=
new
System
.
Drawing
.
Size
(
120
,
45
);
this
.
btnNext
.
TabIndex
=
275
;
this
.
btnNext
.
TabIndex
=
275
;
this
.
btnNext
.
Text
=
"保存"
;
this
.
btnNext
.
Text
=
"保存
料仓配置
"
;
this
.
btnNext
.
UseVisualStyleBackColor
=
false
;
this
.
btnNext
.
UseVisualStyleBackColor
=
false
;
this
.
btnNext
.
Click
+=
new
System
.
EventHandler
(
this
.
btnNext_Click
);
this
.
btnNext
.
Click
+=
new
System
.
EventHandler
(
this
.
btnNext_Click
);
//
//
...
@@ -67,12 +80,12 @@
...
@@ -67,12 +80,12 @@
//
//
this
.
btnBack
.
Anchor
=
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
;
this
.
btnBack
.
Anchor
=
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
;
this
.
btnBack
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnBack
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnBack
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
1
4.25
F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnBack
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
1
2
F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnBack
.
Location
=
new
System
.
Drawing
.
Point
(
157
,
277
);
this
.
btnBack
.
Location
=
new
System
.
Drawing
.
Point
(
203
,
535
);
this
.
btnBack
.
Name
=
"btnBack"
;
this
.
btnBack
.
Name
=
"btnBack"
;
this
.
btnBack
.
Size
=
new
System
.
Drawing
.
Size
(
1
20
,
45
);
this
.
btnBack
.
Size
=
new
System
.
Drawing
.
Size
(
1
83
,
45
);
this
.
btnBack
.
TabIndex
=
274
;
this
.
btnBack
.
TabIndex
=
274
;
this
.
btnBack
.
Text
=
"取消"
;
this
.
btnBack
.
Text
=
"取消
/返回
"
;
this
.
btnBack
.
UseVisualStyleBackColor
=
false
;
this
.
btnBack
.
UseVisualStyleBackColor
=
false
;
this
.
btnBack
.
Click
+=
new
System
.
EventHandler
(
this
.
btnBack_Click
);
this
.
btnBack
.
Click
+=
new
System
.
EventHandler
(
this
.
btnBack_Click
);
//
//
...
@@ -81,16 +94,16 @@
...
@@ -81,16 +94,16 @@
this
.
cmbId
.
DropDownStyle
=
System
.
Windows
.
Forms
.
ComboBoxStyle
.
DropDownList
;
this
.
cmbId
.
DropDownStyle
=
System
.
Windows
.
Forms
.
ComboBoxStyle
.
DropDownList
;
this
.
cmbId
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
12F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
cmbId
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
12F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
cmbId
.
FormattingEnabled
=
true
;
this
.
cmbId
.
FormattingEnabled
=
true
;
this
.
cmbId
.
Location
=
new
System
.
Drawing
.
Point
(
1
71
,
161
);
this
.
cmbId
.
Location
=
new
System
.
Drawing
.
Point
(
1
52
,
130
);
this
.
cmbId
.
Name
=
"cmbId"
;
this
.
cmbId
.
Name
=
"cmbId"
;
this
.
cmbId
.
Size
=
new
System
.
Drawing
.
Size
(
2
6
5
,
29
);
this
.
cmbId
.
Size
=
new
System
.
Drawing
.
Size
(
2
8
5
,
29
);
this
.
cmbId
.
TabIndex
=
276
;
this
.
cmbId
.
TabIndex
=
276
;
//
//
// label2
// label2
//
//
this
.
label2
.
AutoSize
=
true
;
this
.
label2
.
AutoSize
=
true
;
this
.
label2
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label2
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label2
.
Location
=
new
System
.
Drawing
.
Point
(
38
,
5
7
);
this
.
label2
.
Location
=
new
System
.
Drawing
.
Point
(
25
,
3
7
);
this
.
label2
.
Name
=
"label2"
;
this
.
label2
.
Name
=
"label2"
;
this
.
label2
.
Size
=
new
System
.
Drawing
.
Size
(
121
,
20
);
this
.
label2
.
Size
=
new
System
.
Drawing
.
Size
(
121
,
20
);
this
.
label2
.
TabIndex
=
277
;
this
.
label2
.
TabIndex
=
277
;
...
@@ -100,7 +113,7 @@
...
@@ -100,7 +113,7 @@
//
//
this
.
label3
.
AutoSize
=
true
;
this
.
label3
.
AutoSize
=
true
;
this
.
label3
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label3
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label3
.
Location
=
new
System
.
Drawing
.
Point
(
65
,
111
);
this
.
label3
.
Location
=
new
System
.
Drawing
.
Point
(
53
,
86
);
this
.
label3
.
Name
=
"label3"
;
this
.
label3
.
Name
=
"label3"
;
this
.
label3
.
Size
=
new
System
.
Drawing
.
Size
(
93
,
20
);
this
.
label3
.
Size
=
new
System
.
Drawing
.
Size
(
93
,
20
);
this
.
label3
.
TabIndex
=
278
;
this
.
label3
.
TabIndex
=
278
;
...
@@ -109,18 +122,18 @@
...
@@ -109,18 +122,18 @@
// txtLineAddr
// txtLineAddr
//
//
this
.
txtLineAddr
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
txtLineAddr
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
txtLineAddr
.
Location
=
new
System
.
Drawing
.
Point
(
1
71
,
108
);
this
.
txtLineAddr
.
Location
=
new
System
.
Drawing
.
Point
(
1
52
,
83
);
this
.
txtLineAddr
.
Name
=
"txtLineAddr"
;
this
.
txtLineAddr
.
Name
=
"txtLineAddr"
;
this
.
txtLineAddr
.
Size
=
new
System
.
Drawing
.
Size
(
189
,
26
);
this
.
txtLineAddr
.
Size
=
new
System
.
Drawing
.
Size
(
285
,
26
);
this
.
txtLineAddr
.
TabIndex
=
279
;
this
.
txtLineAddr
.
TabIndex
=
279
;
this
.
txtLineAddr
.
Text
=
"192.168.101.11"
;
this
.
txtLineAddr
.
Text
=
"192.168.101.11"
;
//
//
// txthttpAddr
// txthttpAddr
//
//
this
.
txthttpAddr
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
txthttpAddr
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
txthttpAddr
.
Location
=
new
System
.
Drawing
.
Point
(
1
72
,
5
5
);
this
.
txthttpAddr
.
Location
=
new
System
.
Drawing
.
Point
(
1
53
,
3
5
);
this
.
txthttpAddr
.
Name
=
"txthttpAddr"
;
this
.
txthttpAddr
.
Name
=
"txthttpAddr"
;
this
.
txthttpAddr
.
Size
=
new
System
.
Drawing
.
Size
(
2
93
,
26
);
this
.
txthttpAddr
.
Size
=
new
System
.
Drawing
.
Size
(
2
85
,
26
);
this
.
txthttpAddr
.
TabIndex
=
280
;
this
.
txthttpAddr
.
TabIndex
=
280
;
this
.
txthttpAddr
.
Text
=
"http://192.168.101.11/myproject/"
;
this
.
txthttpAddr
.
Text
=
"http://192.168.101.11/myproject/"
;
//
//
...
@@ -129,7 +142,7 @@
...
@@ -129,7 +142,7 @@
this
.
btnReset
.
Anchor
=
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
;
this
.
btnReset
.
Anchor
=
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
;
this
.
btnReset
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnReset
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnReset
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnReset
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnReset
.
Location
=
new
System
.
Drawing
.
Point
(
376
,
105
);
this
.
btnReset
.
Location
=
new
System
.
Drawing
.
Point
(
463
,
80
);
this
.
btnReset
.
Name
=
"btnReset"
;
this
.
btnReset
.
Name
=
"btnReset"
;
this
.
btnReset
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
33
);
this
.
btnReset
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
33
);
this
.
btnReset
.
TabIndex
=
281
;
this
.
btnReset
.
TabIndex
=
281
;
...
@@ -142,35 +155,192 @@
...
@@ -142,35 +155,192 @@
this
.
chbDebug
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
chbDebug
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
chbDebug
.
AutoSize
=
true
;
this
.
chbDebug
.
AutoSize
=
true
;
this
.
chbDebug
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
12F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
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
(
1
71
,
224
);
this
.
chbDebug
.
Location
=
new
System
.
Drawing
.
Point
(
1
52
,
190
);
this
.
chbDebug
.
Name
=
"chbDebug"
;
this
.
chbDebug
.
Name
=
"chbDebug"
;
this
.
chbDebug
.
Size
=
new
System
.
Drawing
.
Size
(
93
,
25
);
this
.
chbDebug
.
Size
=
new
System
.
Drawing
.
Size
(
93
,
25
);
this
.
chbDebug
.
TabIndex
=
282
;
this
.
chbDebug
.
TabIndex
=
282
;
this
.
chbDebug
.
Text
=
"调试状态"
;
this
.
chbDebug
.
Text
=
"调试状态"
;
this
.
chbDebug
.
UseVisualStyleBackColor
=
true
;
this
.
chbDebug
.
UseVisualStyleBackColor
=
true
;
//
//
// groupBox1
//
this
.
groupBox1
.
Controls
.
Add
(
this
.
chbDebug
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label1
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
btnReset
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
btnNext
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
txthttpAddr
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
cmbId
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
txtLineAddr
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label2
);
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
.
TabIndex
=
283
;
this
.
groupBox1
.
TabStop
=
false
;
this
.
groupBox1
.
Text
=
"料仓配置"
;
//
// groupBox2
//
this
.
groupBox2
.
Controls
.
Add
(
this
.
btnSavePosID
);
this
.
groupBox2
.
Controls
.
Add
(
this
.
cmbPosition15
);
this
.
groupBox2
.
Controls
.
Add
(
this
.
label6
);
this
.
groupBox2
.
Controls
.
Add
(
this
.
cmbPosition13
);
this
.
groupBox2
.
Controls
.
Add
(
this
.
label5
);
this
.
groupBox2
.
Controls
.
Add
(
this
.
cmbPosition11
);
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
.
Name
=
"groupBox2"
;
this
.
groupBox2
.
Size
=
new
System
.
Drawing
.
Size
(
577
,
244
);
this
.
groupBox2
.
TabIndex
=
284
;
this
.
groupBox2
.
TabStop
=
false
;
this
.
groupBox2
.
Text
=
"料盘定位功能配置"
;
//
// btnSavePosID
//
this
.
btnSavePosID
.
Anchor
=
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
;
this
.
btnSavePosID
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnSavePosID
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
12F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnSavePosID
.
Location
=
new
System
.
Drawing
.
Point
(
419
,
126
);
this
.
btnSavePosID
.
Name
=
"btnSavePosID"
;
this
.
btnSavePosID
.
Size
=
new
System
.
Drawing
.
Size
(
120
,
45
);
this
.
btnSavePosID
.
TabIndex
=
277
;
this
.
btnSavePosID
.
Text
=
"保存库位配置"
;
this
.
btnSavePosID
.
UseVisualStyleBackColor
=
false
;
this
.
btnSavePosID
.
Click
+=
new
System
.
EventHandler
(
this
.
btnSavePosID_Click
);
//
// cmbPosition15
//
this
.
cmbPosition15
.
AutoCompleteMode
=
System
.
Windows
.
Forms
.
AutoCompleteMode
.
SuggestAppend
;
this
.
cmbPosition15
.
AutoCompleteSource
=
System
.
Windows
.
Forms
.
AutoCompleteSource
.
CustomSource
;
this
.
cmbPosition15
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
cmbPosition15
.
FormattingEnabled
=
true
;
this
.
cmbPosition15
.
ItemHeight
=
20
;
this
.
cmbPosition15
.
Location
=
new
System
.
Drawing
.
Point
(
191
,
190
);
this
.
cmbPosition15
.
MaxDropDownItems
=
10
;
this
.
cmbPosition15
.
Name
=
"cmbPosition15"
;
this
.
cmbPosition15
.
Size
=
new
System
.
Drawing
.
Size
(
183
,
28
);
this
.
cmbPosition15
.
TabIndex
=
182
;
this
.
cmbPosition15
.
MouseLeave
+=
new
System
.
EventHandler
(
this
.
cmbPosition7_MouseLeave
);
//
// label6
//
this
.
label6
.
AutoSize
=
true
;
this
.
label6
.
Cursor
=
System
.
Windows
.
Forms
.
Cursors
.
Default
;
this
.
label6
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label6
.
ForeColor
=
System
.
Drawing
.
SystemColors
.
ControlText
;
this
.
label6
.
Location
=
new
System
.
Drawing
.
Point
(
38
,
193
);
this
.
label6
.
Name
=
"label6"
;
this
.
label6
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
label6
.
Size
=
new
System
.
Drawing
.
Size
(
132
,
20
);
this
.
label6
.
TabIndex
=
181
;
this
.
label6
.
Text
=
"库位号-15寸盘定位:"
;
this
.
label6
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
//
// cmbPosition13
//
this
.
cmbPosition13
.
AutoCompleteMode
=
System
.
Windows
.
Forms
.
AutoCompleteMode
.
SuggestAppend
;
this
.
cmbPosition13
.
AutoCompleteSource
=
System
.
Windows
.
Forms
.
AutoCompleteSource
.
CustomSource
;
this
.
cmbPosition13
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
cmbPosition13
.
FormattingEnabled
=
true
;
this
.
cmbPosition13
.
ItemHeight
=
20
;
this
.
cmbPosition13
.
Location
=
new
System
.
Drawing
.
Point
(
191
,
136
);
this
.
cmbPosition13
.
MaxDropDownItems
=
10
;
this
.
cmbPosition13
.
Name
=
"cmbPosition13"
;
this
.
cmbPosition13
.
Size
=
new
System
.
Drawing
.
Size
(
183
,
28
);
this
.
cmbPosition13
.
TabIndex
=
180
;
this
.
cmbPosition13
.
MouseLeave
+=
new
System
.
EventHandler
(
this
.
cmbPosition7_MouseLeave
);
//
// label5
//
this
.
label5
.
AutoSize
=
true
;
this
.
label5
.
Cursor
=
System
.
Windows
.
Forms
.
Cursors
.
Default
;
this
.
label5
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label5
.
ForeColor
=
System
.
Drawing
.
SystemColors
.
ControlText
;
this
.
label5
.
Location
=
new
System
.
Drawing
.
Point
(
38
,
139
);
this
.
label5
.
Name
=
"label5"
;
this
.
label5
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
label5
.
Size
=
new
System
.
Drawing
.
Size
(
132
,
20
);
this
.
label5
.
TabIndex
=
179
;
this
.
label5
.
Text
=
"库位号-13寸盘定位:"
;
this
.
label5
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
//
// cmbPosition11
//
this
.
cmbPosition11
.
AutoCompleteMode
=
System
.
Windows
.
Forms
.
AutoCompleteMode
.
SuggestAppend
;
this
.
cmbPosition11
.
AutoCompleteSource
=
System
.
Windows
.
Forms
.
AutoCompleteSource
.
CustomSource
;
this
.
cmbPosition11
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
cmbPosition11
.
FormattingEnabled
=
true
;
this
.
cmbPosition11
.
ItemHeight
=
20
;
this
.
cmbPosition11
.
Location
=
new
System
.
Drawing
.
Point
(
191
,
82
);
this
.
cmbPosition11
.
MaxDropDownItems
=
10
;
this
.
cmbPosition11
.
Name
=
"cmbPosition11"
;
this
.
cmbPosition11
.
Size
=
new
System
.
Drawing
.
Size
(
183
,
28
);
this
.
cmbPosition11
.
TabIndex
=
178
;
this
.
cmbPosition11
.
MouseLeave
+=
new
System
.
EventHandler
(
this
.
cmbPosition7_MouseLeave
);
//
// label4
//
this
.
label4
.
AutoSize
=
true
;
this
.
label4
.
Cursor
=
System
.
Windows
.
Forms
.
Cursors
.
Default
;
this
.
label4
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label4
.
ForeColor
=
System
.
Drawing
.
SystemColors
.
ControlText
;
this
.
label4
.
Location
=
new
System
.
Drawing
.
Point
(
38
,
85
);
this
.
label4
.
Name
=
"label4"
;
this
.
label4
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
label4
.
Size
=
new
System
.
Drawing
.
Size
(
132
,
20
);
this
.
label4
.
TabIndex
=
177
;
this
.
label4
.
Text
=
"库位号-11寸盘定位:"
;
this
.
label4
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
//
// cmbPosition7
//
this
.
cmbPosition7
.
AutoCompleteMode
=
System
.
Windows
.
Forms
.
AutoCompleteMode
.
SuggestAppend
;
this
.
cmbPosition7
.
AutoCompleteSource
=
System
.
Windows
.
Forms
.
AutoCompleteSource
.
CustomSource
;
this
.
cmbPosition7
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
cmbPosition7
.
FormattingEnabled
=
true
;
this
.
cmbPosition7
.
ItemHeight
=
20
;
this
.
cmbPosition7
.
Location
=
new
System
.
Drawing
.
Point
(
191
,
31
);
this
.
cmbPosition7
.
MaxDropDownItems
=
10
;
this
.
cmbPosition7
.
Name
=
"cmbPosition7"
;
this
.
cmbPosition7
.
Size
=
new
System
.
Drawing
.
Size
(
183
,
28
);
this
.
cmbPosition7
.
TabIndex
=
176
;
this
.
cmbPosition7
.
MouseLeave
+=
new
System
.
EventHandler
(
this
.
cmbPosition7_MouseLeave
);
//
// label21
//
this
.
label21
.
AutoSize
=
true
;
this
.
label21
.
Cursor
=
System
.
Windows
.
Forms
.
Cursors
.
Default
;
this
.
label21
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label21
.
ForeColor
=
System
.
Drawing
.
SystemColors
.
ControlText
;
this
.
label21
.
Location
=
new
System
.
Drawing
.
Point
(
38
,
34
);
this
.
label21
.
Name
=
"label21"
;
this
.
label21
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
label21
.
Size
=
new
System
.
Drawing
.
Size
(
124
,
20
);
this
.
label21
.
TabIndex
=
175
;
this
.
label21
.
Text
=
"库位号-7寸盘定位:"
;
this
.
label21
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
//
// FrmIdConfig
// FrmIdConfig
//
//
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
7F
,
17F
);
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
7F
,
17F
);
this
.
AutoScaleMode
=
System
.
Windows
.
Forms
.
AutoScaleMode
.
Font
;
this
.
AutoScaleMode
=
System
.
Windows
.
Forms
.
AutoScaleMode
.
Font
;
this
.
ClientSize
=
new
System
.
Drawing
.
Size
(
561
,
389
);
this
.
ClientSize
=
new
System
.
Drawing
.
Size
(
601
,
599
);
this
.
Controls
.
Add
(
this
.
chbDebug
);
this
.
Controls
.
Add
(
this
.
btnReset
);
this
.
Controls
.
Add
(
this
.
txthttpAddr
);
this
.
Controls
.
Add
(
this
.
txtLineAddr
);
this
.
Controls
.
Add
(
this
.
label3
);
this
.
Controls
.
Add
(
this
.
label2
);
this
.
Controls
.
Add
(
this
.
cmbId
);
this
.
Controls
.
Add
(
this
.
btnNext
);
this
.
Controls
.
Add
(
this
.
btnBack
);
this
.
Controls
.
Add
(
this
.
btnBack
);
this
.
Controls
.
Add
(
this
.
label1
);
this
.
Controls
.
Add
(
this
.
groupBox2
);
this
.
Controls
.
Add
(
this
.
groupBox1
);
this
.
Name
=
"FrmIdConfig"
;
this
.
Name
=
"FrmIdConfig"
;
this
.
Text
=
"料仓配置"
;
this
.
Text
=
"料仓配置"
;
this
.
Load
+=
new
System
.
EventHandler
(
this
.
FrmPwd_Load
);
this
.
Load
+=
new
System
.
EventHandler
(
this
.
FrmPwd_Load
);
this
.
Shown
+=
new
System
.
EventHandler
(
this
.
FrmPwd_Shown
);
this
.
Shown
+=
new
System
.
EventHandler
(
this
.
FrmPwd_Shown
);
this
.
KeyDown
+=
new
System
.
Windows
.
Forms
.
KeyEventHandler
(
this
.
FrmPwd_KeyDown
);
this
.
KeyDown
+=
new
System
.
Windows
.
Forms
.
KeyEventHandler
(
this
.
FrmPwd_KeyDown
);
this
.
groupBox1
.
ResumeLayout
(
false
);
this
.
groupBox1
.
PerformLayout
();
this
.
groupBox2
.
ResumeLayout
(
false
);
this
.
groupBox2
.
PerformLayout
();
this
.
ResumeLayout
(
false
);
this
.
ResumeLayout
(
false
);
this
.
PerformLayout
();
}
}
...
@@ -186,5 +356,16 @@
...
@@ -186,5 +356,16 @@
private
System
.
Windows
.
Forms
.
TextBox
txthttpAddr
;
private
System
.
Windows
.
Forms
.
TextBox
txthttpAddr
;
private
System
.
Windows
.
Forms
.
Button
btnReset
;
private
System
.
Windows
.
Forms
.
Button
btnReset
;
private
System
.
Windows
.
Forms
.
CheckBox
chbDebug
;
private
System
.
Windows
.
Forms
.
CheckBox
chbDebug
;
private
System
.
Windows
.
Forms
.
GroupBox
groupBox1
;
private
System
.
Windows
.
Forms
.
GroupBox
groupBox2
;
private
System
.
Windows
.
Forms
.
ComboBox
cmbPosition7
;
public
System
.
Windows
.
Forms
.
Label
label21
;
private
System
.
Windows
.
Forms
.
ComboBox
cmbPosition15
;
public
System
.
Windows
.
Forms
.
Label
label6
;
private
System
.
Windows
.
Forms
.
ComboBox
cmbPosition13
;
public
System
.
Windows
.
Forms
.
Label
label5
;
private
System
.
Windows
.
Forms
.
ComboBox
cmbPosition11
;
public
System
.
Windows
.
Forms
.
Label
label4
;
private
System
.
Windows
.
Forms
.
Button
btnSavePosID
;
}
}
}
}
\ No newline at end of file
\ No newline at end of file
source/ACSingleStore/FrmIDConfig.cs
查看文件 @
41b47a4
...
@@ -41,6 +41,39 @@ namespace OnlineStore.ACSingleStore
...
@@ -41,6 +41,39 @@ namespace OnlineStore.ACSingleStore
cmbId
.
SelectedIndex
=
StoreId
-
1
;
cmbId
.
SelectedIndex
=
StoreId
-
1
;
}
}
chbDebug
.
Checked
=
StoreManager
.
Store
.
IsDebug
;
chbDebug
.
Checked
=
StoreManager
.
Store
.
IsDebug
;
LoadPos
();
}
private
List
<
string
>
allList
=
new
List
<
string
>();
private
void
LoadPos
()
{
allList
=
new
List
<
string
>(
StoreManager
.
Store
.
PositionNumList
);
allList
.
Insert
(
0
,
" ---暂无--- "
);
LoadLocationCom
(
7
,
cmbPosition7
,
allList
);
LoadLocationCom
(
11
,
cmbPosition11
,
allList
);
LoadLocationCom
(
13
,
cmbPosition13
,
allList
);
LoadLocationCom
(
15
,
cmbPosition15
,
allList
);
}
private
void
LoadLocationCom
(
int
width
,
ComboBox
com
,
List
<
string
>
allList
)
{
com
.
DataSource
=
new
List
<
string
>(
allList
);
string
posId
=
StoreManager
.
GetLocationPosId
(
width
);
int
index
=
allList
.
IndexOf
(
posId
);
if
(
index
>
0
)
{
com
.
SelectedIndex
=
index
;
}
else
{
com
.
SelectedIndex
=
0
;
}
foreach
(
string
str
in
allList
)
{
com
.
AutoCompleteCustomSource
.
Add
(
str
);
}
com
.
AutoCompleteSource
=
AutoCompleteSource
.
CustomSource
;
}
}
private
void
btnNext_Click
(
object
sender
,
EventArgs
e
)
private
void
btnNext_Click
(
object
sender
,
EventArgs
e
)
...
@@ -103,7 +136,58 @@ namespace OnlineStore.ACSingleStore
...
@@ -103,7 +136,58 @@ namespace OnlineStore.ACSingleStore
private
void
btnReset_Click
(
object
sender
,
EventArgs
e
)
private
void
btnReset_Click
(
object
sender
,
EventArgs
e
)
{
{
txthttpAddr
.
Text
=
"http://192.168.101.11/myproject/"
;
txthttpAddr
.
Text
=
"http://192.168.101.11/myproject/"
;
txtLineAddr
.
Text
=
"192.168.101.11"
;
txtLineAddr
.
Text
=
"192.168.101.10"
;
}
private
void
cmbPosition7_MouseLeave
(
object
sender
,
EventArgs
e
)
{
try
{
ComboBox
box
=
(
ComboBox
)
sender
;
string
value
=
box
.
Text
;
if
(
allList
.
Contains
(
value
.
Trim
())){
}
else
{
box
.
Text
=
allList
[
0
];
}
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"cmbPosition7_MouseLeave 出错:"
+
ex
.
ToString
());
}
}
private
void
btnSavePosID_Click
(
object
sender
,
EventArgs
e
)
{
try
{
SaveP
(
cmbPosition7
,
7
);
SaveP
(
cmbPosition11
,
11
);
SaveP
(
cmbPosition13
,
13
);
SaveP
(
cmbPosition15
,
15
);
MessageBox
.
Show
(
"保存定位库位成功"
);
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"btnSavePosID_Click 出错:"
+
ex
.
ToString
());
}
}
}
private
void
SaveP
(
ComboBox
box
,
int
width
)
{
string
value
=
box
.
Text
;
if
(!
allList
.
Contains
(
value
)
)
{
box
.
Text
=
allList
[
0
];
value
=
allList
[
0
];
}
if
(
value
.
Equals
(
allList
[
0
]))
{
value
=
""
;
}
ConfigAppSettings
.
SaveValue
(
Setting_Init
.
Location_PosID_
+
width
,
value
);
}
}
}
}
}
source/ACSingleStore/FrmStoreBox.Designer.cs
查看文件 @
41b47a4
...
@@ -145,12 +145,12 @@
...
@@ -145,12 +145,12 @@
this
.
notifyIcon1
=
new
System
.
Windows
.
Forms
.
NotifyIcon
(
this
.
components
);
this
.
notifyIcon1
=
new
System
.
Windows
.
Forms
.
NotifyIcon
(
this
.
components
);
this
.
tabControl1
=
new
System
.
Windows
.
Forms
.
TabControl
();
this
.
tabControl1
=
new
System
.
Windows
.
Forms
.
TabControl
();
this
.
tabPage3
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
tabPage3
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
btnCloseDoor
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnOpenDoor
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
groupBox2
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
groupBox2
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
button6
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
button6
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
button3
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
button3
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
button5
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
button5
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnCloseDoor
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnOpenDoor
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
tabPage1
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
tabPage1
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
tabPage2
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
tabPage2
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
groupBox7
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
groupBox7
=
new
System
.
Windows
.
Forms
.
GroupBox
();
...
@@ -221,9 +221,9 @@
...
@@ -221,9 +221,9 @@
//
//
this
.
lblWarnMsg
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblWarnMsg
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblWarnMsg
.
ForeColor
=
System
.
Drawing
.
Color
.
Red
;
this
.
lblWarnMsg
.
ForeColor
=
System
.
Drawing
.
Color
.
Red
;
this
.
lblWarnMsg
.
Location
=
new
System
.
Drawing
.
Point
(
12
,
61
);
this
.
lblWarnMsg
.
Location
=
new
System
.
Drawing
.
Point
(
12
,
54
);
this
.
lblWarnMsg
.
Name
=
"lblWarnMsg"
;
this
.
lblWarnMsg
.
Name
=
"lblWarnMsg"
;
this
.
lblWarnMsg
.
Size
=
new
System
.
Drawing
.
Size
(
471
,
54
);
this
.
lblWarnMsg
.
Size
=
new
System
.
Drawing
.
Size
(
1049
,
50
);
this
.
lblWarnMsg
.
TabIndex
=
224
;
this
.
lblWarnMsg
.
TabIndex
=
224
;
this
.
lblWarnMsg
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
this
.
lblWarnMsg
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
//
//
...
@@ -271,7 +271,7 @@
...
@@ -271,7 +271,7 @@
this
.
groupAxis
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
groupAxis
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
groupAxis
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
6
);
this
.
groupAxis
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
6
);
this
.
groupAxis
.
Name
=
"groupAxis"
;
this
.
groupAxis
.
Name
=
"groupAxis"
;
this
.
groupAxis
.
Size
=
new
System
.
Drawing
.
Size
(
54
3
,
328
);
this
.
groupAxis
.
Size
=
new
System
.
Drawing
.
Size
(
54
6
,
299
);
this
.
groupAxis
.
TabIndex
=
216
;
this
.
groupAxis
.
TabIndex
=
216
;
this
.
groupAxis
.
TabStop
=
false
;
this
.
groupAxis
.
TabStop
=
false
;
this
.
groupAxis
.
Text
=
"伺服运动"
;
this
.
groupAxis
.
Text
=
"伺服运动"
;
...
@@ -702,9 +702,9 @@
...
@@ -702,9 +702,9 @@
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
richTextBox1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
richTextBox1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
richTextBox1
.
Location
=
new
System
.
Drawing
.
Point
(
7
,
92
);
this
.
richTextBox1
.
Location
=
new
System
.
Drawing
.
Point
(
7
,
13
);
this
.
richTextBox1
.
Name
=
"richTextBox1"
;
this
.
richTextBox1
.
Name
=
"richTextBox1"
;
this
.
richTextBox1
.
Size
=
new
System
.
Drawing
.
Size
(
5
45
,
454
);
this
.
richTextBox1
.
Size
=
new
System
.
Drawing
.
Size
(
5
54
,
408
);
this
.
richTextBox1
.
TabIndex
=
256
;
this
.
richTextBox1
.
TabIndex
=
256
;
this
.
richTextBox1
.
Text
=
""
;
this
.
richTextBox1
.
Text
=
""
;
this
.
richTextBox1
.
VisibleChanged
+=
new
System
.
EventHandler
(
this
.
richTextBox1_VisibleChanged
);
this
.
richTextBox1
.
VisibleChanged
+=
new
System
.
EventHandler
(
this
.
richTextBox1_VisibleChanged
);
...
@@ -738,7 +738,7 @@
...
@@ -738,7 +738,7 @@
this
.
groupBox1
.
Controls
.
Add
(
this
.
label43
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label43
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label42
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label42
);
this
.
groupBox1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
groupBox1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
groupBox1
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
3
43
);
this
.
groupBox1
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
3
08
);
this
.
groupBox1
.
Name
=
"groupBox1"
;
this
.
groupBox1
.
Name
=
"groupBox1"
;
this
.
groupBox1
.
Size
=
new
System
.
Drawing
.
Size
(
543
,
182
);
this
.
groupBox1
.
Size
=
new
System
.
Drawing
.
Size
(
543
,
182
);
this
.
groupBox1
.
TabIndex
=
217
;
this
.
groupBox1
.
TabIndex
=
217
;
...
@@ -1006,9 +1006,9 @@
...
@@ -1006,9 +1006,9 @@
this
.
groupInout
.
Controls
.
Add
(
this
.
btnUpDownP3
);
this
.
groupInout
.
Controls
.
Add
(
this
.
btnUpDownP3
);
this
.
groupInout
.
Controls
.
Add
(
this
.
btnUpDownP4
);
this
.
groupInout
.
Controls
.
Add
(
this
.
btnUpDownP4
);
this
.
groupInout
.
Enabled
=
false
;
this
.
groupInout
.
Enabled
=
false
;
this
.
groupInout
.
Location
=
new
System
.
Drawing
.
Point
(
7
,
218
);
this
.
groupInout
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
205
);
this
.
groupInout
.
Name
=
"groupInout"
;
this
.
groupInout
.
Name
=
"groupInout"
;
this
.
groupInout
.
Size
=
new
System
.
Drawing
.
Size
(
496
,
5
19
);
this
.
groupInout
.
Size
=
new
System
.
Drawing
.
Size
(
496
,
5
32
);
this
.
groupInout
.
TabIndex
=
100
;
this
.
groupInout
.
TabIndex
=
100
;
this
.
groupInout
.
TabStop
=
false
;
this
.
groupInout
.
TabStop
=
false
;
this
.
groupInout
.
Text
=
"料仓操作"
;
this
.
groupInout
.
Text
=
"料仓操作"
;
...
@@ -1671,7 +1671,7 @@
...
@@ -1671,7 +1671,7 @@
this
.
btnClearLog
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Bottom
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)));
this
.
btnClearLog
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Bottom
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)));
this
.
btnClearLog
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnClearLog
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnClearLog
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnClearLog
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnClearLog
.
Location
=
new
System
.
Drawing
.
Point
(
310
,
563
);
this
.
btnClearLog
.
Location
=
new
System
.
Drawing
.
Point
(
310
,
438
);
this
.
btnClearLog
.
Name
=
"btnClearLog"
;
this
.
btnClearLog
.
Name
=
"btnClearLog"
;
this
.
btnClearLog
.
Size
=
new
System
.
Drawing
.
Size
(
105
,
38
);
this
.
btnClearLog
.
Size
=
new
System
.
Drawing
.
Size
(
105
,
38
);
this
.
btnClearLog
.
TabIndex
=
224
;
this
.
btnClearLog
.
TabIndex
=
224
;
...
@@ -1682,34 +1682,37 @@
...
@@ -1682,34 +1682,37 @@
// lblThisSta
// lblThisSta
//
//
this
.
lblThisSta
.
AutoSize
=
true
;
this
.
lblThisSta
.
AutoSize
=
true
;
this
.
lblThisSta
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Bold
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblThisSta
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblThisSta
.
ForeColor
=
System
.
Drawing
.
Color
.
Green
;
this
.
lblThisSta
.
ForeColor
=
System
.
Drawing
.
Color
.
Green
;
this
.
lblThisSta
.
Location
=
new
System
.
Drawing
.
Point
(
20
,
30
);
this
.
lblThisSta
.
Location
=
new
System
.
Drawing
.
Point
(
10
,
22
);
this
.
lblThisSta
.
Name
=
"lblThisSta"
;
this
.
lblThisSta
.
Name
=
"lblThisSta"
;
this
.
lblThisSta
.
Size
=
new
System
.
Drawing
.
Size
(
65
,
19
);
this
.
lblThisSta
.
Size
=
new
System
.
Drawing
.
Size
(
56
,
17
);
this
.
lblThisSta
.
TabIndex
=
216
;
this
.
lblThisSta
.
TabIndex
=
216
;
this
.
lblThisSta
.
Text
=
"等待启动"
;
this
.
lblThisSta
.
Text
=
"等待启动"
;
//
//
// groupBox3
// groupBox3
//
//
this
.
groupBox3
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)(((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
groupBox3
.
Controls
.
Add
(
this
.
lblMoveEquipInfo
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
lblMoveEquipInfo
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
lblWarnMsg
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
lblWarnMsg
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
lblThisSta
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
lblThisSta
);
this
.
groupBox3
.
Location
=
new
System
.
Drawing
.
Point
(
7
,
90
);
this
.
groupBox3
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
88
);
this
.
groupBox3
.
Name
=
"groupBox3"
;
this
.
groupBox3
.
Name
=
"groupBox3"
;
this
.
groupBox3
.
Size
=
new
System
.
Drawing
.
Size
(
496
,
124
);
this
.
groupBox3
.
Size
=
new
System
.
Drawing
.
Size
(
1079
,
111
);
this
.
groupBox3
.
TabIndex
=
268
;
this
.
groupBox3
.
TabIndex
=
268
;
this
.
groupBox3
.
TabStop
=
false
;
this
.
groupBox3
.
TabStop
=
false
;
this
.
groupBox3
.
Text
=
"设备状态"
;
this
.
groupBox3
.
Text
=
"设备状态"
;
//
//
// lblMoveEquipInfo
// lblMoveEquipInfo
//
//
this
.
lblMoveEquipInfo
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
lblMoveEquipInfo
.
AutoSize
=
true
;
this
.
lblMoveEquipInfo
.
AutoSize
=
true
;
this
.
lblMoveEquipInfo
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Bold
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblMoveEquipInfo
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblMoveEquipInfo
.
ForeColor
=
System
.
Drawing
.
Color
.
Blue
;
this
.
lblMoveEquipInfo
.
ForeColor
=
System
.
Drawing
.
Color
.
Blue
;
this
.
lblMoveEquipInfo
.
Location
=
new
System
.
Drawing
.
Point
(
154
,
30
);
this
.
lblMoveEquipInfo
.
Location
=
new
System
.
Drawing
.
Point
(
856
,
22
);
this
.
lblMoveEquipInfo
.
Name
=
"lblMoveEquipInfo"
;
this
.
lblMoveEquipInfo
.
Name
=
"lblMoveEquipInfo"
;
this
.
lblMoveEquipInfo
.
Size
=
new
System
.
Drawing
.
Size
(
65
,
19
);
this
.
lblMoveEquipInfo
.
Size
=
new
System
.
Drawing
.
Size
(
56
,
17
);
this
.
lblMoveEquipInfo
.
TabIndex
=
272
;
this
.
lblMoveEquipInfo
.
TabIndex
=
272
;
this
.
lblMoveEquipInfo
.
Text
=
"移栽状态"
;
this
.
lblMoveEquipInfo
.
Text
=
"移栽状态"
;
//
//
...
@@ -1718,7 +1721,7 @@
...
@@ -1718,7 +1721,7 @@
this
.
chbDebug
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
chbDebug
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
chbDebug
.
AutoSize
=
true
;
this
.
chbDebug
.
AutoSize
=
true
;
this
.
chbDebug
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
12F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
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
(
799
,
12
);
this
.
chbDebug
.
Location
=
new
System
.
Drawing
.
Point
(
811
,
12
);
this
.
chbDebug
.
Name
=
"chbDebug"
;
this
.
chbDebug
.
Name
=
"chbDebug"
;
this
.
chbDebug
.
Size
=
new
System
.
Drawing
.
Size
(
93
,
25
);
this
.
chbDebug
.
Size
=
new
System
.
Drawing
.
Size
(
93
,
25
);
this
.
chbDebug
.
TabIndex
=
271
;
this
.
chbDebug
.
TabIndex
=
271
;
...
@@ -1731,7 +1734,7 @@
...
@@ -1731,7 +1734,7 @@
this
.
chbAuto
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
chbAuto
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
chbAuto
.
AutoSize
=
true
;
this
.
chbAuto
.
AutoSize
=
true
;
this
.
chbAuto
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
12F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
chbAuto
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
12F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
chbAuto
.
Location
=
new
System
.
Drawing
.
Point
(
9
27
,
13
);
this
.
chbAuto
.
Location
=
new
System
.
Drawing
.
Point
(
9
39
,
13
);
this
.
chbAuto
.
Name
=
"chbAuto"
;
this
.
chbAuto
.
Name
=
"chbAuto"
;
this
.
chbAuto
.
Size
=
new
System
.
Drawing
.
Size
(
125
,
25
);
this
.
chbAuto
.
Size
=
new
System
.
Drawing
.
Size
(
125
,
25
);
this
.
chbAuto
.
TabIndex
=
270
;
this
.
chbAuto
.
TabIndex
=
270
;
...
@@ -1784,26 +1787,52 @@
...
@@ -1784,26 +1787,52 @@
this
.
tabControl1
.
Controls
.
Add
(
this
.
tabPage3
);
this
.
tabControl1
.
Controls
.
Add
(
this
.
tabPage3
);
this
.
tabControl1
.
Controls
.
Add
(
this
.
tabPage1
);
this
.
tabControl1
.
Controls
.
Add
(
this
.
tabPage1
);
this
.
tabControl1
.
Controls
.
Add
(
this
.
tabPage2
);
this
.
tabControl1
.
Controls
.
Add
(
this
.
tabPage2
);
this
.
tabControl1
.
Location
=
new
System
.
Drawing
.
Point
(
509
,
89
);
this
.
tabControl1
.
Location
=
new
System
.
Drawing
.
Point
(
509
,
207
);
this
.
tabControl1
.
Name
=
"tabControl1"
;
this
.
tabControl1
.
Name
=
"tabControl1"
;
this
.
tabControl1
.
SelectedIndex
=
0
;
this
.
tabControl1
.
SelectedIndex
=
0
;
this
.
tabControl1
.
Size
=
new
System
.
Drawing
.
Size
(
5
68
,
649
);
this
.
tabControl1
.
Size
=
new
System
.
Drawing
.
Size
(
5
77
,
531
);
this
.
tabControl1
.
TabIndex
=
272
;
this
.
tabControl1
.
TabIndex
=
272
;
//
//
// tabPage3
// tabPage3
//
//
this
.
tabPage3
.
Controls
.
Add
(
this
.
groupBox2
);
this
.
tabPage3
.
Controls
.
Add
(
this
.
btnClearLog
);
this
.
tabPage3
.
Controls
.
Add
(
this
.
btnClearLog
);
this
.
tabPage3
.
Controls
.
Add
(
this
.
btnCloseDoor
);
this
.
tabPage3
.
Controls
.
Add
(
this
.
btnCloseDoor
);
this
.
tabPage3
.
Controls
.
Add
(
this
.
btnOpenDoor
);
this
.
tabPage3
.
Controls
.
Add
(
this
.
btnOpenDoor
);
this
.
tabPage3
.
Controls
.
Add
(
this
.
richTextBox1
);
this
.
tabPage3
.
Controls
.
Add
(
this
.
richTextBox1
);
this
.
tabPage3
.
Controls
.
Add
(
this
.
groupBox2
);
this
.
tabPage3
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
29
);
this
.
tabPage3
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
29
);
this
.
tabPage3
.
Name
=
"tabPage3"
;
this
.
tabPage3
.
Name
=
"tabPage3"
;
this
.
tabPage3
.
Size
=
new
System
.
Drawing
.
Size
(
56
0
,
616
);
this
.
tabPage3
.
Size
=
new
System
.
Drawing
.
Size
(
56
9
,
498
);
this
.
tabPage3
.
TabIndex
=
2
;
this
.
tabPage3
.
TabIndex
=
2
;
this
.
tabPage3
.
Text
=
" 操作日志 "
;
this
.
tabPage3
.
Text
=
" 操作日志 "
;
this
.
tabPage3
.
UseVisualStyleBackColor
=
true
;
this
.
tabPage3
.
UseVisualStyleBackColor
=
true
;
//
//
// btnCloseDoor
//
this
.
btnCloseDoor
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Bottom
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)));
this
.
btnCloseDoor
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnCloseDoor
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnCloseDoor
.
Location
=
new
System
.
Drawing
.
Point
(
146
,
438
);
this
.
btnCloseDoor
.
Name
=
"btnCloseDoor"
;
this
.
btnCloseDoor
.
Size
=
new
System
.
Drawing
.
Size
(
105
,
38
);
this
.
btnCloseDoor
.
TabIndex
=
258
;
this
.
btnCloseDoor
.
Text
=
"关闭仓门"
;
this
.
btnCloseDoor
.
UseVisualStyleBackColor
=
true
;
this
.
btnCloseDoor
.
Click
+=
new
System
.
EventHandler
(
this
.
btnCloseDoor_Click
);
//
// btnOpenDoor
//
this
.
btnOpenDoor
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Bottom
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)));
this
.
btnOpenDoor
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnOpenDoor
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnOpenDoor
.
Location
=
new
System
.
Drawing
.
Point
(
29
,
438
);
this
.
btnOpenDoor
.
Name
=
"btnOpenDoor"
;
this
.
btnOpenDoor
.
Size
=
new
System
.
Drawing
.
Size
(
105
,
38
);
this
.
btnOpenDoor
.
TabIndex
=
257
;
this
.
btnOpenDoor
.
Text
=
"打开仓门"
;
this
.
btnOpenDoor
.
UseVisualStyleBackColor
=
true
;
this
.
btnOpenDoor
.
Click
+=
new
System
.
EventHandler
(
this
.
btnOpenDoor_Click
);
//
// groupBox2
// groupBox2
//
//
this
.
groupBox2
.
Controls
.
Add
(
this
.
button6
);
this
.
groupBox2
.
Controls
.
Add
(
this
.
button6
);
...
@@ -1815,6 +1844,7 @@
...
@@ -1815,6 +1844,7 @@
this
.
groupBox2
.
TabIndex
=
276
;
this
.
groupBox2
.
TabIndex
=
276
;
this
.
groupBox2
.
TabStop
=
false
;
this
.
groupBox2
.
TabStop
=
false
;
this
.
groupBox2
.
Text
=
"流水线通信测试"
;
this
.
groupBox2
.
Text
=
"流水线通信测试"
;
this
.
groupBox2
.
Visible
=
false
;
//
//
// button6
// button6
//
//
...
@@ -1849,32 +1879,6 @@
...
@@ -1849,32 +1879,6 @@
this
.
button5
.
UseVisualStyleBackColor
=
true
;
this
.
button5
.
UseVisualStyleBackColor
=
true
;
this
.
button5
.
Click
+=
new
System
.
EventHandler
(
this
.
button5_Click
);
this
.
button5
.
Click
+=
new
System
.
EventHandler
(
this
.
button5_Click
);
//
//
// btnCloseDoor
//
this
.
btnCloseDoor
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Bottom
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)));
this
.
btnCloseDoor
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnCloseDoor
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnCloseDoor
.
Location
=
new
System
.
Drawing
.
Point
(
146
,
563
);
this
.
btnCloseDoor
.
Name
=
"btnCloseDoor"
;
this
.
btnCloseDoor
.
Size
=
new
System
.
Drawing
.
Size
(
105
,
38
);
this
.
btnCloseDoor
.
TabIndex
=
258
;
this
.
btnCloseDoor
.
Text
=
"关闭仓门"
;
this
.
btnCloseDoor
.
UseVisualStyleBackColor
=
true
;
this
.
btnCloseDoor
.
Click
+=
new
System
.
EventHandler
(
this
.
btnCloseDoor_Click
);
//
// btnOpenDoor
//
this
.
btnOpenDoor
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((
System
.
Windows
.
Forms
.
AnchorStyles
.
Bottom
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)));
this
.
btnOpenDoor
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnOpenDoor
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnOpenDoor
.
Location
=
new
System
.
Drawing
.
Point
(
29
,
563
);
this
.
btnOpenDoor
.
Name
=
"btnOpenDoor"
;
this
.
btnOpenDoor
.
Size
=
new
System
.
Drawing
.
Size
(
105
,
38
);
this
.
btnOpenDoor
.
TabIndex
=
257
;
this
.
btnOpenDoor
.
Text
=
"打开仓门"
;
this
.
btnOpenDoor
.
UseVisualStyleBackColor
=
true
;
this
.
btnOpenDoor
.
Click
+=
new
System
.
EventHandler
(
this
.
btnOpenDoor_Click
);
//
// tabPage1
// tabPage1
//
//
this
.
tabPage1
.
Controls
.
Add
(
this
.
groupAxis
);
this
.
tabPage1
.
Controls
.
Add
(
this
.
groupAxis
);
...
@@ -1882,7 +1886,7 @@
...
@@ -1882,7 +1886,7 @@
this
.
tabPage1
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
29
);
this
.
tabPage1
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
29
);
this
.
tabPage1
.
Name
=
"tabPage1"
;
this
.
tabPage1
.
Name
=
"tabPage1"
;
this
.
tabPage1
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
3
);
this
.
tabPage1
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
3
);
this
.
tabPage1
.
Size
=
new
System
.
Drawing
.
Size
(
56
0
,
616
);
this
.
tabPage1
.
Size
=
new
System
.
Drawing
.
Size
(
56
9
,
498
);
this
.
tabPage1
.
TabIndex
=
0
;
this
.
tabPage1
.
TabIndex
=
0
;
this
.
tabPage1
.
Text
=
" 伺服调试 "
;
this
.
tabPage1
.
Text
=
" 伺服调试 "
;
this
.
tabPage1
.
UseVisualStyleBackColor
=
true
;
this
.
tabPage1
.
UseVisualStyleBackColor
=
true
;
...
@@ -1893,7 +1897,7 @@
...
@@ -1893,7 +1897,7 @@
this
.
tabPage2
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
29
);
this
.
tabPage2
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
29
);
this
.
tabPage2
.
Name
=
"tabPage2"
;
this
.
tabPage2
.
Name
=
"tabPage2"
;
this
.
tabPage2
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
3
);
this
.
tabPage2
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
3
);
this
.
tabPage2
.
Size
=
new
System
.
Drawing
.
Size
(
56
0
,
616
);
this
.
tabPage2
.
Size
=
new
System
.
Drawing
.
Size
(
56
9
,
498
);
this
.
tabPage2
.
TabIndex
=
1
;
this
.
tabPage2
.
TabIndex
=
1
;
this
.
tabPage2
.
Text
=
" 温湿度 "
;
this
.
tabPage2
.
Text
=
" 温湿度 "
;
this
.
tabPage2
.
UseVisualStyleBackColor
=
true
;
this
.
tabPage2
.
UseVisualStyleBackColor
=
true
;
...
@@ -2168,7 +2172,7 @@
...
@@ -2168,7 +2172,7 @@
this
.
tabControl2
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
4
);
this
.
tabControl2
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
4
);
this
.
tabControl2
.
Name
=
"tabControl2"
;
this
.
tabControl2
.
Name
=
"tabControl2"
;
this
.
tabControl2
.
SelectedIndex
=
0
;
this
.
tabControl2
.
SelectedIndex
=
0
;
this
.
tabControl2
.
Size
=
new
System
.
Drawing
.
Size
(
10
68
,
80
);
this
.
tabControl2
.
Size
=
new
System
.
Drawing
.
Size
(
10
80
,
80
);
this
.
tabControl2
.
TabIndex
=
271
;
this
.
tabControl2
.
TabIndex
=
271
;
//
//
// tabPage4
// tabPage4
...
@@ -2183,7 +2187,7 @@
...
@@ -2183,7 +2187,7 @@
this
.
tabPage4
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
30
);
this
.
tabPage4
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
30
);
this
.
tabPage4
.
Name
=
"tabPage4"
;
this
.
tabPage4
.
Name
=
"tabPage4"
;
this
.
tabPage4
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
3
);
this
.
tabPage4
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
3
);
this
.
tabPage4
.
Size
=
new
System
.
Drawing
.
Size
(
10
60
,
46
);
this
.
tabPage4
.
Size
=
new
System
.
Drawing
.
Size
(
10
72
,
46
);
this
.
tabPage4
.
TabIndex
=
0
;
this
.
tabPage4
.
TabIndex
=
0
;
this
.
tabPage4
.
Text
=
" 料仓操作 "
;
this
.
tabPage4
.
Text
=
" 料仓操作 "
;
this
.
tabPage4
.
UseVisualStyleBackColor
=
true
;
this
.
tabPage4
.
UseVisualStyleBackColor
=
true
;
...
@@ -2254,7 +2258,7 @@
...
@@ -2254,7 +2258,7 @@
this
.
tabPage5
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
30
);
this
.
tabPage5
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
30
);
this
.
tabPage5
.
Name
=
"tabPage5"
;
this
.
tabPage5
.
Name
=
"tabPage5"
;
this
.
tabPage5
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
3
);
this
.
tabPage5
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
3
);
this
.
tabPage5
.
Size
=
new
System
.
Drawing
.
Size
(
10
60
,
46
);
this
.
tabPage5
.
Size
=
new
System
.
Drawing
.
Size
(
10
72
,
46
);
this
.
tabPage5
.
TabIndex
=
1
;
this
.
tabPage5
.
TabIndex
=
1
;
this
.
tabPage5
.
Text
=
" 设备调试 "
;
this
.
tabPage5
.
Text
=
" 设备调试 "
;
this
.
tabPage5
.
UseVisualStyleBackColor
=
true
;
this
.
tabPage5
.
UseVisualStyleBackColor
=
true
;
...
@@ -2333,7 +2337,7 @@
...
@@ -2333,7 +2337,7 @@
this
.
tabPage6
.
Controls
.
Add
(
this
.
btnLogDebug
);
this
.
tabPage6
.
Controls
.
Add
(
this
.
btnLogDebug
);
this
.
tabPage6
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
30
);
this
.
tabPage6
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
30
);
this
.
tabPage6
.
Name
=
"tabPage6"
;
this
.
tabPage6
.
Name
=
"tabPage6"
;
this
.
tabPage6
.
Size
=
new
System
.
Drawing
.
Size
(
10
60
,
46
);
this
.
tabPage6
.
Size
=
new
System
.
Drawing
.
Size
(
10
72
,
46
);
this
.
tabPage6
.
TabIndex
=
2
;
this
.
tabPage6
.
TabIndex
=
2
;
this
.
tabPage6
.
Text
=
" 其他 "
;
this
.
tabPage6
.
Text
=
" 其他 "
;
this
.
tabPage6
.
UseVisualStyleBackColor
=
true
;
this
.
tabPage6
.
UseVisualStyleBackColor
=
true
;
...
...
source/ACSingleStore/FrmStoreBox.cs
查看文件 @
41b47a4
...
@@ -101,8 +101,8 @@ namespace OnlineStore.ACSingleStore
...
@@ -101,8 +101,8 @@ namespace OnlineStore.ACSingleStore
txtMiddleP2
.
Text
=
ktkPosition
.
MiddleAxis_Position_P2
.
ToString
();
txtMiddleP2
.
Text
=
ktkPosition
.
MiddleAxis_Position_P2
.
ToString
();
txtUpDownP3
.
Text
=
ktkPosition
.
UpDownAxis_IHPosition_P3
.
ToString
();
txtUpDownP3
.
Text
=
ktkPosition
.
UpDownAxis_IHPosition_P3
.
ToString
();
txtUpDownP4
.
Text
=
ktkPosition
.
UpDownAxis_ILPosition_P4
.
ToString
();
txtUpDownP4
.
Text
=
ktkPosition
.
UpDownAxis_ILPosition_P4
.
ToString
();
txtUpDownP5
.
Text
=
ktkPosition
.
UpDownAxis_O
H
Position_P5
.
ToString
();
txtUpDownP5
.
Text
=
ktkPosition
.
UpDownAxis_O
L
Position_P5
.
ToString
();
txtUpDownP6
.
Text
=
ktkPosition
.
UpDownAxis_O
L
Position_P6
.
ToString
();
txtUpDownP6
.
Text
=
ktkPosition
.
UpDownAxis_O
H
Position_P6
.
ToString
();
txtComP2
.
Text
=
ktkPosition
.
CompressAxis_Position_P2
.
ToString
();
txtComP2
.
Text
=
ktkPosition
.
CompressAxis_Position_P2
.
ToString
();
txtComP3
.
Text
=
ktkPosition
.
CompressAxis_CPosition_P3
.
ToString
();
txtComP3
.
Text
=
ktkPosition
.
CompressAxis_CPosition_P3
.
ToString
();
txtInOutP3
.
Text
=
ktkPosition
.
InOutAxis_Position_P3
.
ToString
();
txtInOutP3
.
Text
=
ktkPosition
.
InOutAxis_Position_P3
.
ToString
();
...
@@ -180,7 +180,7 @@ namespace OnlineStore.ACSingleStore
...
@@ -180,7 +180,7 @@ namespace OnlineStore.ACSingleStore
LoadOk
=
true
;
LoadOk
=
true
;
}
}
lblTemp
.
Text
=
store
.
currTempStr
;
lblTemp
.
Text
=
store
.
currTempStr
;
lblMoveEquipInfo
.
Text
=
"移栽状态:"
+(
LineConnect
.
CanStartOut
()
?
"可出库"
:
"不可出库"
)+
" "
+
LineConnect
.
LastUpdateTime
.
ToLongTimeString
()
;
lblMoveEquipInfo
.
Text
=
"移栽状态:"
+(
LineConnect
.
CanStartOut
()
?
"可出库"
:
"不可出库"
)+
" "
+
LineConnect
.
LastUpdateTime
.
ToLongTimeString
()
+
""
;
//忙碌状态不读取状态
//忙碌状态不读取状态
if
(!
store
.
storeRunStatus
.
Equals
(
StoreRunStatus
.
Busy
))
if
(!
store
.
storeRunStatus
.
Equals
(
StoreRunStatus
.
Busy
))
{
{
...
@@ -438,8 +438,8 @@ namespace OnlineStore.ACSingleStore
...
@@ -438,8 +438,8 @@ namespace OnlineStore.ACSingleStore
txtMiddleP2
.
Text
=
ktkPosition
.
MiddleAxis_Position_P2
.
ToString
();
txtMiddleP2
.
Text
=
ktkPosition
.
MiddleAxis_Position_P2
.
ToString
();
txtUpDownP3
.
Text
=
ktkPosition
.
UpDownAxis_IHPosition_P3
.
ToString
();
txtUpDownP3
.
Text
=
ktkPosition
.
UpDownAxis_IHPosition_P3
.
ToString
();
txtUpDownP4
.
Text
=
ktkPosition
.
UpDownAxis_ILPosition_P4
.
ToString
();
txtUpDownP4
.
Text
=
ktkPosition
.
UpDownAxis_ILPosition_P4
.
ToString
();
txtUpDownP5
.
Text
=
ktkPosition
.
UpDownAxis_O
H
Position_P5
.
ToString
();
txtUpDownP5
.
Text
=
ktkPosition
.
UpDownAxis_O
L
Position_P5
.
ToString
();
txtUpDownP6
.
Text
=
ktkPosition
.
UpDownAxis_O
L
Position_P6
.
ToString
();
txtUpDownP6
.
Text
=
ktkPosition
.
UpDownAxis_O
H
Position_P6
.
ToString
();
txtComP2
.
Text
=
ktkPosition
.
CompressAxis_Position_P2
.
ToString
();
txtComP2
.
Text
=
ktkPosition
.
CompressAxis_Position_P2
.
ToString
();
txtComP3
.
Text
=
ktkPosition
.
CompressAxis_CPosition_P3
.
ToString
();
txtComP3
.
Text
=
ktkPosition
.
CompressAxis_CPosition_P3
.
ToString
();
txtInOutP3
.
Text
=
ktkPosition
.
InOutAxis_Position_P3
.
ToString
();
txtInOutP3
.
Text
=
ktkPosition
.
InOutAxis_Position_P3
.
ToString
();
...
@@ -610,8 +610,8 @@ namespace OnlineStore.ACSingleStore
...
@@ -610,8 +610,8 @@ namespace OnlineStore.ACSingleStore
ktkPosition
.
UpDownAxis_ILPosition_P4
=
FormUtil
.
GetIntValue
(
txtUpDownP4
);
ktkPosition
.
UpDownAxis_ILPosition_P4
=
FormUtil
.
GetIntValue
(
txtUpDownP4
);
ktkPosition
.
InOutAxis_Position_P3
=
FormUtil
.
GetIntValue
(
txtInOutP3
);
ktkPosition
.
InOutAxis_Position_P3
=
FormUtil
.
GetIntValue
(
txtInOutP3
);
ktkPosition
.
CompressAxis_CPosition_P3
=
FormUtil
.
GetIntValue
(
txtComP3
);
ktkPosition
.
CompressAxis_CPosition_P3
=
FormUtil
.
GetIntValue
(
txtComP3
);
ktkPosition
.
UpDownAxis_O
H
Position_P5
=
FormUtil
.
GetIntValue
(
txtUpDownP5
);
ktkPosition
.
UpDownAxis_O
L
Position_P5
=
FormUtil
.
GetIntValue
(
txtUpDownP5
);
ktkPosition
.
UpDownAxis_O
L
Position_P6
=
FormUtil
.
GetIntValue
(
txtUpDownP6
);
ktkPosition
.
UpDownAxis_O
H
Position_P6
=
FormUtil
.
GetIntValue
(
txtUpDownP6
);
ktkPosition
.
CompressAxis_Position_P2
=
FormUtil
.
GetIntValue
(
txtComP2
);
ktkPosition
.
CompressAxis_Position_P2
=
FormUtil
.
GetIntValue
(
txtComP2
);
ktkPosition
.
InOutAxis_DoorPosition_P2
=
FormUtil
.
GetIntValue
(
txtInOutP2
);
ktkPosition
.
InOutAxis_DoorPosition_P2
=
FormUtil
.
GetIntValue
(
txtInOutP2
);
//ktkPosition.UpDownAxis_DoorIPosition_P2 = FormUtil.GetIntValue(txtUpDownP2);
//ktkPosition.UpDownAxis_DoorIPosition_P2 = FormUtil.GetIntValue(txtUpDownP2);
...
...
source/ACSingleStore/记录.txt
查看文件 @
41b47a4
...
@@ -27,3 +27,8 @@
...
@@ -27,3 +27,8 @@
第9和第10位表示隔板位置(04)
第9和第10位表示隔板位置(04)
例如: 4D12010124 表示4楼12号料仓第1列第1行架子上的第24个隔板位置
例如: 4D12010124 表示4楼12号料仓第1列第1行架子上的第24个隔板位置
4D19050208 表示4楼19号料仓(包装料仓)第5列第2行架子上的第8个隔板位置
4D19050208 表示4楼19号料仓(包装料仓)第5列第2行架子上的第8个隔板位置
20200408
入库时仓门口必须有料。
source/Common/Setting_Init.cs
查看文件 @
41b47a4
...
@@ -101,5 +101,8 @@ namespace OnlineStore.Common
...
@@ -101,5 +101,8 @@ namespace OnlineStore.Common
public
static
string
Tool_TargetPosition
=
"Tool_TargetPosition"
;
public
static
string
Tool_TargetPosition
=
"Tool_TargetPosition"
;
public
static
string
Location_PosID_
=
"Location_PosID_"
;
}
}
}
}
source/Common/util/HttpHelper.cs
查看文件 @
41b47a4
...
@@ -12,17 +12,39 @@ using System.Security.Cryptography;
...
@@ -12,17 +12,39 @@ using System.Security.Cryptography;
using
System.Security.Cryptography.X509Certificates
;
using
System.Security.Cryptography.X509Certificates
;
using
System.Reflection
;
using
System.Reflection
;
using
log4net
;
using
log4net
;
using
System.Net.NetworkInformation
;
namespace
OnlineStore.Common
namespace
OnlineStore.Common
{
{
public
class
HttpHelper
public
class
HttpHelper
{
{
public
static
readonly
ILog
LOGGER
=
LogManager
.
GetLogger
(
MethodBase
.
GetCurrentMethod
().
DeclaringType
);
public
static
readonly
ILog
LOGGER
=
LogManager
.
GetLogger
(
MethodBase
.
GetCurrentMethod
().
DeclaringType
);
public
static
string
Post
(
string
url
,
string
paramData
)
public
static
string
Post
(
string
url
,
string
paramData
)
{
{
return
Post
(
url
,
paramData
,
Encoding
.
UTF8
);
return
Post
(
url
,
paramData
,
Encoding
.
UTF8
);
}
}
//public static bool PingURLIP(string url, int ms = 100)
//{
// string[] urlArray = url.Split('/');
// if (urlArray.Length > 3)
// {
// string ip = urlArray[2];
// Ping pingSender = new Ping();
// PingReply reply = pingSender.Send(ip, ms);//第一个参数为ip地址,第二个参数为ping的时间
// if (reply.Status == IPStatus.Success)
// {
// //通
// return true;
// }
// else
// {
// //不通
// return false;
// }
// }
// return true;
//}
/// <summary>
/// <summary>
///
///
/// </summary>
/// </summary>
...
@@ -33,7 +55,14 @@ namespace OnlineStore.Common
...
@@ -33,7 +55,14 @@ namespace OnlineStore.Common
public
static
Operation
Post
(
string
url
,
Operation
operation
,
bool
simulate
)
public
static
Operation
Post
(
string
url
,
Operation
operation
,
bool
simulate
)
{
{
try
try
{
{
//如果Op=0或者Op=5,先拼Ip,不通不发送
//if (operation.op < 0 || operation.op.Equals(5))
//{
// if (PingURLIP(url, 100).Equals(false))
// {
// return null;
// }
//}
if
(
simulate
)
if
(
simulate
)
{
//模拟服务器返回
{
//模拟服务器返回
operation
.
status
=
200
;
operation
.
status
=
200
;
...
@@ -58,7 +87,7 @@ namespace OnlineStore.Common
...
@@ -58,7 +87,7 @@ namespace OnlineStore.Common
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
L
OGGER
.
E
rror
(
"JsonHelper.SerializeObject(operation) 出错【operation.op="
+
operation
.
op
+
"】"
+
ex
);
L
ogUtil
.
e
rror
(
"JsonHelper.SerializeObject(operation) 出错【operation.op="
+
operation
.
op
+
"】"
+
ex
);
}
}
string
result
=
Post
(
url
,
json
);
string
result
=
Post
(
url
,
json
);
if
(!
string
.
IsNullOrEmpty
(
result
))
if
(!
string
.
IsNullOrEmpty
(
result
))
...
@@ -69,20 +98,24 @@ namespace OnlineStore.Common
...
@@ -69,20 +98,24 @@ namespace OnlineStore.Common
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
L
OGGER
.
E
rror
(
"JsonHelper.DeserializeJsonToObject 出错【result="
+
result
+
"】"
+
ex
);
L
ogUtil
.
e
rror
(
"JsonHelper.DeserializeJsonToObject 出错【result="
+
result
+
"】"
+
ex
);
}
}
}
}
}
}
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
L
OGGER
.
E
rror
(
"Post 出错【operation.op="
+
operation
.
op
+
"】:"
+
ex
);
L
ogUtil
.
e
rror
(
"Post 出错【operation.op="
+
operation
.
op
+
"】:"
+
ex
);
}
}
return
null
;
return
null
;
}
}
private
static
int
isLog
=
ConfigAppSettings
.
GetIntValue
(
Setting_Init
.
Server_Log_Open
);
private
static
int
isLog
=
ConfigAppSettings
.
GetIntValue
(
Setting_Init
.
Server_Log_Open
);
public
static
string
Post
(
string
url
,
string
paramData
,
Encoding
encoding
)
public
static
string
Post
(
string
url
,
string
paramData
,
Encoding
encoding
)
{
{
//if (PingURLIP(url, 100).Equals(false))
//{
// return null;
//}
if
(
isLog
==
1
)
if
(
isLog
==
1
)
{
{
LOGGER
.
Info
(
"给服务器发送数据【"
+
paramData
+
"】 "
);
LOGGER
.
Info
(
"给服务器发送数据【"
+
paramData
+
"】 "
);
...
@@ -101,7 +134,7 @@ namespace OnlineStore.Common
...
@@ -101,7 +134,7 @@ namespace OnlineStore.Common
try
try
{
{
var
wc
=
new
MyWebClient
(
5
000
);
var
wc
=
new
MyWebClient
(
10
000
);
if
(
string
.
IsNullOrEmpty
(
wc
.
Headers
[
"Content-Type"
]))
if
(
string
.
IsNullOrEmpty
(
wc
.
Headers
[
"Content-Type"
]))
wc
.
Headers
.
Add
(
"Content-Type"
,
"application/json;charset=UTF-8"
);
wc
.
Headers
.
Add
(
"Content-Type"
,
"application/json;charset=UTF-8"
);
wc
.
Encoding
=
encoding
;
wc
.
Encoding
=
encoding
;
...
@@ -111,7 +144,7 @@ namespace OnlineStore.Common
...
@@ -111,7 +144,7 @@ namespace OnlineStore.Common
}
}
catch
(
Exception
e
)
catch
(
Exception
e
)
{
{
LogUtil
.
error
(
LOGGER
,
"POST ERROR:"
+
e
.
StackTrace
,
1
);
LogUtil
.
error
(
LOGGER
,
"POST ERROR:"
+
e
.
ToString
()
,
1
);
}
}
if
(!
result
.
Contains
(
"null"
)
&&
result
.
Length
!=
0
)
if
(!
result
.
Contains
(
"null"
)
&&
result
.
Length
!=
0
)
{
{
...
@@ -119,7 +152,7 @@ namespace OnlineStore.Common
...
@@ -119,7 +152,7 @@ namespace OnlineStore.Common
}
}
if
(
isLog
==
1
)
if
(
isLog
==
1
)
{
{
L
OGGER
.
I
nfo
(
"收到服务器数据【"
+
result
+
"】"
);
L
ogUtil
.
i
nfo
(
"收到服务器数据【"
+
result
+
"】"
);
}
}
return
result
;
return
result
;
}
}
...
...
source/Common/util/LogUtil.cs
查看文件 @
41b47a4
...
@@ -5,7 +5,7 @@ using System.Text;
...
@@ -5,7 +5,7 @@ using System.Text;
using
log4net
;
using
log4net
;
using
System.Reflection
;
using
System.Reflection
;
using
System.Drawing
;
using
System.Drawing
;
using
System.Runtime.ExceptionServices
;
namespace
OnlineStore.Common
namespace
OnlineStore.Common
{
{
...
@@ -109,6 +109,8 @@ namespace OnlineStore.Common
...
@@ -109,6 +109,8 @@ namespace OnlineStore.Common
}
}
private
static
List
<
string
>
logList
=
new
List
<
string
>();
private
static
List
<
string
>
logList
=
new
List
<
string
>();
public
static
string
LastText
=
""
;
public
static
string
LastText
=
""
;
[
HandleProcessCorruptedStateExceptions
]
private
static
void
ShowLogPro
(
string
msg
,
Color
color
)
private
static
void
ShowLogPro
(
string
msg
,
Color
color
)
{
{
try
try
...
@@ -149,6 +151,10 @@ namespace OnlineStore.Common
...
@@ -149,6 +151,10 @@ namespace OnlineStore.Common
}
}
}
}
}
}
catch
(
AccessViolationException
e
)
{
LOGGER
.
Error
(
" ShowLogPro 出错:"
+
e
.
ToString
());
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
LOGGER
.
Error
(
"出错:"
+
ex
.
ToString
());
LOGGER
.
Error
(
"出错:"
+
ex
.
ToString
());
...
...
source/DeviceLibrary/IO/AIOBOX/AIOBOXManager.cs
查看文件 @
41b47a4
...
@@ -9,6 +9,7 @@ using OnlineStore.Common;
...
@@ -9,6 +9,7 @@ using OnlineStore.Common;
using
OnlineStore.LoadCSVLibrary
;
using
OnlineStore.LoadCSVLibrary
;
using
System.Threading.Tasks
;
using
System.Threading.Tasks
;
using
Asa.IOModule
;
using
Asa.IOModule
;
using
System.Windows.Forms
;
namespace
OnlineStore.DeviceLibrary
namespace
OnlineStore.DeviceLibrary
{
{
...
@@ -33,57 +34,31 @@ namespace OnlineStore.DeviceLibrary
...
@@ -33,57 +34,31 @@ namespace OnlineStore.DeviceLibrary
public
override
void
ConnectionIOList
(
List
<
string
>
DIONameList
)
public
override
void
ConnectionIOList
(
List
<
string
>
DIONameList
)
{
{
if
(
conTimer
==
null
)
{
conTimer
=
new
System
.
Timers
.
Timer
();
conTimer
.
AutoReset
=
true
;
conTimer
.
Interval
=
60000
;
conTimer
.
Elapsed
+=
ConTimer_Elapsed
;
}
conTimer
.
Enabled
=
false
;
IoIPLIst
=
new
List
<
string
>(
DIONameList
);
foreach
(
string
ip
in
DIONameList
)
foreach
(
string
ip
in
DIONameList
)
{
{
ConnectionIP
(
ip
);
ConnectionIP
(
ip
);
}
}
if
(
IoIPLIst
.
Count
>
0
)
{
//启动定时器,1一分钟重连一次
conTimer
.
Start
();
}
}
private
void
ConTimer_Elapsed
(
object
sender
,
System
.
Timers
.
ElapsedEventArgs
e
)
{
try
{
List
<
string
>
list
=
new
List
<
string
>(
IoIPLIst
);
if
(
list
.
Count
>
0
)
{
foreach
(
string
ip
in
list
)
{
LogUtil
.
info
(
"重连AOI :"
+
ip
);
ConnectionIP
(
ip
);
}
}
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"AOI ConTimer_Elapsed 出错: "
+
ex
.
ToString
());
}
}
}
private
bool
isProcess
=
false
;
private
DateTime
lastTime
=
DateTime
.
Now
;
public
void
ConnectionIP
(
string
ioIp
)
public
void
ConnectionIP
(
string
ioIp
)
{
{
AIOBOX
aioBox
=
null
;
AIOBOX
aioBox
=
null
;
if
(
AIOMap
.
ContainsKey
(
ioIp
))
if
(
AIOMap
.
ContainsKey
(
ioIp
))
{
{
aioBox
=
AIOMap
[
ioIp
];
aioBox
=
AIOMap
[
ioIp
];
try
if
(
null
!=
aioBox
)
{
if
(
null
!=
aioBox
)
{
aioBox
.
Close
();
aioBox
=
null
;
}
}
catch
(
Exception
ex
)
{
{
aioBox
.
Close
();
LogUtil
.
error
(
"关闭Io模块【"
+
ioIp
+
"】出错:"
+
ex
.
ToString
());
aioBox
=
null
;
}
}
AIOMap
.
Remove
(
ioIp
);
AIOMap
.
Remove
(
ioIp
);
}
}
...
@@ -96,14 +71,22 @@ namespace OnlineStore.DeviceLibrary
...
@@ -96,14 +71,22 @@ namespace OnlineStore.DeviceLibrary
DOValueMap
.
Remove
(
ioIp
);
DOValueMap
.
Remove
(
ioIp
);
}
}
int
DIMS
=
ConfigAppSettings
.
GetIntValue
(
"DIMS"
);
int
DIMS
=
ConfigAppSettings
.
GetIntValue
(
"DIMS"
);
if
(
DIMS
<
2
0
)
if
(
DIMS
<
=
0
)
{
{
DIMS
=
20
;
DIMS
=
150
;
}
else
if
(
DIMS
<
20
)
{
DIMS
=
100
;
}
}
int
DOMS
=
ConfigAppSettings
.
GetIntValue
(
"DOMS"
);
int
DOMS
=
ConfigAppSettings
.
GetIntValue
(
"DOMS"
);
if
(
DOMS
<
200
)
if
(
DOMS
<=
0
)
{
DOMS
=
300
;
}
else
if
(
DOMS
<
100
)
{
{
DOMS
=
2
00
;
DOMS
=
3
00
;
}
}
int
DILength
=
StoreManager
.
Config
.
GetDILength
(
ioIp
);
int
DILength
=
StoreManager
.
Config
.
GetDILength
(
ioIp
);
int
DOLength
=
StoreManager
.
Config
.
GetDOLength
(
ioIp
);
int
DOLength
=
StoreManager
.
Config
.
GetDOLength
(
ioIp
);
...
@@ -112,6 +95,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -112,6 +95,8 @@ namespace OnlineStore.DeviceLibrary
{
{
// Create new modbus master and add event functions
// Create new modbus master and add event functions
aioBox
=
new
AIOBOX
();
aioBox
=
new
AIOBOX
();
aioBox
.
LogPath
(
Application
.
StartupPath
+
@"\logs\aio\"
,
LogType
.
OnlyError
);
aioBox
.
IP
=
ioIp
;
aioBox
.
IP
=
ioIp
;
// bool rtn = aioBox.AutoIP(ioIp);
// bool rtn = aioBox.AutoIP(ioIp);
...
@@ -119,58 +104,29 @@ namespace OnlineStore.DeviceLibrary
...
@@ -119,58 +104,29 @@ namespace OnlineStore.DeviceLibrary
aioBox
.
SetInput
(
Asa
.
IOModule
.
Box_Type
.
DI
,
DILength
);
aioBox
.
SetInput
(
Asa
.
IOModule
.
Box_Type
.
DI
,
DILength
);
aioBox
.
SetOutput
(
Asa
.
IOModule
.
Box_Type
.
DO
,
DOLength
);
aioBox
.
SetOutput
(
Asa
.
IOModule
.
Box_Type
.
DO
,
DOLength
);
//DI主动上传
//DI主动上传
aioBox
.
AutoReadInput
(
true
,
DIMS
);
aioBox
.
AutoReadInput
(
true
,
DIMS
);
aioBox
.
AutoReadOutput
(
tru
e
,
DOMS
);
aioBox
.
AutoReadOutput
(
fals
e
,
DOMS
);
aioBox
.
LogOut
=
true
;
aioBox
.
DI_Changed_Event
+=
AioBox_DI_Changed_Event
;
;
aioBox
.
DI_Changed_Event
+=
AioBox_DI_Changed_Event
;
;
aioBox
.
DO_Changed_Event
+=
AioBox_DO_Changed_Event
;
aioBox
.
DO_Changed_Event
+=
AioBox_DO_Changed_Event
;
// aioBox.Log_Out_Event += AioBox_Log_Out_Event;
//aioBox.Log_RxTx_Event += AioBox_Log_RxTx_Event;
AIOMap
.
Add
(
ioIp
,
aioBox
);
LogUtil
.
debug
(
"开始连接"
+
logName
+
",尝试重连5次"
);
LogUtil
.
info
(
"开始连接:"
+
logName
+
":"
+
aioBox
.
ErrInfo
);
for
(
int
i
=
1
;
i
<=
3
;
i
++)
aioBox
.
Connect
();
{
bool
result
=
aioBox
.
Connect
();
if
(
result
)
{
LogUtil
.
info
(
"第【"
+
i
+
"】次连接 "
+
logName
+
" 成功:"
+
aioBox
.
ErrInfo
);
Thread
.
Sleep
(
10
);
//读取所有的DO
ReadAllDI
(
ioIp
,
0
);
if
(
IoIPLIst
.
Contains
(
ioIp
))
{
IoIPLIst
.
Remove
(
ioIp
);
}
break
;
}
else
{
LogUtil
.
error
(
"第【"
+
i
+
"】次连接 "
+
logName
+
" 失败:"
+
aioBox
.
ErrInfo
+
""
);
}
Thread
.
Sleep
(
2
);
}
AIOMap
.
Add
(
ioIp
,
aioBox
);
Thread
.
Sleep
(
5
);
//读取所有的DO
ReadAllDI
(
ioIp
,
0
);
Thread
.
Sleep
(
5
);
GC
.
Collect
();
}
}
catch
(
Exception
error
)
catch
(
Exception
error
)
{
{
LogUtil
.
error
(
LOGGER
,
"连接IO模块 "
+
logName
+
" 出错:"
+
error
.
ToString
());
LogUtil
.
error
(
LOGGER
,
"连接IO模块 "
+
logName
+
" 出错:"
+
error
.
ToString
());
}
}
}
}
private
void
AioBox_Reconnect_Event
(
AIOBOX
box
,
int
times
,
ref
bool
conn
,
Dictionary
<
string
,
string
>
dict
)
{
conn
=
true
;
string
msg
=
"重连AIO块【"
+
box
.
IP
+
"】次数:"
+
times
+
"【"
+
box
.
ErrInfo
+
"】,连接信息如下\r\n"
;
foreach
(
string
key
in
dict
.
Keys
)
{
msg
=
msg
+
"\t"
+
"["
+
key
+
"]=["
+
dict
[
key
]
+
"],"
;
}
LogUtil
.
error
(
msg
);
}
private
DateTime
lastLogTime
=
DateTime
.
Now
;
private
DateTime
lastLogTime
=
DateTime
.
Now
;
...
@@ -178,7 +134,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -178,7 +134,7 @@ namespace OnlineStore.DeviceLibrary
{
{
foreach
(
string
str
in
s
)
foreach
(
string
str
in
s
)
{
{
//
LogUtil.AIOLog.Debug("[" + box.IP + "]" + str);
LogUtil
.
AIOLog
.
Debug
(
"["
+
box
.
IP
+
"]"
+
str
);
}
}
}
}
...
@@ -222,14 +178,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -222,14 +178,6 @@ namespace OnlineStore.DeviceLibrary
}
}
else
else
{
{
//foreach(Box_Sta s in sta)
//{
// updateDi += s.ToString() + ",";
//}
//if (ip.Equals("192.168.201.61"))
//{
// LogUtil.info(updateDi);
//}
for
(
int
i
=
0
;
i
<
newList
.
Count
;
i
++)
for
(
int
i
=
0
;
i
<
newList
.
Count
;
i
++)
{
{
if
(!(
oldList
[
i
].
Equals
(
newList
[
i
])))
if
(!(
oldList
[
i
].
Equals
(
newList
[
i
])))
...
@@ -295,17 +243,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -295,17 +243,6 @@ namespace OnlineStore.DeviceLibrary
}
}
}
}
}
}
//else
//{
// if (sta == null)
// {
// LogUtil.error("UpdateAllDO ip[" + ip + "], sta=null");
// }
// else
// {
// LogUtil.error(" UpdateAllDO ip[" + ip + "], sta.Length=" + sta.Length);
// }
//}
}
}
...
@@ -318,9 +255,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -318,9 +255,6 @@ namespace OnlineStore.DeviceLibrary
ushort
length
=
StoreManager
.
Config
.
GetDOLength
(
aio
.
IP
);
ushort
length
=
StoreManager
.
Config
.
GetDOLength
(
aio
.
IP
);
for
(
ushort
i
=
0
;
i
<
length
;
i
++)
for
(
ushort
i
=
0
;
i
<
length
;
i
++)
{
{
// ushort u = (ushort)(i + length);
// ushort u = (ushort)(i );
// Box_Addr addr = GetAddr(u);
aio
.
WriteDO
(
i
,
Box_Sta
.
Off
);
aio
.
WriteDO
(
i
,
Box_Sta
.
Off
);
}
}
}
}
...
@@ -330,7 +264,14 @@ namespace OnlineStore.DeviceLibrary
...
@@ -330,7 +264,14 @@ namespace OnlineStore.DeviceLibrary
{
{
foreach
(
AIOBOX
aio
in
AIOMap
.
Values
)
foreach
(
AIOBOX
aio
in
AIOMap
.
Values
)
{
{
aio
.
Close
();
try
{
aio
.
Close
();
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"aio.Close出错:"
+
ex
.
ToString
());
}
}
}
AIOMap
.
Clear
();
AIOMap
.
Clear
();
}
}
...
@@ -342,19 +283,10 @@ namespace OnlineStore.DeviceLibrary
...
@@ -342,19 +283,10 @@ namespace OnlineStore.DeviceLibrary
AIOBOX
aioBox
=
getAIO
(
ioIp
);
AIOBOX
aioBox
=
getAIO
(
ioIp
);
if
(
aioBox
!=
null
)
if
(
aioBox
!=
null
)
{
{
// Box_Addr add = GetAddr(StartAddress);
bool
result
=
aioBox
.
WriteDO
(
StartAddress
,
GetBox_Sta
(
onOff
));
if
(!
result
)
for
(
int
i
=
1
;
i
<=
3
;
i
++)
{
{
bool
result
=
aioBox
.
WriteDO
(
StartAddress
,
GetBox_Sta
(
onOff
));
LogUtil
.
error
(
"AIO WriteSingleDO ["
+
ioIp
+
"] ["
+
StartAddress
+
"] 失败:"
+
aioBox
.
ErrInfo
);
if
(!
result
)
{
LogUtil
.
error
(
"AIO WriteSingleDO ["
+
StartAddress
+
"] 第"
+
i
+
"次失败:"
+
aioBox
.
ErrInfo
);
}
else
{
break
;
}
}
}
}
}
else
else
...
@@ -364,19 +296,17 @@ namespace OnlineStore.DeviceLibrary
...
@@ -364,19 +296,17 @@ namespace OnlineStore.DeviceLibrary
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
LOGGER
.
Error
(
"出错啦:"
+
ex
.
ToString
());
LOGGER
.
Error
(
"
AIO WriteSingleDO ["
+
ioIp
+
"] ["
+
StartAddress
+
"]
出错啦:"
+
ex
.
ToString
());
}
}
}
}
public
override
void
WriteSingleDO
(
string
ioIp
,
byte
slaveId
,
ushort
StartAddress
,
IO_VALUE
onOff
,
int
mSeconds
)
public
override
void
WriteSingleDO
(
string
ioIp
,
byte
slaveId
,
ushort
StartAddress
,
IO_VALUE
onOff
,
int
mSeconds
)
{
{
try
try
{
{
AIOBOX
aioBox
=
getAIO
(
ioIp
);
AIOBOX
aioBox
=
getAIO
(
ioIp
);
Box_Sta
currBox_Sta
=
GetBox_Sta
(
onOff
);
if
(
aioBox
!=
null
)
if
(
aioBox
!=
null
)
{
{
// Box_Addr add = GetAddr(StartAddress
);
Box_Sta
currBox_Sta
=
GetBox_Sta
(
onOff
);
aioBox
.
WriteDO
(
StartAddress
,
currBox_Sta
);
aioBox
.
WriteDO
(
StartAddress
,
currBox_Sta
);
//写入之后,等待指定间隔后回写
//写入之后,等待指定间隔后回写
...
@@ -386,7 +316,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -386,7 +316,7 @@ namespace OnlineStore.DeviceLibrary
try
try
{
{
aioBox
.
WriteDO
(
StartAddress
,
aioBox
.
ReverseStatus
(
currBox_Sta
));
aioBox
.
WriteDO
(
StartAddress
,
aioBox
.
ReverseStatus
(
currBox_Sta
));
LogUtil
.
debug
(
LOGGER
,
"**********定时回写入 IO
【"
+
ioIp
+
","
+
StartAddress
+
",
值"
+
aioBox
.
ReverseStatus
(
currBox_Sta
)
+
"】:"
);
LogUtil
.
debug
(
LOGGER
,
"**********定时回写入 IO
["
+
ioIp
+
"] ["
+
StartAddress
+
"]
值"
+
aioBox
.
ReverseStatus
(
currBox_Sta
)
+
"】:"
);
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
...
@@ -395,15 +325,16 @@ namespace OnlineStore.DeviceLibrary
...
@@ -395,15 +325,16 @@ namespace OnlineStore.DeviceLibrary
};
};
mytimer
.
AutoReset
=
false
;
//设置是否自动重启,即自动执行多次;
mytimer
.
AutoReset
=
false
;
//设置是否自动重启,即自动执行多次;
mytimer
.
Enabled
=
true
;
//是否执行System.Timers.Timer.Elapsed事件mytask;
mytimer
.
Enabled
=
true
;
//是否执行System.Timers.Timer.Elapsed事件mytask;
}
}
else
else
{
{
LogUtil
.
error
(
LOGGER
,
"
WriteSingleDO
出错 没有连接IO模块:"
+
ioIp
);
LogUtil
.
error
(
LOGGER
,
"
AIO WriteSingleDO ["
+
ioIp
+
"] ["
+
StartAddress
+
"]
出错 没有连接IO模块:"
+
ioIp
);
}
}
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
LogUtil
.
error
(
"
WriteSingleDO
出错:"
+
ioIp
);
LogUtil
.
error
(
"
AIO WriteSingleDO ["
+
ioIp
+
"] ["
+
StartAddress
+
"]
出错:"
+
ioIp
);
}
}
}
}
public
override
void
ReadAllDI
(
string
ioIp
,
byte
slaveId
)
public
override
void
ReadAllDI
(
string
ioIp
,
byte
slaveId
)
...
@@ -419,7 +350,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -419,7 +350,7 @@ namespace OnlineStore.DeviceLibrary
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
LogUtil
.
error
(
"ReadAllDI出错:"
+
ioIp
);
LogUtil
.
error
(
"ReadAllDI
["
+
ioIp
+
"]
出错:"
+
ioIp
);
}
}
}
}
public
override
void
ReadAllDO
(
string
ioIp
,
byte
slaveId
)
public
override
void
ReadAllDO
(
string
ioIp
,
byte
slaveId
)
...
@@ -436,7 +367,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -436,7 +367,7 @@ namespace OnlineStore.DeviceLibrary
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
LogUtil
.
error
(
"ReadAllDO出错:"
+
ioIp
);
LogUtil
.
error
(
"ReadAllDO
["
+
ioIp
+
"]
出错:"
+
ioIp
);
}
}
}
}
public
override
IO_VALUE
GetDOValue
(
string
ioIP
,
byte
slaveId
,
ushort
StartAddress
)
public
override
IO_VALUE
GetDOValue
(
string
ioIP
,
byte
slaveId
,
ushort
StartAddress
)
...
@@ -448,9 +379,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -448,9 +379,6 @@ namespace OnlineStore.DeviceLibrary
if
(
aioBox
!=
null
)
if
(
aioBox
!=
null
)
{
{
Box_Sta
sta
=
Box_Sta
.
Off
;
Box_Sta
sta
=
Box_Sta
.
Off
;
// Box_Addr addr = GetAddr(StartAddress);
// int index = (int)StartAddress - (int)StoreManager.Config.GetDILength(ioIP);
if
(
DOValueMap
.
ContainsKey
(
ioIP
)
&&
DOValueMap
[
ioIP
].
Count
>
StartAddress
)
if
(
DOValueMap
.
ContainsKey
(
ioIP
)
&&
DOValueMap
[
ioIP
].
Count
>
StartAddress
)
{
{
sta
=
DOValueMap
[
ioIP
][
StartAddress
];
sta
=
DOValueMap
[
ioIP
][
StartAddress
];
...
@@ -465,7 +393,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -465,7 +393,7 @@ namespace OnlineStore.DeviceLibrary
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
LogUtil
.
error
(
"GetDOValue 出错:"
+
ex
.
ToString
());
LogUtil
.
error
(
"GetDOValue
["
+
ioIP
+
"] ["
+
StartAddress
+
"]
出错:"
+
ex
.
ToString
());
}
}
return
value
;
return
value
;
}
}
...
@@ -473,31 +401,34 @@ namespace OnlineStore.DeviceLibrary
...
@@ -473,31 +401,34 @@ namespace OnlineStore.DeviceLibrary
public
override
IO_VALUE
GetDIValue
(
string
ioIP
,
byte
slaveId
,
ushort
StartAddress
)
public
override
IO_VALUE
GetDIValue
(
string
ioIP
,
byte
slaveId
,
ushort
StartAddress
)
{
{
IO_VALUE
value
=
IO_VALUE
.
LOW
;
IO_VALUE
value
=
IO_VALUE
.
LOW
;
try
for
(
int
i
=
1
;
i
<=
3
;
i
++)
{
{
AIOBOX
aioBox
=
getAIO
(
ioIP
);
try
if
(
aioBox
!=
null
)
{
{
Box_Sta
sta
=
Box_Sta
.
Off
;
AIOBOX
aioBox
=
getAIO
(
ioIP
);
// Box_Addr addr = GetAddr(StartAddress);
if
(
aioBox
!=
null
)
int
index
=
StartAddress
;
if
(
DIValueMap
.
ContainsKey
(
ioIP
)
&&
DIValueMap
[
ioIP
].
Count
>
index
)
{
{
sta
=
DIValueMap
[
ioIP
][
index
];
Box_Sta
sta
=
Box_Sta
.
Off
;
}
// Box_Addr addr = GetAddr(StartAddress);
else
int
index
=
StartAddress
;
{
if
(
DIValueMap
.
ContainsKey
(
ioIP
)
&&
DIValueMap
[
ioIP
].
Count
>
index
)
sta
=
aioBox
.
ReadDI
(
StartAddress
);
{
}
sta
=
DIValueMap
[
ioIP
][
index
];
if
(
sta
.
Equals
(
Box_Sta
.
On
))
}
{
else
value
=
IO_VALUE
.
HIGH
;
{
sta
=
aioBox
.
ReadDI
(
StartAddress
);
}
if
(
sta
.
Equals
(
Box_Sta
.
On
))
{
value
=
IO_VALUE
.
HIGH
;
}
}
}
}
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
LogUtil
.
error
(
"GetDIValue ["
+
ioIP
+
"] ["
+
StartAddress
+
"] ["
+
i
+
"] 出错:"
+
ex
.
ToString
());
LogUtil
.
error
(
"GetDIValue 出错:"
+
ex
.
ToString
());
}
}
}
return
value
;
return
value
;
}
}
...
@@ -508,24 +439,20 @@ namespace OnlineStore.DeviceLibrary
...
@@ -508,24 +439,20 @@ namespace OnlineStore.DeviceLibrary
{
{
if
(
configIO
.
ProType
.
Equals
(
ConfigItemType
.
DI
))
if
(
configIO
.
ProType
.
Equals
(
ConfigItemType
.
DI
))
{
{
return
GetDIValue
(
configIO
.
DeviceName
,
configIO
.
SlaveID
,
configIO
.
GetIOAddr
());
return
GetDIValue
(
configIO
.
IO_IP
,
configIO
.
SlaveID
,
configIO
.
GetIOAddr
());
}
}
else
if
(
configIO
.
ProType
.
Equals
(
ConfigItemType
.
DO
))
else
if
(
configIO
.
ProType
.
Equals
(
ConfigItemType
.
DO
))
{
{
return
GetDOValue
(
configIO
.
DeviceName
,
configIO
.
SlaveID
,
configIO
.
GetIOAddr
());
return
GetDOValue
(
configIO
.
IO_IP
,
configIO
.
SlaveID
,
configIO
.
GetIOAddr
());
}
}
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
{
{
LogUtil
.
error
(
LOGGER
,
" GetIOValue 获取数据出错:"
+
ex
.
ToString
());
LogUtil
.
error
(
LOGGER
,
" GetIOValue
["
+
configIO
.
IO_IP
+
"] ["
+
configIO
.
GetIOAddr
()
+
"]
获取数据出错:"
+
ex
.
ToString
());
}
}
return
value
;
return
value
;
}
}
//private Box_Addr GetAddr(ushort StartAddress)
//{
// return (Box_Addr)(StartAddress);
//}
private
Box_Sta
GetBox_Sta
(
IO_VALUE
onOff
)
private
Box_Sta
GetBox_Sta
(
IO_VALUE
onOff
)
{
{
if
(
onOff
.
Equals
(
IO_VALUE
.
HIGH
))
if
(
onOff
.
Equals
(
IO_VALUE
.
HIGH
))
...
@@ -547,5 +474,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -547,5 +474,7 @@ namespace OnlineStore.DeviceLibrary
}
}
return
aioBox
;
return
aioBox
;
}
}
}
}
}
}
\ No newline at end of file
\ No newline at end of file
source/DeviceLibrary/StoreConfig/AC/StoreConfig.csv
查看文件 @
41b47a4
类型,说明,名称,属性值,设备名称,默认值,描述,电器定义,代码定义,SlaveID,
类型,说明,名称,属性值,设备名称,默认值,描述,电器定义,代码定义,SlaveID,
PRO,IO模块对应的DI数量,IO_DILength,192.168.20
1.21#8
,,,,,,,
PRO,IO模块对应的DI数量,IO_DILength,192.168.20
2.21#8,,,,
,,,,,,,
PRO,模块对应的DO数量,IO_DOLength,192.168.20
1.21#8
,,,,,,,
PRO,模块对应的DO数量,IO_DOLength,192.168.20
2.21#8,,,,
,,,,,,,
PRO,是否有仓门,HasDoor,1,,,,,,,
PRO,是否有仓门,HasDoor,1,,,,,,,
,,,,
PRO,IO模块IP,PRO_AOI_IP_1,192.168.20
1.21
,,,,,,,
PRO,IO模块IP,PRO_AOI_IP_1,192.168.20
2.21,,,,
,,,,,,,
,,,,,,,,,,
,,,,,,,,,,
DI,急停,SuddenStop_BTN,0,PRO_AOI_IP_1,0,急停,X01,DI-01,0,
DI,急停,SuddenStop_BTN,0,PRO_AOI_IP_1,0,急停,X01,DI-01,0,
DI,复位,Reset_BTN,1,PRO_AOI_IP_1,0,复位,X02,DI-02,0,
DI,复位,Reset_BTN,1,PRO_AOI_IP_1,0,复位,X02,DI-02,0,
...
@@ -20,85 +20,85 @@ DO,轴2刹车电源ON,Axis_Brake,4,PRO_AOI_IP_1,0,轴2刹车电源ON,Y05,DO-05,0,
...
@@ -20,85 +20,85 @@ DO,轴2刹车电源ON,Axis_Brake,4,PRO_AOI_IP_1,0,轴2刹车电源ON,Y05,DO-05,0,
DO,料仓吹气SOL,StartOrStopBlow,5,PRO_AOI_IP_1,0,料仓吹气SOL,Y06,DO-06,0,
DO,料仓吹气SOL,StartOrStopBlow,5,PRO_AOI_IP_1,0,料仓吹气SOL,Y06,DO-06,0,
DO,进料口门上升SOL,Door_Up,6,PRO_AOI_IP_1,0,进料口门上升SOL,Y07,DO-07,0,
DO,进料口门上升SOL,Door_Up,6,PRO_AOI_IP_1,0,进料口门上升SOL,Y07,DO-07,0,
DO,进料口门下降SOL,Door_Down,7,PRO_AOI_IP_1,0,进料口门下降SOL,Y08,DO-08,0,
DO,进料口门下降SOL,Door_Down,7,PRO_AOI_IP_1,0,进料口门下降SOL,Y08,DO-08,0,
AXIS,(轴一)旋转轴,Middle_Axis,1,COM
3
,0,,,,,
AXIS,(轴一)旋转轴,Middle_Axis,1,COM
4
,0,,,,,
AXIS,(轴二)升降轴轴,UpDown_Axis,2,COM
3
,0,,,,,
AXIS,(轴二)升降轴轴,UpDown_Axis,2,COM
4
,0,,,,,
AXIS,(轴三)进出轴,InOut_Axis,3,COM
3
,0,,,,,
AXIS,(轴三)进出轴,InOut_Axis,3,COM
4
,0,,,,,
AXIS,(轴四)压紧轴,Comp_Axis,4,COM
3
,0,,,,,
AXIS,(轴四)压紧轴,Comp_Axis,4,COM
4
,0,,,,,
PRO,升降轴 进料口取料点 P1,UpDownAxis_DoorOPosition_P1,30
1400
,,,,,,,
PRO,升降轴 进料口取料点 P1,UpDownAxis_DoorOPosition_P1,30
4500,,,,
,,,,,,,
PRO,升降轴 进料口出料前点 P2,UpDownAxis_DoorIPosition_P2,32
1500
,,,,,,,
PRO,升降轴 进料口出料前点 P2,UpDownAxis_DoorIPosition_P2,32
5300,,,,
,,,,,,,
PRO,升降轴 进料口取料缓冲点 P7,UpDownAxis_DoorOBPosition_P7,32
1500
,,,,,,,
PRO,升降轴 进料口取料缓冲点 P7,UpDownAxis_DoorOBPosition_P7,32
5300,,,,
,,,,,,,
PRO,升降轴 进料口出料缓冲点 P8,UpDownAxis_DoorIBPosition_P8,30
1400
,,,,,,,
PRO,升降轴 进料口出料缓冲点 P8,UpDownAxis_DoorIBPosition_P8,30
4500,,,,
,,,,,,,
PRO,旋转轴(轴1)P1 待机原位点,MiddleAxis_P1_Position,3
25000
,,,,,,,
PRO,旋转轴(轴1)P1 待机原位点,MiddleAxis_P1_Position,3
59300,,,,
,,,,,,,
PRO,进出轴(轴3)P1待机原位点,InOutAxis_P1_Position,
7900
,,,,,,,
PRO,进出轴(轴3)P1待机原位点,InOutAxis_P1_Position,
1000,,,,
,,,,,,,
PRO,压紧轴(轴4)P1待机原位点,CompressAxis_P1_Position,
318000
,,,,,,,
PRO,压紧轴(轴4)P1待机原位点,CompressAxis_P1_Position,
28000,,,,
,,,,,,,
PRO,是否使用定位气缸,IsHasLocationCylinder,0,,,,,,,
PRO,是否使用定位气缸,IsHasLocationCylinder,0,,,,,,,
,,,,
PRO,是否有左右侧门,IsHasDoorLimit,1,,,,,,,
PRO,是否有左右侧门,IsHasDoorLimit,1,,,,,,,
,,,,
PRO,是否使用压紧轴(1=使用),IsHasCompress_Axis,1,,,,, ,,
PRO,是否使用压紧轴(1=使用),IsHasCompress_Axis,1,,,,, ,,
,,,,
PRO,气压检测IO关闭需要持续的时间,AirCheckSeconds,3,,,,,,,
PRO,气压检测IO关闭需要持续的时间,AirCheckSeconds,3,,,,,,,
,,,,
,,,,,,,,,,
,,,,,,,,,,
PRO,预警温度,WarnTemperate,80,,,,,,,
PRO,预警温度,WarnTemperate,80,,,,,,,
,,,,
PRO,预警湿度,WarnHumidity,80,,,,,,,
PRO,预警湿度,WarnHumidity,80,,,,,,,
,,,,
PRO,(轴一)旋转轴目标速度,MiddleAxis_TargetSpeed,250,,,,,,,
PRO,(轴一)旋转轴目标速度,MiddleAxis_TargetSpeed,250,,,,,,,
,,,,
PRO,(轴一)旋转轴加速度,MiddleAxis_AddSpeed,1000,,,,,,,
PRO,(轴一)旋转轴加速度,MiddleAxis_AddSpeed,1000,,,,,,,
,,,,
PRO,(轴一)旋转轴减速度,MiddleAxis_DelSpeed,1000,,,,,,,
PRO,(轴一)旋转轴减速度,MiddleAxis_DelSpeed,1000,,,,,,,
,,,,
PRO,(轴一)旋转轴原点低速度,MiddleAxis_HomeLowSpeed,80,,,,,,,
PRO,(轴一)旋转轴原点低速度,MiddleAxis_HomeLowSpeed,80,,,,,,,
,,,,
PRO,(轴一)旋转轴原点高速,MiddleAxis_HomeHighSpeed,60,,,,,,,
PRO,(轴一)旋转轴原点高速,MiddleAxis_HomeHighSpeed,60,,,,,,,
,,,,
PRO,(轴一)旋转轴原点加速度,MiddleAxis_HomeAddSpeed,50,,,,,,,
PRO,(轴一)旋转轴原点加速度,MiddleAxis_HomeAddSpeed,50,,,,,,,
,,,,
PRO,(轴二)升降轴轴目标速度,UpdownAxis_TargetSpeed,150,,,,,,,
PRO,(轴二)升降轴轴目标速度,UpdownAxis_TargetSpeed,150,,,,,,,
,,,,
PRO,(轴二)升降轴轴加速度,UpdownAxis_AddSpeed,400,,,,,,,
PRO,(轴二)升降轴轴加速度,UpdownAxis_AddSpeed,400,,,,,,,
,,,,
PRO,(轴二)升降轴轴减速度,UpdownAxis_DelSpeed,400,,,,,,,
PRO,(轴二)升降轴轴减速度,UpdownAxis_DelSpeed,400,,,,,,,
,,,,
PRO,(轴二)升降轴轴原点低速度,UpdownAxis_HomeLowSpeed,100,,,,,,,
PRO,(轴二)升降轴轴原点低速度,UpdownAxis_HomeLowSpeed,100,,,,,,,
,,,,
PRO,(轴二)升降轴轴原点高速,UpdownAxis_HomeHighSpeed,200,,,,,,,
PRO,(轴二)升降轴轴原点高速,UpdownAxis_HomeHighSpeed,200,,,,,,,
,,,,
PRO,(轴二)升降轴轴原点加速度,UpdownAxis_HomeAddSpeed,200,,,,,,,
PRO,(轴二)升降轴轴原点加速度,UpdownAxis_HomeAddSpeed,200,,,,,,,
,,,,
PRO,(轴三)进出轴目标速度,InoutAxis_TargetSpeed,100,,,,,,,
PRO,(轴三)进出轴目标速度,InoutAxis_TargetSpeed,100,,,,,,,
,,,,
PRO,(轴三)进出轴加速度,InoutAxis_AddSpeed,300,,,,,,,
PRO,(轴三)进出轴加速度,InoutAxis_AddSpeed,300,,,,,,,
,,,,
PRO,(轴三)进出轴减速度,InoutAxis_DelSpeed,300,,,,,,,
PRO,(轴三)进出轴减速度,InoutAxis_DelSpeed,300,,,,,,,
,,,,
PRO,(轴三)进出轴原点低速,InoutAxis_HomeLowSpeed,20,,,,,,,
PRO,(轴三)进出轴原点低速,InoutAxis_HomeLowSpeed,20,,,,,,,
,,,,
PRO,(轴三)进出轴原点高速,InoutAxis_HomeHighSpeed,60,,,,,,,
PRO,(轴三)进出轴原点高速,InoutAxis_HomeHighSpeed,60,,,,,,,
,,,,
PRO,(轴三)进出轴原点加速度,InoutAxis_HomeAddSpeed,200,,,,,,,
PRO,(轴三)进出轴原点加速度,InoutAxis_HomeAddSpeed,200,,,,,,,
,,,,
PRO,(轴四)压紧轴目标速度,CompAxis_TargetSpeed,100,,,,,,,
PRO,(轴四)压紧轴目标速度,CompAxis_TargetSpeed,100,,,,,,,
,,,,
PRO,(轴四)压紧轴加速度,CompAxis_AddSpeed,300,,,,,,,
PRO,(轴四)压紧轴加速度,CompAxis_AddSpeed,300,,,,,,,
,,,,
PRO,(轴四)压紧轴减速度,CompAxis_DelSpeed,300,,,,,,,
PRO,(轴四)压紧轴减速度,CompAxis_DelSpeed,300,,,,,,,
,,,,
PRO,(轴四)压紧轴原点低速,CompAxis_HomeLowSpeed,20,,,,,,,
PRO,(轴四)压紧轴原点低速,CompAxis_HomeLowSpeed,20,,,,,,,
,,,,
PRO,(轴四)压紧轴原点高速,CompAxis_HomeHighSpeed,60,,,,,,,
PRO,(轴四)压紧轴原点高速,CompAxis_HomeHighSpeed,60,,,,,,,
,,,,
PRO,(轴四)压紧轴原点加速度,CompAxis_HomeAddSpeed,200,,,,,,,
PRO,(轴四)压紧轴原点加速度,CompAxis_HomeAddSpeed,200,,,,,,,
,,,,
,,,,,,,,,,
,,,,,,,,,,
PRO,升降轴(轴2)P1速度,UpDownAxis_P1_Speed,1000,,,,,,,
PRO,升降轴(轴2)P1速度,UpDownAxis_P1_Speed,1000,,,,,,,
,,,,
PRO,升降轴(轴2)P2速度,UpDownAxis_P2_Speed,600,,,,,,,
PRO,升降轴(轴2)P2速度,UpDownAxis_P2_Speed,600,,,,,,,
,,,,
PRO,升降轴(轴2)P3速度,UpDownAxis_P3_Speed,1000,,,,,,,
PRO,升降轴(轴2)P3速度,UpDownAxis_P3_Speed,1000,,,,,,,
,,,,
PRO,升降轴(轴2)P4速度,UpDownAxis_P4_Speed,
600
,,,,,,,
PRO,升降轴(轴2)P4速度,UpDownAxis_P4_Speed,
100,,,,
,,,,,,,
PRO,升降轴(轴2)P5速度,UpDownAxis_P5_Speed,1000,,,,,,,
PRO,升降轴(轴2)P5速度,UpDownAxis_P5_Speed,1000,,,,,,,
,,,,
PRO,升降轴(轴2)P6速度,UpDownAxis_P6_Speed,
600
,,,,,,,
PRO,升降轴(轴2)P6速度,UpDownAxis_P6_Speed,
100,,,,
,,,,,,,
PRO,升降轴(轴2)P7速度,UpDownAxis_P7_Speed,
600,,,,,,
,
PRO,升降轴(轴2)P7速度,UpDownAxis_P7_Speed,
100,,,,,, ,,,,
,
PRO,升降轴(轴2)P8速度,UpDownAxis_P8_Speed,
600
,,,,,,,
PRO,升降轴(轴2)P8速度,UpDownAxis_P8_Speed,
100,,,,
,,,,,,,
PRO,旋转轴(轴1)P1速度,MiddleAxis_P1_Speed,500,,,,,,,
PRO,旋转轴(轴1)P1速度,MiddleAxis_P1_Speed,500,,,,,,,
,,,,
PRO,旋转轴(轴1)P2速度,MiddleAxis_P2_Speed,500,,,,,,,
PRO,旋转轴(轴1)P2速度,MiddleAxis_P2_Speed,500,,,,,,,
,,,,
PRO,进出轴(轴3)P1速度,InOutAxis_P1_Speed,
600
,,,,,,,
PRO,进出轴(轴3)P1速度,InOutAxis_P1_Speed,
500,,,,
,,,,,,,
PRO,进出轴(轴3)P2速度,InOutAxis_P2_Speed,
600
,,,,,,,
PRO,进出轴(轴3)P2速度,InOutAxis_P2_Speed,
500,,,,
,,,,,,,
PRO,进出轴(轴3)P3速度,InOutAxis_P3_Speed,
600
,,,,,,,
PRO,进出轴(轴3)P3速度,InOutAxis_P3_Speed,
500,,,,
,,,,,,,
PRO,压紧轴(轴4)P1速度,CompAxis_P1_Speed,
600
,,,,,,,
PRO,压紧轴(轴4)P1速度,CompAxis_P1_Speed,
800,,,,
,,,,,,,
PRO,压紧轴(轴4)P2速度,CompAxis_P2_Speed,
600
,,,,,,,
PRO,压紧轴(轴4)P2速度,CompAxis_P2_Speed,
800,,,,
,,,,,,,
PRO,压紧轴(轴4)P3速度,CompAxis_P3_Speed,
600
,,,,,,,
PRO,压紧轴(轴4)P3速度,CompAxis_P3_Speed,
800,,,,
,,,,,,,
PRO,(轴一)旋转轴停止时可误差的脉冲数的最小值,MiddleAxis_ErrorCountMin,10,,,,,,,
PRO,(轴一)旋转轴停止时可误差的脉冲数的最小值,MiddleAxis_ErrorCountMin,10,,,,,,,
,,,,
PRO,(轴二)升降轴轴停止时可误差的脉冲数的最小值,UpdownAxis_ErrorCountMin,10,,,,,, ,
PRO,(轴二)升降轴轴停止时可误差的脉冲数的最小值,UpdownAxis_ErrorCountMin,10,,,,,, ,
,,,,
PRO,(轴三)进出轴停止时可误差的脉冲数的最小值,InoutAxis_ErrorCountMin,10,,,,,,,
PRO,(轴三)进出轴停止时可误差的脉冲数的最小值,InoutAxis_ErrorCountMin,10,,,,,,,
,,,,
PRO,(轴一)旋转轴停止时可误差的脉冲数的最大值,MiddleAxis_ErrorCountMax,1000,,,,,,,
PRO,(轴一)旋转轴停止时可误差的脉冲数的最大值,MiddleAxis_ErrorCountMax,1000,,,,,,,
,,,,
PRO,(轴二)升降轴轴停止时可误差的脉冲数的最大值,UpdownAxis_ErrorCountMax,1000,,,,,,,
PRO,(轴二)升降轴轴停止时可误差的脉冲数的最大值,UpdownAxis_ErrorCountMax,1000,,,,,,,
,,,,
PRO,(轴三)进出轴停止时可误差的脉冲数的最大值,InoutAxis_ErrorCountMax,1000,,,,,,,
PRO,(轴三)进出轴停止时可误差的脉冲数的最大值,InoutAxis_ErrorCountMax,1000,,,,,,,
,,,,
PRO,出入库多少次,会自动重置旋转轴,Box_ResetMCount,1000,,,,,,,
PRO,出入库多少次,会自动重置旋转轴,Box_ResetMCount,1000,,,,,,,
,,,,
PRO,出入库多少次,会自动重置所有轴操作,Box_ResetACount,100,,,,,,,
PRO,出入库多少次,会自动重置所有轴操作,Box_ResetACount,100,,,,,,,
,,,,
PRO,IO信号超时时间(毫秒),IOSingle_TimerOut,10000,,,,,,,
PRO,IO信号超时时间(毫秒),IOSingle_TimerOut,10000,,,,,,,
,,,,
PRO,是否使用料盘检测信号,IsUse_Tray_Check,0,,,,,, ,
PRO,是否使用料盘检测信号,IsUse_Tray_Check,0,,,,,, ,
,,,,
PRO,(轴一)旋转轴最小限位,MiddleAxis_PositionMin,0,,,,,,,
PRO,(轴一)旋转轴最小限位,MiddleAxis_PositionMin,0,,,,,,,
,,,,
PRO,(轴二)升降轴最小限位,UpdownAxis_PositionMin,0,,,,,,,
PRO,(轴二)升降轴最小限位,UpdownAxis_PositionMin,0,,,,,,,
,,,,
PRO,(轴三)进出轴最小限位,InoutAxis_PositionMin,0,,,,,,,
PRO,(轴三)进出轴最小限位,InoutAxis_PositionMin,0,,,,,,,
,,,,
PRO,(轴一)旋转轴最大限位,MiddleAxis_PositionMax,0,,,,,,,
PRO,(轴一)旋转轴最大限位,MiddleAxis_PositionMax,0,,,,,,,
,,,,
PRO,(轴二)升降轴最大限位,UpdownAxis_PositionMax,0,,,,,,,
PRO,(轴二)升降轴最大限位,UpdownAxis_PositionMax,0,,,,,,,
,,,,
PRO,(轴三)进出轴最大限位,InoutAxis_PositionMax,0,,,,,,,
PRO,(轴三)进出轴最大限位,InoutAxis_PositionMax,0,,,,,,,
,,,,
PRO,需要吹气的温度(温度标准),Max_Temperature,0,,,,,,,
PRO,需要吹气的温度(温度标准),Max_Temperature,0,,,,,,,
,,,,
PRO,需要吹气的湿度(湿度标准),Max_Humidity,10,,,,,,,
PRO,需要吹气的湿度(湿度标准),Max_Humidity,10,,,,,,,
,,,,
PRO,每次吹气的时间(分钟),BlowAir_Time,10,,,,,,,
PRO,每次吹气的时间(分钟),BlowAir_Time,10,,,,,,,
,,,,
PRO,两次吹气间隔(分钟),BlowAir_Interval,10,,,,,,,
PRO,两次吹气间隔(分钟),BlowAir_Interval,10,,,,,,,
,,,,
PRO,温湿度端口号,Humiture_Port,COM
1
,,,,,,,
PRO,温湿度端口号,Humiture_Port,COM
5,,,,
,,,,,,,
,,,,,,,,, ,
,,,,,,,,, ,
,,,,,,,,, ,
,,,,,,,,, ,
source/DeviceLibrary/StoreConfig/AC/linePositions.csv
查看文件 @
41b47a4
此文件的差异太大,无法显示。
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean.cs
查看文件 @
41b47a4
...
@@ -53,7 +53,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -53,7 +53,7 @@ namespace OnlineStore.DeviceLibrary
serverConnectTimer
.
Enabled
=
false
;
serverConnectTimer
.
Enabled
=
false
;
serverConnectTimer
.
Elapsed
+=
server_connect_timer_Tick
;
serverConnectTimer
.
Elapsed
+=
server_connect_timer_Tick
;
IoCheckTimer
=
new
System
.
Timers
.
Timer
();
IoCheckTimer
=
new
System
.
Timers
.
Timer
();
IoCheckTimer
.
Interval
=
2
00
;
IoCheckTimer
.
Interval
=
3
00
;
IoCheckTimer
.
AutoReset
=
true
;
IoCheckTimer
.
AutoReset
=
true
;
IoCheckTimer
.
Enabled
=
false
;
IoCheckTimer
.
Enabled
=
false
;
IoCheckTimer
.
Elapsed
+=
IoCheckTimer_Elapsed
;
IoCheckTimer
.
Elapsed
+=
IoCheckTimer_Elapsed
;
...
@@ -71,7 +71,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -71,7 +71,7 @@ namespace OnlineStore.DeviceLibrary
PositionNumList
=
new
List
<
string
>();
PositionNumList
=
new
List
<
string
>();
foreach
(
ACStorePosition
position
in
positionList
)
foreach
(
ACStorePosition
position
in
positionList
)
{
{
// if (position.StoreId.Equals(StoreID))
// if (position.StoreId.Equals(StoreID))
{
{
bool
result
=
ACStorePosition
.
CheckPosition
(
position
,
Config
);
bool
result
=
ACStorePosition
.
CheckPosition
(
position
,
Config
);
if
(
result
)
if
(
result
)
...
@@ -107,17 +107,27 @@ namespace OnlineStore.DeviceLibrary
...
@@ -107,17 +107,27 @@ namespace OnlineStore.DeviceLibrary
{
{
if
(
isInSuddenDown
.
Equals
(
false
))
if
(
isInSuddenDown
.
Equals
(
false
))
{
{
isInSuddenDown
=
true
;
LogUtil
.
error
(
StoreName
+
"收到急停信号,等待100后再次验证急停"
);
LogUtil
.
error
(
LOGGER
,
StoreName
+
"收到急停信号,报警急停"
);
Task
.
Factory
.
StartNew
(
delegate
WarnMsg
=
StoreName
+
"收到急停信号,报警急停"
;
{
Thread
.
Sleep
(
100
);
if
(
IOManager
.
IOValue
(
IO_Type
.
SuddenStop_BTN
).
Equals
(
IO_VALUE
.
LOW
))
{
isInSuddenDown
=
true
;
LogUtil
.
error
(
LOGGER
,
StoreName
+
"收到急停信号,报警急停"
);
WarnMsg
=
StoreName
+
"收到急停信号,报警急停"
;
//报警时会关闭所有轴
Alarm
(
StoreAlarmType
.
SuddenStop
,
"1"
,
WarnMsg
,
StoreMoveType
.
None
);
}
//报警时会关闭所有轴
});
Alarm
(
StoreAlarmType
.
SuddenStop
,
"1"
,
WarnMsg
,
StoreMoveType
.
None
);
}
}
}
}
}
}
}
}
/// <summary>
/// <summary>
/// 配置速度,加减速时间
/// 配置速度,加减速时间
/// </summary>
/// </summary>
...
@@ -1183,7 +1193,16 @@ namespace OnlineStore.DeviceLibrary
...
@@ -1183,7 +1193,16 @@ namespace OnlineStore.DeviceLibrary
#
region
入库命令处理
#
region
入库命令处理
private
int
StrToInt
(
string
str
)
{
try
{
return
Convert
.
ToInt32
(
str
.
Trim
());
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
StoreName
+
"转换["
+
str
+
"]出错:"
+
ex
.
ToString
());
}
return
0
;
}
private
void
ReviceInStoreProcess
(
string
message
,
Operation
resultOperation
)
private
void
ReviceInStoreProcess
(
string
message
,
Operation
resultOperation
)
{
{
Dictionary
<
string
,
string
>
data
=
resultOperation
.
data
;
Dictionary
<
string
,
string
>
data
=
resultOperation
.
data
;
...
@@ -1191,8 +1210,10 @@ namespace OnlineStore.DeviceLibrary
...
@@ -1191,8 +1210,10 @@ namespace OnlineStore.DeviceLibrary
{
{
//服务器返回时有:posId库位编号,plateW:料盘宽度,plateH:料盘高度,
//服务器返回时有:posId库位编号,plateW:料盘宽度,plateH:料盘高度,
string
posId
=
data
[
ParamDefine
.
posId
];
string
posId
=
data
[
ParamDefine
.
posId
];
string
plateW
=
data
[
ParamDefine
.
plateW
];
string
plateWStr
=
data
[
ParamDefine
.
plateW
];
string
plateH
=
data
[
ParamDefine
.
plateH
];
string
plateHStr
=
data
[
ParamDefine
.
plateH
];
int
plateW
=
StrToInt
(
plateWStr
);
int
plateH
=
StrToInt
(
plateHStr
);
InOutPosInfo
inoutInfo
=
new
InOutPosInfo
(
message
,
posId
,
plateH
,
plateW
);
InOutPosInfo
inoutInfo
=
new
InOutPosInfo
(
message
,
posId
,
plateH
,
plateW
);
//根据发送的posId获取位置列表
//根据发送的posId获取位置列表
...
@@ -1221,7 +1242,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -1221,7 +1242,7 @@ namespace OnlineStore.DeviceLibrary
}
}
public
bool
ReviceLineCheckInStoreCMD
(
string
posId
,
string
plateH
,
string
plateW
,
string
message
,
string
rfid
)
public
bool
ReviceLineCheckInStoreCMD
(
string
posId
,
int
plateH
,
int
plateW
,
string
message
,
string
rfid
)
{
{
string
logName
=
"入库库位验证【 "
+
message
+
"】【"
+
posId
+
"】:"
;
string
logName
=
"入库库位验证【 "
+
message
+
"】【"
+
posId
+
"】:"
;
try
try
...
@@ -1265,7 +1286,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -1265,7 +1286,7 @@ namespace OnlineStore.DeviceLibrary
}
}
return
false
;
return
false
;
}
}
public
void
ReviceLineInStoreCMD
(
string
posId
,
string
plateH
,
string
plateW
,
string
message
,
string
rfid
)
public
void
ReviceLineInStoreCMD
(
string
posId
,
int
plateH
,
int
plateW
,
string
message
,
string
rfid
)
{
{
string
logName
=
"流水线入库命令【 "
+
message
+
"】【"
+
posId
+
"】:"
;
string
logName
=
"流水线入库命令【 "
+
message
+
"】【"
+
posId
+
"】:"
;
if
(!
LineConnect
.
WaitInStoreList
.
Contains
(
posId
))
if
(!
LineConnect
.
WaitInStoreList
.
Contains
(
posId
))
...
@@ -1444,13 +1465,19 @@ namespace OnlineStore.DeviceLibrary
...
@@ -1444,13 +1465,19 @@ namespace OnlineStore.DeviceLibrary
private
string
CodeMsg
=
""
;
private
string
CodeMsg
=
""
;
private
bool
isInProcess
=
false
;
private
bool
isInProcess
=
false
;
private
DateTime
lastConTime
=
DateTime
.
Now
;
public
void
server_connect_timer_Tick
(
object
sender
,
EventArgs
e
)
public
void
server_connect_timer_Tick
(
object
sender
,
EventArgs
e
)
{
{
if
(
isInProcess
)
if
(
isInProcess
)
{
{
return
;
TimeSpan
span
=
DateTime
.
Now
-
lastConTime
;
}
if
(
span
.
TotalSeconds
<
60
)
{
return
;
}
}
isInProcess
=
true
;
isInProcess
=
true
;
lastConTime
=
DateTime
.
Now
;
try
try
{
{
if
(
LineConnect
.
IsConnect
())
if
(
LineConnect
.
IsConnect
())
...
@@ -1483,7 +1510,10 @@ namespace OnlineStore.DeviceLibrary
...
@@ -1483,7 +1510,10 @@ namespace OnlineStore.DeviceLibrary
{
{
LogUtil
.
error
(
"server_connect_timer_Tick出错:"
+
ex
.
ToString
());
LogUtil
.
error
(
"server_connect_timer_Tick出错:"
+
ex
.
ToString
());
}
}
isInProcess
=
false
;
finally
{
isInProcess
=
false
;
}
}
}
/// <summary>
/// <summary>
...
@@ -1675,8 +1705,11 @@ namespace OnlineStore.DeviceLibrary
...
@@ -1675,8 +1705,11 @@ namespace OnlineStore.DeviceLibrary
foreach
(
string
posId
in
posIdArray
)
foreach
(
string
posId
in
posIdArray
)
{
{
index
++;
index
++;
string
plateW
=
plateWArray
[
index
];
string
plateWStr
=
plateWArray
[
index
];
string
plateH
=
plateHArray
[
index
];
string
plateHStr
=
plateHArray
[
index
];
int
plateW
=
StrToInt
(
plateWStr
);
int
plateH
=
StrToInt
(
plateHStr
);
InOutPosInfo
intouInfo
=
new
InOutPosInfo
(
barcode
,
posId
,
plateW
,
plateH
,
urgentReel
,
cutReel
,
smallReel
,
rfid
,
rfidLoc
);
InOutPosInfo
intouInfo
=
new
InOutPosInfo
(
barcode
,
posId
,
plateW
,
plateH
,
urgentReel
,
cutReel
,
smallReel
,
rfid
,
rfidLoc
);
//根据发送的posId获取位置列表
//根据发送的posId获取位置列表
...
...
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean_Partial.cs
查看文件 @
41b47a4
...
@@ -69,20 +69,21 @@ namespace OnlineStore.DeviceLibrary
...
@@ -69,20 +69,21 @@ namespace OnlineStore.DeviceLibrary
p
.
Middle_P2
=
position
.
MiddleAxis_Position_P2
;
p
.
Middle_P2
=
position
.
MiddleAxis_Position_P2
;
p
.
UpDown_P3
=
position
.
UpDownAxis_IHPosition_P3
;
p
.
UpDown_P3
=
position
.
UpDownAxis_IHPosition_P3
;
p
.
UpDown_P4
=
position
.
UpDownAxis_ILPosition_P4
;
p
.
UpDown_P4
=
position
.
UpDownAxis_ILPosition_P4
;
p
.
UpDown_P5
=
position
.
UpDownAxis_O
H
Position_P5
;
p
.
UpDown_P5
=
position
.
UpDownAxis_O
L
Position_P5
;
p
.
UpDown_P6
=
position
.
UpDownAxis_O
L
Position_P6
;
p
.
UpDown_P6
=
position
.
UpDownAxis_O
H
Position_P6
;
param
.
MoveP
=
p
;
param
.
MoveP
=
p
;
if
(
String
.
IsNullOrEmpty
(
param
.
PosInfo
.
PlateH
)
)
if
(
param
.
PosInfo
.
PlateH
<=
0
)
{
{
param
.
PosInfo
.
PlateH
=
position
.
BagHigh
.
ToString
()
;
param
.
PosInfo
.
PlateH
=
position
.
BagHigh
;
}
}
if
(
string
.
IsNullOrEmpty
(
param
.
PosInfo
.
PlateW
)
)
if
(
param
.
PosInfo
.
PlateW
<=
0
)
{
{
param
.
PosInfo
.
PlateW
=
position
.
BagWidth
.
ToString
()
;
param
.
PosInfo
.
PlateW
=
position
.
BagWidth
;
}
}
return
true
;
return
true
;
}
else
if
(
String
.
IsNullOrEmpty
(
param
.
PosInfo
.
PlateH
)||
string
.
IsNullOrEmpty
(
param
.
PosInfo
.
PlateW
))
}
else
if
((
param
.
PosInfo
.
PlateH
<=
0
)
||
(
param
.
PosInfo
.
PlateW
<=
0
))
{
{
ACStorePosition
position
=
param
.
GetACPosition
();
ACStorePosition
position
=
param
.
GetACPosition
();
if
(
position
==
null
)
if
(
position
==
null
)
...
@@ -90,13 +91,13 @@ namespace OnlineStore.DeviceLibrary
...
@@ -90,13 +91,13 @@ namespace OnlineStore.DeviceLibrary
LogUtil
.
error
(
LOGGER
,
StoreName
+
"出入库时发现param中取到的Position=null,没有库位不能执行出入库"
);
LogUtil
.
error
(
LOGGER
,
StoreName
+
"出入库时发现param中取到的Position=null,没有库位不能执行出入库"
);
return
false
;
return
false
;
}
}
if
(
String
.
IsNullOrEmpty
(
param
.
PosInfo
.
PlateH
)
)
if
(
param
.
PosInfo
.
PlateH
<=
0
)
{
{
param
.
PosInfo
.
PlateH
=
position
.
BagHigh
.
ToString
()
;
param
.
PosInfo
.
PlateH
=
position
.
BagHigh
;
}
}
if
(
string
.
IsNullOrEmpty
(
param
.
PosInfo
.
PlateW
)
)
if
(
param
.
PosInfo
.
PlateW
<=
0
)
{
{
param
.
PosInfo
.
PlateW
=
position
.
BagWidth
.
ToString
()
;
param
.
PosInfo
.
PlateW
=
position
.
BagWidth
;
}
}
return
true
;
return
true
;
}
}
...
@@ -168,20 +169,20 @@ namespace OnlineStore.DeviceLibrary
...
@@ -168,20 +169,20 @@ namespace OnlineStore.DeviceLibrary
{
{
wait
.
IsEnd
=
IOManager
.
IOValue
(
wait
.
IoType
).
Equals
(
wait
.
IoValue
);
wait
.
IsEnd
=
IOManager
.
IOValue
(
wait
.
IoType
).
Equals
(
wait
.
IoValue
);
int
timeOutMs
=
Config
.
IOSingle_TimerOut
;
int
timeOutMs
=
Config
.
IOSingle_TimerOut
;
if
(
StoreMove
.
MoveStep
.
Equals
(
StoreMoveStep
.
SO_
14
_WaitTake
))
if
(
StoreMove
.
MoveStep
.
Equals
(
StoreMoveStep
.
SO_
27
_WaitTake
))
{
{
timeOutMs
=
650000
;
timeOutMs
=
650000
;
}
}
if
((!
wait
.
IsEnd
)
&&
span
.
TotalMilliseconds
>
timeOutMs
)
if
((!
wait
.
IsEnd
)
&&
span
.
TotalMilliseconds
>
timeOutMs
)
{
{
ConfigIO
io
=
Config
.
getWaitIO
(
wait
.
IoType
);
ConfigIO
io
=
Config
.
getWaitIO
(
wait
.
IoType
);
WarnMsg
=
StoreName
+
"
等待信号"
+
io
.
DisplayStr
+
"="
+
wait
.
IoValue
+
"超时!
"
;
WarnMsg
=
StoreName
+
"
["
+
StoreMove
.
MoveType
+
"]["
+
StoreMove
.
MoveStep
+
"] 等待"
+
io
.
DisplayStr
+
"="
+
wait
.
IoValue
+
"超时
"
;
Alarm
(
StoreAlarmType
.
IoSingleTimeOut
,
io
.
ElectricalDefinition
,
WarnMsg
,
StoreMove
.
MoveType
);
Alarm
(
StoreAlarmType
.
IoSingleTimeOut
,
io
.
ElectricalDefinition
,
WarnMsg
,
StoreMove
.
MoveType
);
LogUtil
.
error
(
LOGGER
,
StoreName
+
wait
.
IoType
+
"等待信号("
+
io
.
DisplayStr
+
"="
+
wait
.
IoValue
+
") 超时"
,
14
);
LogUtil
.
error
(
LOGGER
,
StoreName
+
wait
.
IoType
+
"等待信号("
+
io
.
DisplayStr
+
"="
+
wait
.
IoValue
+
") 超时"
,
14
);
isOk
=
false
;
isOk
=
false
;
break
;
break
;
}
}
else
if
((!
wait
.
IsEnd
)
&&
StoreMove
.
MoveStep
.
Equals
(
StoreMoveStep
.
SO_
14
_WaitTake
)
&&
LineConnect
.
CanReSend
())
else
if
((!
wait
.
IsEnd
)
&&
StoreMove
.
MoveStep
.
Equals
(
StoreMoveStep
.
SO_
27
_WaitTake
)
&&
LineConnect
.
CanReSend
())
{
{
//判断是否需要重发入库结束命令
//判断是否需要重发入库结束命令
SendOutStoreEnd
(
StoreMove
);
SendOutStoreEnd
(
StoreMove
);
...
@@ -245,7 +246,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -245,7 +246,7 @@ namespace OnlineStore.DeviceLibrary
}
}
else
if
(
span
.
TotalSeconds
>
StoreMove
.
TimeOutSeconds
)
else
if
(
span
.
TotalSeconds
>
StoreMove
.
TimeOutSeconds
)
{
{
WarnMsg
=
StoreName
+
"
【"
+
StoreMove
.
MoveType
+
"】【"
+
StoreMove
.
MoveStep
+
"】
等待超时 ["
+
NotOkMsg
WarnMsg
=
StoreName
+
"
["
+
StoreMove
.
MoveType
+
"]["
+
StoreMove
.
MoveStep
+
"]
等待超时 ["
+
NotOkMsg
+
"]已等待["
+
Math
.
Round
(
span
.
TotalSeconds
,
1
)
+
"]秒"
;
+
"]已等待["
+
Math
.
Round
(
span
.
TotalSeconds
,
1
)
+
"]秒"
;
LogUtil
.
error
(
LOGGER
,
WarnMsg
,
100
);
LogUtil
.
error
(
LOGGER
,
WarnMsg
,
100
);
Alarm
(
StoreAlarmType
.
IoSingleTimeOut
,
""
,
WarnMsg
,
StoreMove
.
MoveType
);
Alarm
(
StoreAlarmType
.
IoSingleTimeOut
,
""
,
WarnMsg
,
StoreMove
.
MoveType
);
...
@@ -262,8 +263,9 @@ namespace OnlineStore.DeviceLibrary
...
@@ -262,8 +263,9 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// 开始入库移动移动
/// 开始入库移动移动
/// </summary>
/// </summary>
public
void
StartInStoreMove
(
InOutParam
param
,
bool
isNeedCheckIO
)
public
override
void
StartInStoreMove
(
InOutParam
param
)
{
{
bool
isNeedCheckIO
=
true
;
startInStoreTime
=
DateTime
.
Now
;
startInStoreTime
=
DateTime
.
Now
;
string
posId
=
param
!=
null
?
param
.
PosInfo
.
PosId
:
""
;
string
posId
=
param
!=
null
?
param
.
PosInfo
.
PosId
:
""
;
if
(
storeRunStatus
==
StoreRunStatus
.
Runing
)
if
(
storeRunStatus
==
StoreRunStatus
.
Runing
)
...
@@ -285,22 +287,17 @@ namespace OnlineStore.DeviceLibrary
...
@@ -285,22 +287,17 @@ namespace OnlineStore.DeviceLibrary
if
(
isNeedCheckIO
)
if
(
isNeedCheckIO
)
{
{
//料盘检测
//料盘检测
InStoreLog
(
" 入库:SI_00
检测
料盘信号"
);
InStoreLog
(
" 入库:SI_00
入库等待仓门口
料盘信号"
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SI_00_TrayCheck
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SI_00_TrayCheck
);
StoreMove
.
TimeOutSeconds
=
5
;
// StoreMove.WaitList.Add(WaitResultInfo.WaitTime(5000));
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
TrayCheck_Door
,
IO_VALUE
.
HIGH
));
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
TrayCheck_Door
,
IO_VALUE
.
HIGH
));
// StoreMove.OneWaitCanEndStep = true;
}
}
else
else
{
{
if
(
IsHasCompress_Axis
||
Config
.
IsHasLocationCylinder
.
Equals
(
0
))
SI_02_Move
(
param
.
MoveP
);
{
SI_02_Move
(
param
.
MoveP
);
}
else
{
InStoreLog
(
"入库:SI_01 定位气缸下降"
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SI_01_LocationCylinderDown
);
LocationDownAndWait
();
}
}
}
}
}
else
else
...
@@ -309,13 +306,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -309,13 +306,7 @@ namespace OnlineStore.DeviceLibrary
}
}
}
}
/// <summary>
/// 开始入库移动移动
/// </summary>
public
override
void
StartInStoreMove
(
InOutParam
param
)
{
StartInStoreMove
(
param
,
false
);
}
private
void
SI_02_Move
(
LineMoveP
moveP
)
private
void
SI_02_Move
(
LineMoveP
moveP
)
{
{
InStoreLog
(
"入库:SI_02_ 进出轴(叉子)动作至P1,打开舱门"
);
InStoreLog
(
"入库:SI_02_ 进出轴(叉子)动作至P1,打开舱门"
);
...
@@ -351,17 +342,32 @@ namespace OnlineStore.DeviceLibrary
...
@@ -351,17 +342,32 @@ namespace OnlineStore.DeviceLibrary
{
{
return
;
return
;
}
}
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SI_00_TrayCheck
)
if
(
StoreMove
.
MoveStep
.
Equals
(
StoreMoveStep
.
SI_00_TrayCheck
)
)
{
{
if
(
IsHasCompress_Axis
||
Config
.
IsHasLocationCylinder
.
Equals
(
0
))
//判断是否有料盘信号
if
(
IOManager
.
IOValue
(
IO_Type
.
TrayCheck_Door
).
Equals
(
IO_VALUE
.
HIGH
))
{
{
SI_02_Move
(
moveP
);
SI_02_Move
(
moveP
);
}
}
else
else
{
{
InStoreLog
(
"入库:SI_01 定位气缸下降"
);
InStoreLog
(
" 入库:SI_00 入库等待仓门口料盘信号"
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SI_01_LocationCylinderDown
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SI_00_TrayCheck
);
LocationDownAndWait
();
StoreMove
.
TimeOutSeconds
=
5
;
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
TrayCheck_Door
,
IO_VALUE
.
HIGH
));
//WarnMsg = StoreName + "入库未检测到料盘[" + StoreMove.MoveParam.PosInfo.barcode + "][" + StoreMove.MoveParam.PosInfo.PosId + "]";
//LogUtil.error(LOGGER, WarnMsg, 100);
//Alarm(StoreAlarmType.IoSingleTimeOut, "", WarnMsg, StoreMove.MoveType);
//TimeSpan span = DateTime.Now - startInStoreTime;
//string posId = StoreMove.MoveParam != null ? StoreMove.MoveParam.PosInfo.PosId : "";
//LogUtil.error(StoreName + " [" + StoreMove.MoveParam.PosInfo.ToStr() + "] 入库未检测到料盘,结束入库.[" + FormUtil.GetSpanStr(span) + "]");
//StoreMove.EndMove();
//storeRunStatus = StoreRunStatus.Runing;
////设备连接,入库后,BOX恢复原始状态
//storeStatus = StoreStatus.StoreOnline;
//InOutEndProcess(StoreMoveType.InStore);
}
}
}
}
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SI_01_LocationCylinderDown
)
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SI_01_LocationCylinderDown
)
...
@@ -530,32 +536,22 @@ namespace OnlineStore.DeviceLibrary
...
@@ -530,32 +536,22 @@ namespace OnlineStore.DeviceLibrary
if
(!
LoadParamPosition
(
param
))
if
(!
LoadParamPosition
(
param
))
{
{
LogUtil
.
error
(
LOGGER
,
StoreName
+
" 启动出库【"
+
posId
+
"】出错,找不到库位信息"
);
LogUtil
.
error
(
LOGGER
,
StoreName
+
" 启动出库【"
+
posId
+
"】出错,找不到库位信息"
);
return
false
;
return
false
;
}
}
if
(
IOManager
.
IOValue
(
IO_Type
.
TrayCheck_Fixture
).
Equals
(
IO_VALUE
.
HIGH
))
if
(
IOManager
.
IOValue
(
IO_Type
.
TrayCheck_Fixture
).
Equals
(
IO_VALUE
.
HIGH
))
{
{
LogUtil
.
error
(
LOGGER
,
StoreName
+
" 启动出库【"
+
posId
+
"】出错,叉子料盘检测有料"
);
LogUtil
.
error
(
LOGGER
,
StoreName
+
" 启动出库【"
+
posId
+
"】出错,叉子料盘检测有料"
);
return
false
;
return
false
;
}
}
storeStatus
=
StoreStatus
.
OutStoreExecute
;
storeStatus
=
StoreStatus
.
OutStoreExecute
;
LogUtil
.
info
(
LOGGER
,
StoreName
+
"启动出库【"
+
posId
+
"】 "
,
storeMoveColor
);
LogUtil
.
info
(
LOGGER
,
StoreName
+
"启动出库【"
+
posId
+
"】 "
,
storeMoveColor
);
storeRunStatus
=
StoreRunStatus
.
Busy
;
storeRunStatus
=
StoreRunStatus
.
Busy
;
StoreMove
.
NewMove
(
StoreMoveType
.
OutStore
,
param
);
StoreMove
.
NewMove
(
StoreMoveType
.
OutStore
,
param
);
if
(
IsHasCompress_Axis
||
Config
.
IsHasLocationCylinder
.
Equals
(
0
))
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_02_DeviceBack
);
OutStoreLog
(
"出库:SO_02 叉子先运动到P1 ,打开舱门 开始"
);
//ACAxisMove(Config.InOut_Axis, StoreMove.MoveParam.MoveP.InOut_P1, Config.InOutAxis_P1_Speed);
InOutBackToP1
(
StoreMove
.
MoveParam
.
MoveP
.
InOut_P1
);
//OpenDoorAndWait();
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_02_InoutBack
);
}
OutStoreLog
(
"出库: 进出轴到P1 ,打开舱门 "
);
else
InOutBackToP1
(
StoreMove
.
MoveParam
.
MoveP
.
InOut_P1
);
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_01_LocationCylinderDown
);
OutStoreLog
(
"出库:SO_01 定位气缸下降"
);
LocationDownAndWait
();
}
return
true
;
return
true
;
}
}
else
else
...
@@ -575,38 +571,38 @@ namespace OnlineStore.DeviceLibrary
...
@@ -575,38 +571,38 @@ namespace OnlineStore.DeviceLibrary
{
{
return
;
return
;
}
}
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_01_LocationCylinderDown
)
//
if (StoreMove.MoveStep == StoreMoveStep.SO_01_LocationCylinderDown)
{
//
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_02_DeviceBack
);
//
StoreMove.NextMoveStep(StoreMoveStep.SO_02_DeviceBack);
OutStoreLog
(
"出库:SO_02 叉子先运动到P1 "
);
//
OutStoreLog("出库:SO_02 叉子先运动到P1 ");
InOutBackToP1
(
StoreMove
.
MoveParam
.
MoveP
.
InOut_P1
);
//
InOutBackToP1(StoreMove.MoveParam.MoveP.InOut_P1);
}
//
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_02_Device
Back
)
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_02_Inout
Back
)
{
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_03_ToBagP
osition
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_03_ToBagP
);
OutStoreLog
(
"出库:
SO_03 走到库位,
压紧轴至P3(压紧前点) ,旋转轴至P2(库位点),升降轴至P5(库位出库前点)"
);
OutStoreLog
(
"出库:压紧轴至P3(压紧前点) ,旋转轴至P2(库位点),升降轴至P5(库位出库前点)"
);
ComMoveToPosition
(
moveP
.
ComPress_P3
,
Config
.
CompAxis_P3_Speed
);
ComMoveToPosition
(
moveP
.
ComPress_P3
,
Config
.
CompAxis_P3_Speed
);
ACAxisMove
(
Config
.
Middle_Axis
,
StoreMove
.
MoveParam
.
MoveP
.
Middle_P2
,
Config
.
MiddleAxis_P2_Speed
);
ACAxisMove
(
Config
.
Middle_Axis
,
StoreMove
.
MoveParam
.
MoveP
.
Middle_P2
,
Config
.
MiddleAxis_P2_Speed
);
ACAxisMove
(
Config
.
UpDown_Axis
,
StoreMove
.
MoveParam
.
MoveP
.
UpDown_P5
,
Config
.
UpDownAxis_P5_Speed
);
ACAxisMove
(
Config
.
UpDown_Axis
,
StoreMove
.
MoveParam
.
MoveP
.
UpDown_P5
,
Config
.
UpDownAxis_P5_Speed
);
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_03_ToBagP
osition
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_03_ToBagP
)
{
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_04_
DeviceToBag
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_04_
InoutToP3
);
OutStoreLog
(
"出库:
SO_04 叉子进入库位中, 进出轴至P3(库位取放料点)
"
);
OutStoreLog
(
"出库:
进出轴至P3(库位取放料点) ["
+
moveP
.
InOut_P3
+
"]
"
);
ACAxisMove
(
Config
.
InOut_Axis
,
moveP
.
InOut_P3
,
Config
.
InOutAxis_P3_Speed
);
ACAxisMove
(
Config
.
InOut_Axis
,
moveP
.
InOut_P3
,
Config
.
InOutAxis_P3_Speed
);
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_04_
DeviceToBag
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_04_
InoutToP3
)
{
{
OutStoreLog
(
"出库:
SO_05 拿起物品,
升降轴至P6(库位出料缓冲点),压紧轴至P2(压紧点) "
);
OutStoreLog
(
"出库:升降轴至P6(库位出料缓冲点),压紧轴至P2(压紧点) "
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_05_
BagWareToDevic
e
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_05_
GetWar
e
);
ComMoveToPosition
(
moveP
.
ComPress_P2
,
Config
.
CompAxis_P2_Speed
);
ComMoveToPosition
(
moveP
.
ComPress_P2
,
Config
.
CompAxis_P2_Speed
);
ACAxisMove
(
Config
.
UpDown_Axis
,
moveP
.
UpDown_P6
,
Config
.
UpDownAxis_P6_Speed
);
ACAxisMove
(
Config
.
UpDown_Axis
,
moveP
.
UpDown_P6
,
Config
.
UpDownAxis_P6_Speed
);
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_05_
BagWareToDevic
e
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_05_
GetWar
e
)
{
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_06_
BagDeviceBack
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_06_
InoutToP1
);
OutStoreLog
(
"出库:
SO_06 叉子从库位返回,
进出轴至P1(待机点) "
);
OutStoreLog
(
"出库:进出轴至P1(待机点) "
);
//ACAxisMove(Config.InOut_Axis, moveP.InOut_P1, Config.InOutAxis_P1_Speed);
//ACAxisMove(Config.InOut_Axis, moveP.InOut_P1, Config.InOutAxis_P1_Speed);
InOutBackToP1
(
moveP
.
InOut_P1
);
InOutBackToP1
(
moveP
.
InOut_P1
);
//把库位的物品放到取到叉子上之后是出仓完成
//把库位的物品放到取到叉子上之后是出仓完成
...
@@ -616,7 +612,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -616,7 +612,7 @@ namespace OnlineStore.DeviceLibrary
storeStatus
=
StoreStatus
.
OutStoreBoxEnd
;
storeStatus
=
StoreStatus
.
OutStoreBoxEnd
;
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_06_
BagDeviceBack
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_06_
InoutToP1
)
{
{
if
(
IOManager
.
IOValue
(
IO_Type
.
TrayCheck_Fixture
).
Equals
(
IO_VALUE
.
LOW
))
if
(
IOManager
.
IOValue
(
IO_Type
.
TrayCheck_Fixture
).
Equals
(
IO_VALUE
.
LOW
))
{
{
...
@@ -624,86 +620,93 @@ namespace OnlineStore.DeviceLibrary
...
@@ -624,86 +620,93 @@ namespace OnlineStore.DeviceLibrary
CodeMsg
=
"出库["
+
posId
+
"]叉子从库位退出后,未检测到料盘有料"
;
CodeMsg
=
"出库["
+
posId
+
"]叉子从库位退出后,未检测到料盘有料"
;
LogUtil
.
error
(
CodeMsg
);
LogUtil
.
error
(
CodeMsg
);
}
}
if
(
IsHasCompress_Axis
||
Config
.
IsHasLocationCylinder
.
Equals
(
0
)
)
if
(
StoreMove
.
MoveParam
.
LoadLocationP
()
)
{
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_08_ToDoorPosition
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SOL_11_MoveToBag
);
OutStoreLog
(
"出库:SO_08 走到料门口,旋转轴至P1(待机点)升降轴至P2(进料口出料前点),打开舱门 "
);
OutStoreLog
(
"出库定位:旋转轴 至P2( 库位点)升降轴到P3(库位入库前点) "
);
ACAxisMove
(
Config
.
UpDown_Axis
,
moveP
.
UpDown_P2
,
Config
.
UpDownAxis_P2_Speed
);
ACAxisMove
(
Config
.
Middle_Axis
,
moveP
.
Middle_P1
,
Config
.
MiddleAxis_P1_Speed
);
ACAxisMove
(
Config
.
Middle_Axis
,
StoreMove
.
MoveParam
.
LocationPos
.
MiddleAxis_Position_P2
,
Config
.
MiddleAxis_P2_Speed
);
//打开舱门
ACAxisMove
(
Config
.
UpDown_Axis
,
StoreMove
.
MoveParam
.
LocationPos
.
UpDownAxis_IHPosition_P3
,
Config
.
UpDownAxis_P3_Speed
);
//OpenDoorAndWait();
}
}
else
else
{
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_07_LocationCylinder_Up
);
SO_21_ToDoorP
();
OutStoreLog
(
"出库:SO_07 定位气缸伸出 "
);
LocationUpAndWait
();
}
}
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_07_LocationCylinder_Up
)
#
region
出库定位动作
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SOL_11_MoveToBag
)
{
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_08_ToDoorPosition
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SOL_12_InoutToP3
);
OutStoreLog
(
"出库:SO_08 走到料门口,旋转轴至P1(待机点)升降轴至P2(进料口出料前点) "
);
int
p
=
StoreMove
.
MoveParam
.
LocationPos
.
InOutAxis_Position_P3
;
ACAxisMove
(
Config
.
UpDown_Axis
,
moveP
.
UpDown_P2
,
Config
.
UpDownAxis_P2_Speed
);
OutStoreLog
(
"出库定位:进出轴到P3(库位取放料点)["
+
p
+
"] "
);
ACAxisMove
(
Config
.
Middle_Axis
,
moveP
.
Middle_P1
,
Config
.
MiddleAxis_P1_Speed
);
ACAxisMove
(
Config
.
InOut_Axis
,
p
,
Config
.
InOutAxis_P3_Speed
);
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO
_08_ToDoorPosition
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO
L_12_InoutToP3
)
{
{
if
(
IsHasCompress_Axis
||
Config
.
IsHasLocationCylinder
.
Equals
(
0
))
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SOL_13_ComToP3
);
{
OutStoreLog
(
"出库定位:压紧轴到P3( 压紧前点) "
);
//SO_10_DeviceToDoorPro();
ACAxisMove
(
Config
.
Comp_Axis
,
StoreMove
.
MoveParam
.
LocationPos
.
CompressAxis_CPosition_P3
,
Config
.
CompAxis_P3_Speed
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_091_WaitNoTray
);
}
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
TrayCheck_Door
,
IO_VALUE
.
LOW
));
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SOL_13_ComToP3
)
// StoreMove.WaitList.Add(WaitResultInfo.WaitHeight(0));
{
OpenDoor
();
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SOL_14_UpdownToP4
);
OutStoreLog
(
"出库定位:放下物品,升降轴到P4( 库位入料缓冲点) "
);
}
ACAxisMove
(
Config
.
UpDown_Axis
,
StoreMove
.
MoveParam
.
LocationPos
.
UpDownAxis_ILPosition_P4
,
Config
.
UpDownAxis_P4_Speed
);
else
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_09_LocationCylinder_Down
);
OutStoreLog
(
"出库:SO_09 定位气缸退回,定位气缸退回 "
);
LocationDownAndWait
();
}
}
}
//此处需要等待移栽没有工作,才能把盘放入出料口
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SOL_14_UpdownToP4
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_09_LocationCylinder_Down
)
{
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_091_WaitNoTray
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SOL_15_GetWare
);
OutStoreLog
(
"出库:SO_091 打开仓门,等待门口无料盘 "
);
OutStoreLog
(
"出库定位:拿物品,升降轴到P6( 库位出料缓冲点),压紧轴到P2(压紧点) "
);
ACAxisMove
(
Config
.
UpDown_Axis
,
StoreMove
.
MoveParam
.
LocationPos
.
UpDownAxis_OHPosition_P6
,
Config
.
UpDownAxis_P6_Speed
);
ACAxisMove
(
Config
.
Comp_Axis
,
StoreMove
.
MoveParam
.
MoveP
.
ComPress_P2
,
Config
.
CompAxis_P2_Speed
);
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SOL_15_GetWare
)
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SOL_16_InoutToP1
);
OutStoreLog
(
"出库定位: 进出轴到P1( 待机点) "
);
ACAxisMove
(
Config
.
InOut_Axis
,
Config
.
InOutAxis_P1_Position
,
Config
.
InOutAxis_P1_Speed
);
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SOL_16_InoutToP1
)
{
SO_21_ToDoorP
();
}
#
endregion
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_21_ToDoorP
)
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_22_WaitNoTray
);
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
TrayCheck_Door
,
IO_VALUE
.
LOW
));
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
TrayCheck_Door
,
IO_VALUE
.
LOW
));
// StoreMove.WaitList.Add(WaitResultInfo.WaitHeight(0));
OpenDoor
();
OpenDoor
();
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
091
_WaitNoTray
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
22
_WaitNoTray
)
{
{
SO_
10_DeviceToDoorPro
();
SO_
53_InoutToP2
();
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
10_DeviceToDoor
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
23_InoutToP2
)
{
{
OutStoreLog
(
"出库:
SO_11 放下物品,
升降轴至P8(进料口出料缓冲点) "
);
OutStoreLog
(
"出库:升降轴至P8(进料口出料缓冲点) "
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
11_Device
PutWare
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
24_
PutWare
);
//NeedCheckSafetyLight = 0;
//NeedCheckSafetyLight = 0;
ComMoveToPosition
(
moveP
.
ComPress_P1
,
Config
.
CompAxis_P1_Speed
);
ComMoveToPosition
(
moveP
.
ComPress_P1
,
Config
.
CompAxis_P1_Speed
);
ACAxisMove
(
Config
.
UpDown_Axis
,
moveP
.
UpDown_P8
,
Config
.
UpDownAxis_P8_Speed
);
ACAxisMove
(
Config
.
UpDown_Axis
,
moveP
.
UpDown_P8
,
Config
.
UpDownAxis_P8_Speed
);
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
11_Device
PutWare
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
24_
PutWare
)
{
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
12_DeviceOutFromDoor
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
25_InoutToP1
);
OutStoreLog
(
"出库:
SO_12 叉子从出料口返回,,
进出轴动作至P1(待机点) "
);
OutStoreLog
(
"出库:进出轴动作至P1(待机点) "
);
InOutBackToP1
(
moveP
.
InOut_P1
);
InOutBackToP1
(
moveP
.
InOut_P1
);
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
12_DeviceOutFromDoor
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
25_InoutToP1
)
{
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
13
_GoBack
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
26
_GoBack
);
OutStoreLog
(
"出库:
SO_13 升降轴返回,
轴2至P1(待机点) ,关闭舱门"
);
OutStoreLog
(
"出库:轴2至P1(待机点) ,关闭舱门"
);
ACAxisMove
(
Config
.
UpDown_Axis
,
moveP
.
UpDown_P1
,
Config
.
UpDownAxis_P1_Speed
);
ACAxisMove
(
Config
.
UpDown_Axis
,
moveP
.
UpDown_P1
,
Config
.
UpDownAxis_P1_Speed
);
CloseDoor
();
CloseDoor
();
//发送消息给流水线
//发送消息给流水线
SendOutStoreEnd
(
StoreMove
);
SendOutStoreEnd
(
StoreMove
);
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
13
_GoBack
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
26
_GoBack
)
{
{
int
OutStoreWaitSeconds
=
ConfigAppSettings
.
GetIntValue
(
Setting_Init
.
OutStoreWaitSeconds
);
int
OutStoreWaitSeconds
=
ConfigAppSettings
.
GetIntValue
(
Setting_Init
.
OutStoreWaitSeconds
);
if
(
OutStoreWaitSeconds
<=
0
)
if
(
OutStoreWaitSeconds
<=
0
)
...
@@ -711,14 +714,14 @@ namespace OnlineStore.DeviceLibrary
...
@@ -711,14 +714,14 @@ namespace OnlineStore.DeviceLibrary
OutStoreWaitSeconds
=
600
;
OutStoreWaitSeconds
=
600
;
}
}
int
ms
=
OutStoreWaitSeconds
*
1000
;
int
ms
=
OutStoreWaitSeconds
*
1000
;
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
14
_WaitTake
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
27
_WaitTake
);
OutStoreLog
(
"出库:
SO_14_WaitTake
等待拿走物品,最多等待"
+
OutStoreWaitSeconds
+
"秒"
);
OutStoreLog
(
"出库: 等待拿走物品,最多等待"
+
OutStoreWaitSeconds
+
"秒"
);
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
ms
));
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
ms
));
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
TrayCheck_Door
,
IO_VALUE
.
LOW
));
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
TrayCheck_Door
,
IO_VALUE
.
LOW
));
// StoreMove.WaitList.Add(WaitResultInfo.WaitHeight(0));
// StoreMove.WaitList.Add(WaitResultInfo.WaitHeight(0));
StoreMove
.
OneWaitCanEndStep
=
true
;
StoreMove
.
OneWaitCanEndStep
=
true
;
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
14
_WaitTake
)
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_
27
_WaitTake
)
{
{
TimeSpan
span
=
DateTime
.
Now
-
startOutStoreTime
;
TimeSpan
span
=
DateTime
.
Now
-
startOutStoreTime
;
string
posId
=
StoreMove
.
MoveParam
!=
null
?
StoreMove
.
MoveParam
.
PosInfo
.
PosId
:
""
;
string
posId
=
StoreMove
.
MoveParam
!=
null
?
StoreMove
.
MoveParam
.
PosInfo
.
PosId
:
""
;
...
@@ -735,7 +738,14 @@ namespace OnlineStore.DeviceLibrary
...
@@ -735,7 +738,14 @@ namespace OnlineStore.DeviceLibrary
}
}
}
}
private
void
SO_21_ToDoorP
()
{
LineMoveP
moveP
=
StoreMove
.
MoveParam
.
MoveP
;
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_21_ToDoorP
);
OutStoreLog
(
"出库:旋转轴至P1(待机点)升降轴至P2(进料口出料前点),打开舱门 "
);
ACAxisMove
(
Config
.
UpDown_Axis
,
moveP
.
UpDown_P2
,
Config
.
UpDownAxis_P2_Speed
);
ACAxisMove
(
Config
.
Middle_Axis
,
moveP
.
Middle_P1
,
Config
.
MiddleAxis_P1_Speed
);
}
private
void
SendOutStoreEnd
(
StoreMoveInfo
storeMove
)
private
void
SendOutStoreEnd
(
StoreMoveInfo
storeMove
)
{
{
int
hasTray
=
(
int
)
IOManager
.
IOValue
(
IO_Type
.
TrayCheck_Door
);
int
hasTray
=
(
int
)
IOManager
.
IOValue
(
IO_Type
.
TrayCheck_Door
);
...
@@ -746,8 +756,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -746,8 +756,8 @@ namespace OnlineStore.DeviceLibrary
}
}
StoreSendBean
store
=
new
StoreSendBean
(
Config
.
Id
,
Config
.
CID
,
(
int
)
storeStatus
,
(
int
)
storeRunStatus
,
hasTray
,
(
int
)
alarmType
);
StoreSendBean
store
=
new
StoreSendBean
(
Config
.
Id
,
Config
.
CID
,
(
int
)
storeStatus
,
(
int
)
storeRunStatus
,
hasTray
,
(
int
)
alarmType
);
store
.
data
.
Add
(
ParamDefine
.
posId
,
StoreMove
.
MoveParam
.
PosInfo
.
PosId
);
store
.
data
.
Add
(
ParamDefine
.
posId
,
StoreMove
.
MoveParam
.
PosInfo
.
PosId
);
store
.
data
.
Add
(
ParamDefine
.
plateH
,
StoreMove
.
MoveParam
.
PosInfo
.
PlateH
);
store
.
data
.
Add
(
ParamDefine
.
plateH
,
StoreMove
.
MoveParam
.
PosInfo
.
PlateH
.
ToString
()
);
store
.
data
.
Add
(
ParamDefine
.
plateW
,
StoreMove
.
MoveParam
.
PosInfo
.
PlateW
);
store
.
data
.
Add
(
ParamDefine
.
plateW
,
StoreMove
.
MoveParam
.
PosInfo
.
PlateW
.
ToString
()
);
store
.
data
.
Add
(
ParamDefine
.
cutReel
,
StoreMove
.
MoveParam
.
PosInfo
.
cutReel
.
ToString
());
store
.
data
.
Add
(
ParamDefine
.
cutReel
,
StoreMove
.
MoveParam
.
PosInfo
.
cutReel
.
ToString
());
store
.
data
.
Add
(
ParamDefine
.
smallReel
,
StoreMove
.
MoveParam
.
PosInfo
.
smallReel
.
ToString
());
store
.
data
.
Add
(
ParamDefine
.
smallReel
,
StoreMove
.
MoveParam
.
PosInfo
.
smallReel
.
ToString
());
store
.
data
.
Add
(
ParamDefine
.
urgentReel
,
StoreMove
.
MoveParam
.
PosInfo
.
urgentReel
.
ToString
());
store
.
data
.
Add
(
ParamDefine
.
urgentReel
,
StoreMove
.
MoveParam
.
PosInfo
.
urgentReel
.
ToString
());
...
@@ -764,21 +774,21 @@ namespace OnlineStore.DeviceLibrary
...
@@ -764,21 +774,21 @@ namespace OnlineStore.DeviceLibrary
LineConnect
.
OutStoreEnd
(
store
);
LineConnect
.
OutStoreEnd
(
store
);
}
}
private
void
SO_
10_DeviceToDoorPro
()
private
void
SO_
53_InoutToP2
()
{
{
if
(
DoorIsOpen
())
if
(
DoorIsOpen
())
{
{
//判断仓门是否打开
//判断仓门是否打开
LineMoveP
moveP
=
StoreMove
.
MoveParam
.
MoveP
;
LineMoveP
moveP
=
StoreMove
.
MoveParam
.
MoveP
;
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
10_DeviceToDoor
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
23_InoutToP2
);
OutStoreLog
(
"出库:
SO_10 叉子进出料口,
进出轴至P2(进料口取料点) "
);
OutStoreLog
(
"出库:进出轴至P2(进料口取料点) "
);
ACAxisMove
(
Config
.
InOut_Axis
,
moveP
.
InOut_P2
,
Config
.
InOutAxis_P2_Speed
);
ACAxisMove
(
Config
.
InOut_Axis
,
moveP
.
InOut_P2
,
Config
.
InOutAxis_P2_Speed
);
//NeedCheckSafetyLight = 1;
//NeedCheckSafetyLight = 1;
}
}
else
else
{
{
InStoreLog
(
"出库:SO_09 叉子即将取料,发现门未上升到位,重新打开门 "
);
InStoreLog
(
"出库:SO_09 叉子即将取料,发现门未上升到位,重新打开门 "
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
091
_WaitNoTray
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_
22
_WaitNoTray
);
OpenDoor
();
OpenDoor
();
}
}
...
@@ -950,8 +960,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -950,8 +960,8 @@ namespace OnlineStore.DeviceLibrary
}
}
private
void
OutStoreLog
(
string
msg
)
private
void
OutStoreLog
(
string
msg
)
{
{
string
posId
=
StoreMove
.
MoveParam
!=
null
?
StoreMove
.
MoveParam
.
PosInfo
.
PosId
:
"
"
;
string
posId
=
StoreMove
.
MoveParam
!=
null
?
"【"
+
StoreMove
.
MoveParam
.
PosInfo
.
PosId
+
"】"
:
"
"
;
LogUtil
.
info
(
LOGGER
,
"【"
+
posId
+
"】
"
+
msg
,
storeMoveColor
);
LogUtil
.
info
(
LOGGER
,
posId
+
StoreMove
.
MoveStep
+
"
"
+
msg
,
storeMoveColor
);
}
}
}
}
}
}
source/DeviceLibrary/acSingleStore/StoreManager.cs
查看文件 @
41b47a4
...
@@ -98,6 +98,15 @@ namespace OnlineStore.DeviceLibrary
...
@@ -98,6 +98,15 @@ namespace OnlineStore.DeviceLibrary
return
Store
;
return
Store
;
}
}
/// <summary>
/// <summary>
/// 获取定位库位信息
/// </summary>
public
static
string
GetLocationPosId
(
int
width
)
{
string
config
=
ConfigAppSettings
.
GetValue
(
Setting_Init
.
Location_PosID_
+
width
);
return
config
;
}
/// <summary>
/// 修改了料仓配置,更新缓存,更新配置文件(只能更新PRO的配置)
/// 修改了料仓配置,更新缓存,更新配置文件(只能更新PRO的配置)
/// </summary>
/// </summary>
/// <param name="kTK_LA_Store_Config"></param>
/// <param name="kTK_LA_Store_Config"></param>
...
...
source/DeviceLibrary/lineConnect/LineConnect.cs
查看文件 @
41b47a4
...
@@ -194,8 +194,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -194,8 +194,8 @@ namespace OnlineStore.DeviceLibrary
public
string
Cmd
=
""
;
public
string
Cmd
=
""
;
public
int
CanOutStore
=
0
;
public
int
CanOutStore
=
0
;
public
string
PosId
=
""
;
public
string
PosId
=
""
;
public
string
PlateH
=
"0"
;
public
int
PlateH
=
0
;
public
string
PlateW
=
"0"
;
public
int
PlateW
=
0
;
public
string
WareCode
=
""
;
public
string
WareCode
=
""
;
public
int
IsDebug
=
0
;
public
int
IsDebug
=
0
;
public
string
rfid
=
""
;
public
string
rfid
=
""
;
...
...
source/DeviceLibrary/store/InOutParam.cs
查看文件 @
41b47a4
...
@@ -49,14 +49,38 @@ namespace OnlineStore.DeviceLibrary
...
@@ -49,14 +49,38 @@ namespace OnlineStore.DeviceLibrary
}
}
public
InOutPosInfo
PosInfo
{
get
;
set
;
}
public
InOutPosInfo
PosInfo
{
get
;
set
;
}
public
LineMoveP
MoveP
{
get
;
set
;
}
public
LineMoveP
MoveP
{
get
;
set
;
}
public
ACStorePosition
LocationPos
=
null
;
public
bool
LoadLocationP
()
{
if
(
LocationPos
==
null
)
{
string
posId
=
StoreManager
.
GetLocationPosId
(
PosInfo
.
PlateW
);
if
(!
String
.
IsNullOrEmpty
(
posId
))
{
LocationPos
=
CSVPositionReader
<
ACStorePosition
>.
GetPositon
(
posId
);
}
}
if
(
LocationPos
==
null
)
{
LogUtil
.
info
(
PosInfo
.
ToStr
()
+
" 出库 不需要定位 "
);
return
false
;
}
else
{
LogUtil
.
info
(
PosInfo
.
ToStr
()
+
" 出库前 需要定位【"
+
LocationPos
.
PositionNum
+
"】 "
);
return
true
;
}
}
}
/// <summary>
}
/// <summary>
/// 夹具编码信息(保存夹具检测到的IO数值,和对应的料仓位置)
/// 夹具编码信息(保存夹具检测到的IO数值,和对应的料仓位置)
/// </summary>
/// </summary>
public
class
InOutPosInfo
public
class
InOutPosInfo
{
{
public
InOutPosInfo
(
string
barcode
,
string
posId
,
string
platew
=
""
,
string
plateh
=
""
,
bool
urgentReel
=
false
,
bool
cutReel
=
false
,
bool
smallReel
=
false
,
string
rfid
=
""
,
int
rfidLoc
=
0
)
public
InOutPosInfo
(
string
barcode
,
string
posId
,
int
platew
=
0
,
int
plateh
=
0
,
bool
urgentReel
=
false
,
bool
cutReel
=
false
,
bool
smallReel
=
false
,
string
rfid
=
""
,
int
rfidLoc
=
0
)
{
{
this
.
barcode
=
barcode
;
this
.
barcode
=
barcode
;
this
.
PosId
=
posId
;
this
.
PosId
=
posId
;
...
@@ -80,11 +104,11 @@ namespace OnlineStore.DeviceLibrary
...
@@ -80,11 +104,11 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// 料盘宽
/// 料盘宽
/// </summary>
/// </summary>
public
string
PlateW
{
get
;
set
;
}
public
int
PlateW
{
get
;
set
;
}
/// <summary>
/// <summary>
/// 料盘高
/// 料盘高
/// </summary>
/// </summary>
public
string
PlateH
{
get
;
set
;
}
public
int
PlateH
{
get
;
set
;
}
/// <summary>
/// <summary>
/// urgentReel: true 表示紧急料,需要出到料串上
/// urgentReel: true 表示紧急料,需要出到料串上
...
@@ -112,9 +136,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -112,9 +136,8 @@ namespace OnlineStore.DeviceLibrary
public
int
rfidLoc
{
get
;
set
;
}
public
int
rfidLoc
{
get
;
set
;
}
public
string
ToStr
()
public
string
ToStr
()
{
{
return
"
barcode["
+
barcode
+
"],PosId ["
+
PosId
+
"],plateW ["
+
PlateW
+
"],plateH ["
+
PlateH
+
"],
urgentReel ["
+
urgentReel
return
"
["
+
barcode
+
"] ["
+
PosId
+
"] ["
+
PlateW
+
"x"
+
PlateH
+
"],
urgentReel ["
+
urgentReel
+
"],cutReel ["
+
cutReel
+
"],smallReel ["
+
smallReel
+
"],rfid ["
+
rfid
+
"],rfidLoc ["
+
rfidLoc
+
"]"
;
+
"],cutReel ["
+
cutReel
+
"],smallReel ["
+
smallReel
+
"],rfid ["
+
rfid
+
"],rfidLoc ["
+
rfidLoc
+
"]"
;
}
}
}
}
}
}
source/DeviceLibrary/store/KTK_Store.cs
查看文件 @
41b47a4
...
@@ -465,7 +465,17 @@ namespace OnlineStore.DeviceLibrary
...
@@ -465,7 +465,17 @@ namespace OnlineStore.DeviceLibrary
}
}
if
(!
aa
.
Equals
(
""
))
if
(!
aa
.
Equals
(
""
))
{
{
return
sta
+
"_"
+
aa
;
string
inout
=
""
;
if
(
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
InStore
)&&
StoreMove
.
MoveParam
!=
null
&&
StoreMove
.
MoveParam
.
PosInfo
!=
null
)
{
inout
=
"_入库:"
+
StoreMove
.
MoveParam
.
PosInfo
.
ToStr
();
}
else
if
(
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
OutStore
)
&&
StoreMove
.
MoveParam
!=
null
&&
StoreMove
.
MoveParam
.
PosInfo
!=
null
)
{
inout
=
"_出库:"
+
StoreMove
.
MoveParam
.
PosInfo
.
ToStr
();
}
return
sta
+
"_"
+
aa
+
inout
;
}
}
else
else
{
{
...
...
source/DeviceLibrary/store/StoreStep.cs
查看文件 @
41b47a4
...
@@ -119,17 +119,17 @@ namespace OnlineStore.DeviceLibrary
...
@@ -119,17 +119,17 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// 料仓原点返回和重置步骤,,定位气缸下降
/// 料仓原点返回和重置步骤,,定位气缸下降
/// </summary>
/// </summary>
BOX_H_LocationCylinderBack
=
010
,
BOX_H_LocationCylinderBack
=
010
,
/// <summary>
/// <summary>
/// 料仓原点返回和重置步骤,轴三先相对走3000
/// 料仓原点返回和重置步骤,轴三先相对走3000
/// </summary>
/// </summary>
BOX_H_InOutMove
=
011
,
BOX_H_InOutMove
=
011
,
/// <summary>
/// <summary>
/// 料仓原点返回和重置步骤,,轴三进出轴先返回原点
/// 料仓原点返回和重置步骤,,轴三进出轴先返回原点
/// </summary>
/// </summary>
BOX_H_InOutBack
=
012
,
BOX_H_InOutBack
=
012
,
/// <summary>
/// <summary>
/// 料仓原点返回和重置步骤,,轴三返回P1点
/// 料仓原点返回和重置步骤,,轴三返回P1点
/// </summary>
/// </summary>
...
@@ -145,12 +145,12 @@ namespace OnlineStore.DeviceLibrary
...
@@ -145,12 +145,12 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// 旋转轴返回P1
/// 旋转轴返回P1
/// </summary>
/// </summary>
BOX_H_MiddleAxisToP1
=
016
,
BOX_H_MiddleAxisToP1
=
016
,
/// <summary>
/// <summary>
/// 叉子先退回P1
/// 叉子先退回P1
/// </summary>
/// </summary>
BOX_M_H_InOutToP1
=
018
,
BOX_M_H_InOutToP1
=
018
,
/// <summary>
/// <summary>
/// 旋转轴回原点
/// 旋转轴回原点
/// </summary>
/// </summary>
...
@@ -175,87 +175,106 @@ namespace OnlineStore.DeviceLibrary
...
@@ -175,87 +175,106 @@ namespace OnlineStore.DeviceLibrary
#
endregion
#
endregion
#
region
料仓内部出库步骤
#
region
料仓
出库步骤
101
-
200
/// <summary>
///料仓出库,,定位气缸下降
/// </summary>
SO_01_LocationCylinderDown
=
101
,
/// <summary>
/// <summary>
///料仓出库:叉子先运动到P1
///料仓出库:叉子先运动到P1
/// </summary>
/// </summary>
SO_02_
Device
Back
=
102
,
SO_02_
Inout
Back
=
102
,
/// <summary>
/// <summary>
/// 料仓出库,,所有轴运行到库位,
轴4( 压紧) 至P3(压紧前点) ,轴1( 转盘) 至P2( 库位点),轴2(上下) 至
P5(库位出库前点)
/// 料仓出库,,所有轴运行到库位,
压紧轴到P3(压紧前点) ,旋转轴到P2( 库位点),升降轴到
P5(库位出库前点)
/// </summary>
/// </summary>
SO_03_ToBagP
osition
=
103
,
SO_03_ToBagP
,
/// <summary>
/// <summary>
/// 料仓出库,,叉子进入库位中,
轴3( 叉子) 至
P3(库位取放料点)
/// 料仓出库,,叉子进入库位中,
进出轴到
P3(库位取放料点)
/// </summary>
/// </summary>
SO_04_
DeviceToBag
=
104
,
SO_04_
InoutToP3
,
/// <summary>
/// <summary>
///料仓出库,, 库位的物品放入叉子上,
轴2( 上下) 至P6( 库位出料缓冲点),轴4( 压紧) 至
P2(压紧点)
///料仓出库,, 库位的物品放入叉子上,
升降轴到P6( 库位出料缓冲点),压紧轴到
P2(压紧点)
/// </summary>
/// </summary>
SO_05_
BagWareToDevice
=
105
,
SO_05_
GetWare
,
/// <summary>
/// <summary>
///料仓出库,,叉子从 库位返回,
轴3( 叉子) 至
P1( 待机点)
///料仓出库,,叉子从 库位返回,
进出轴到
P1( 待机点)
/// </summary>
/// </summary>
SO_06_BagDeviceBack
=
106
,
SO_06_InoutToP1
,
#
region
定位处理:先将料放入定位区,再拿起料到仓门口
/// <summary>
/// <summary>
///
料仓出库,定位气缸伸出(有压紧轴的不需要此步骤),,定位气缸伸出 Y103-1/PCI5O1-83) Y103-2/PCI5O1-90) Y103-3/PCI5O1-95) 伸出到位
///
出库定位:旋转轴 至P2( 库位点)升降轴到P3(库位入库前点)
/// </summary>
/// </summary>
SO
_07_LocationCylinder_Up
=
107
,
SO
L_11_MoveToBag
=
110
,
/// <summary>
/// <summary>
///
料仓出库,,所有设备运行到门,,轴1( 转盘) 至P1( 待机点)轴2( 上下) 至P2( 进料口出料前
点)
///
出库定位:进出轴到P3(库位取放料
点)
/// </summary>
/// </summary>
SO_08_ToDoorPosition
=
108
,
SOL_12_InoutToP3
,
/// <summary>
/// 出库定位: 压紧轴到P3( 压紧前点)
/// </summary>
SOL_13_ComToP3
,
/// <summary>
/// 出库定位:放下物品,升降轴到P4( 库位入料缓冲点)
/// </summary>
SOL_14_UpdownToP4
,
/// <summary>
/// 出库定位:拿物品,升降轴到P6( 库位出料缓冲点),压紧轴到P2(压紧点)
/// </summary>
SOL_15_GetWare
,
/// <summary>
/// 出库定位:叉子从 库位返回,进出轴到P1( 待机点)
/// </summary>
SOL_16_InoutToP1
,
#
endregion
/// <summary>
/// <summary>
/// 料仓出库,
定位气缸退回(有压紧轴的不需要此步骤),,定位气缸退回(Y104-1/PCI5O1-84) (Y104-2/PCI5O1-91) (Y104-2/PCI5O1-96) 退回到位
/// 料仓出库,
,所有设备运行到门,,旋转轴到P1( 待机点)升降轴到P2( 进料口出料前点)
/// </summary>
/// </summary>
SO_
09_LocationCylinder_Down
=
109
,
SO_
21_ToDoorP
=
121
,
/// <summary>
/// <summary>
/// 等待门口无料盘
/// 等待门口无料盘
/// </summary>
/// </summary>
SO_091_WaitNoTray
=
115
,
SO_22_WaitNoTray
,
/// <summary>
/// <summary>
/// 料仓出库,,叉子进出料口,,
轴3( 叉子) 至
P2( 进料口取料点)
/// 料仓出库,,叉子进出料口,,
进出轴到
P2( 进料口取料点)
/// /// </summary>
/// /// </summary>
SO_
10_DeviceToDoor
=
110
,
SO_
23_InoutToP2
,
/// <summary>
/// <summary>
/// 料仓出库,,把物品放下,,
轴2( 上下) 至P8( 进料口出料缓冲点)轴4( 压紧) 至
P1( 待机点)
/// 料仓出库,,把物品放下,,
升降轴到P8( 进料口出料缓冲点)压紧轴到
P1( 待机点)
/// </summary>
/// </summary>
SO_
11_DevicePutWare
=
111
,
SO_
24_PutWare
,
/// <summary>
/// <summary>
/// 料仓出库,,叉子从出料口返回,,轴3( 叉子) 动作至P1( 待机点)
/// 料仓出库,,叉子从出料口返回,,轴3( 叉子) 动作至P1( 待机点)
/// </summary>
/// </summary>
SO_12_DeviceOutFromDoor
=
112
,
SO_25_InoutToP1
,
/// <summary>
/// <summary>
/// 料仓出库,,升降轴返回,, 轴2至P1( 待机点)
/// 料仓出库,,升降轴返回,, 轴2至P1( 待机点)
/// </summary>
/// </summary>
SO_
13_GoBack
=
113
,
SO_
26_GoBack
,
/// <summary>
/// <summary>
/// 等待拿走物品
/// 等待拿走物品
/// </summary>
/// </summary>
SO_
14_WaitTake
=
114
,
SO_
27_WaitTake
,
#
endregion
#
endregion
#
region
料仓
内部入库步骤
#
region
料仓
入库
/// <summary>
/// <summary>
/// 入库检测
/// 入库检测
/// </summary>
/// </summary>
SI_00_TrayCheck
=
200
,
SI_00_TrayCheck
=
200
,
/// <summary>
/// <summary>
/// 入库,。定位气缸下降
/// 入库,。定位气缸下降
/// </summary>
/// </summary>
SI_01_LocationCylinderDown
=
201
,
SI_01_LocationCylinderDown
=
201
,
/// <summary>
/// <summary>
/// 入库。。进出轴(叉子)先返回P1
/// 入库。。进出轴(叉子)先返回P1
/// </summary>
/// </summary>
...
@@ -265,20 +284,20 @@ namespace OnlineStore.DeviceLibrary
...
@@ -265,20 +284,20 @@ namespace OnlineStore.DeviceLibrary
/// </summary>
/// </summary>
SI_03_ReturnHome
=
203
,
SI_03_ReturnHome
=
203
,
/// <summary>
/// <summary>
/// 入库。。压紧物品(有压紧轴的才需要此步骤),
轴4( 压紧) 至
P3(压紧前点)
/// 入库。。压紧物品(有压紧轴的才需要此步骤),
压紧轴到
P3(压紧前点)
/// </summary>
/// </summary>
SI_04_CompressWare
=
204
,
SI_04_CompressWare
=
204
,
/// <summary>
/// <summary>
/// 入库。。叉子进入入料口,
轴3( 叉子) 至
P2( 进料口取料点)
/// 入库。。叉子进入入料口,
进出轴到
P2( 进料口取料点)
/// </summary>
/// </summary>
SI_05_DeviceToDoor
=
205
,
SI_05_DeviceToDoor
=
205
,
/// <summary>
/// <summary>
/// 入库。。把物品放入叉子上,
轴2( 上下) 至P7( 进料口取料缓冲点),压紧物品(有压紧轴的才需要此步骤),轴4( 压紧) 至
P2(压紧点)
/// 入库。。把物品放入叉子上,
升降轴到P7( 进料口取料缓冲点),压紧物品(有压紧轴的才需要此步骤),压紧轴到
P2(压紧点)
/// </summary>
/// </summary>
SI_06_DoorWarToDevice
=
206
,
SI_06_DoorWarToDevice
=
206
,
/// <summary>
/// <summary>
/// 入库。。叉子 从入料口抽出,
轴3( 叉子) 至
P1( 待机点)
/// 入库。。叉子 从入料口抽出,
进出轴到
P1( 待机点)
/// </summary>
/// </summary>
SI_07_DeviceBackFromDoor
=
207
,
SI_07_DeviceBackFromDoor
=
207
,
/// <summary>
/// <summary>
...
@@ -286,7 +305,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -286,7 +305,7 @@ namespace OnlineStore.DeviceLibrary
/// </summary>
/// </summary>
SI_08_LocationCylinder_Up
=
208
,
SI_08_LocationCylinder_Up
=
208
,
/// <summary>
/// <summary>
/// 入库。。移动到库位点,
轴1( 转盘) 至P2( 库位点)轴2(上下) 至
P3(库位入库前点)
/// 入库。。移动到库位点,
旋转轴到P2( 库位点)升降轴到
P3(库位入库前点)
/// </summary>
/// </summary>
SI_09_MoveToBag
=
209
,
SI_09_MoveToBag
=
209
,
/// <summary>
/// <summary>
...
@@ -294,11 +313,11 @@ namespace OnlineStore.DeviceLibrary
...
@@ -294,11 +313,11 @@ namespace OnlineStore.DeviceLibrary
/// </summary>
/// </summary>
SI_10_LocationCylinder_Down
=
210
,
SI_10_LocationCylinder_Down
=
210
,
/// <summary>
/// <summary>
/// 入库。。叉子进入库位中,
轴3( 叉子) 至
P3(库位取放料点)
/// 入库。。叉子进入库位中,
进出轴到
P3(库位取放料点)
/// </summary>
/// </summary>
SI_11_DeviceToBag
=
211
,
SI_11_DeviceToBag
=
211
,
/// <summary>
/// <summary>
/// 入库。。放下物品,
轴2( 上下) 至P4( 库位入料缓冲点)轴4( 压紧) 至
P3( 压紧前点)
/// 入库。。放下物品,
升降轴到P4( 库位入料缓冲点)压紧轴到
P3( 压紧前点)
/// </summary>
/// </summary>
SI_12_PutWareToBag
=
212
,
SI_12_PutWareToBag
=
212
,
/// <summary>
/// <summary>
...
@@ -312,456 +331,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -312,456 +331,8 @@ namespace OnlineStore.DeviceLibrary
#
endregion
#
endregion
#
region
手动料仓出入库步骤
/// <summary>
/// 手动料仓,已经写入开门IO
/// </summary>
M_Begin_OpenDoor
=
1000
,
/// <summary>
/// 手动料仓,已经收到开门信号
/// </summary>
M_End_OpenDoor
=
1001
,
/// <summary>
/// 手动料仓,已经收到关门信号
/// </summary>
M_CloseDoor
=
1002
,
#
endregion
#
region
移栽装置原点返回和重置步骤
/// <summary>
/// 料仓移栽装置,,上下气缸上升端
/// </summary>
H_UpDownCylinder_Up
=
2001
,
/// <summary>
/// 料仓移载装置,其他气缸运行到初始状态( 顶升气缸下降端,前后气缸后退端,夹料气缸放松端,阻挡气缸输入=0 )
/// </summary>
H_OtherCylinder_Back
=
2002
,
#
endregion
#
region
流水线入仓操作
/// <summary>
/// 流水线入仓,开始扫码 扫描枪触发,数据处理
/// </summary>
LI_Scannering
=
10001
,
/// <summary>
/// 流水线入仓,料仓号及库位号发送, 夹具号编码记忆(X5,X6.X7)数据接收
/// </summary>
LI_WaitServerResult
=
10002
,
/// <summary>
/// 等待100毫秒后再放行
/// </summary>
LI_00_Wait100
=
10003
,
/// <summary>
/// 阻挡气缸0-2下降
/// </summary>
LI_01_StopCylinder2Down
=
10004
,
/// <summary>
/// 检测夹具检测1=0 ) 开始
/// </summary>
LI_02_FixtureCheck
=
10005
,
/// <summary>
/// 阻挡气缸0-2上升
/// </summary>
LI_03_StopCylinder2Up
=
10006
,
/// <summary>
/// 阻挡气缸0-1下降
/// </summary>
LI_04_StopCylinder1Down
=
10007
,
#
endregion
#
region
流水线出库操作
/// <summary>
/// 流水线出库,等待100毫秒之后在放行
/// </summary>
LO_00_Wait100
=
11000
,
/// <summary>
/// 流水线出库,阻挡气缸0-2下降
/// </summary>
LO_01_StopCylinder2Down
=
11001
,
/// <summary>
/// 流水线出库, 检测夹具检测1=0
/// </summary>
LO_02_FixtureCheck
=
11002
,
/// <summary>
/// 流水线出库,阻挡气缸0-2上升( Y13=0)
/// </summary>
LO_03_StopCylinder2Up
=
11003
,
/// <summary>
/// 阻挡气缸0-1下降(Y12=1)
/// </summary>
LO_04_StopCylinder1Up
=
11004
,
#
endregion
#
region
移栽装置出入库共同模块
/// <summary>
///移载(流水线)装置出入库处理,, 阻挡气缸1-1下降( Y14=1)
/// </summary>
MIO_01_StopCylinder1Down
=
3081
,
/// <summary>
///移载(流水线)装置出入库处理,,夹具检测1-4=1
/// </summary>
MIO_02_FixtureCheck
=
3082
,
/// <summary>
///移载(流水线)装置出入库处理,,阻挡气缸1-1上升( Y14=0)
/// </summary>
MIO_03_StopCylinder2Down
=
3083
,
/// <summary>
/// 检测夹具检测IO1=1
/// </summary>
MIO_04_Check1High
=
3084
,
/// <summary>
/// 等待一秒钟
/// </summary>
MIO_05_WaitTime
=
3085
,
/// <summary>
///移载(流水线)装置出入库处理,,顶 升 气缸 上 升 (Y17 =0/Y1 16 =1 )检测X17=0X16=1
/// </summary>
MIO_06_TopCylinderUp
=
3086
,
/// <summary>
/// 此处 顶升气缸上升时等待一秒钟,再下降,现在看起来没有升到位就下降
/// </summary>
MIO_07_TopCylinderUpWait
=
3087
,
/// <summary>
/// 等待StoreMove完成当前操作开始入库
/// </summary>
MIO_08_WaitInStore
=
3088
,
/// <summary>
/// 等待StoreMove移走料盘开始放托盘通过
/// </summary>
MIO_09_WaitLetFixtureGo
=
3089
,
#
endregion
#
region
移栽装置出库处理
/// <summary>
/// 移载(流水线)装置出库处理, 检测夹具编码并记忆,托盘 是空盘,并且BOX在出库等待中,开始移栽料盘
/// </summary>
MO_05_CodeRember
=
3105
,
/// <summary>
/// 移载(流水线)装置出库处理,, ,顶升气缸1下降(Y16=0/Y17=1)
/// </summary>
MO_09_TopCylinder_Down
=
3109
,
/// <summary>
/// 移载(流水线)装置出库处理,, 阻挡气缸1-2下降( Y15=1)
/// </summary>
MO_10_StopCylinder2_Down
=
3110
,
/// <summary>
/// 移载(流水线)装置出库处理,, 夹具检测1-4=0,
/// </summary>
MO_11_Tray_Check
=
3111
,
/// <summary>
/// 移载(流水线)装置出库处理,,阻挡气缸1-1下降( Y14=1)阻挡气缸1-2上升( Y15=0)
/// </summary>
MO_12_StopCylinder_Back
=
3112
,
/// <summary>
/// 移栽装置出库处理。。前后气缸1前进
/// </summary>
MO_51_BeforeAfterCylinderBefore
=
3151
,
/// <summary>
/// 移栽装置出库处理。。 上下气缸1下降(Y22=0/Y23=1)
/// </summary>
MO_52_UpDownCylinderDown
=
3152
,
/// <summary>
/// 移栽装置出库处理。。 上下气缸1下降后,等待0.3秒再夹紧,防止没有下降到位就夹紧操作
/// </summary>
MO_53_UpDownCylinderDownWait
=
3153
,
/// <summary>
/// 移栽装置出库处理。 夹料气缸1夹紧( Y25=0/Y24=1)
/// </summary>
MO_54_ClampCylinderSlack
=
3154
,
/// <summary>
/// 移栽装置出库处理。。 上下气缸1上升(Y22=1/Y23=0)
/// </summary>
MO_55_UpDownCylinderUp
=
3155
,
/// <summary>
/// 移栽装置出库处理。。 前后气缸1后退( Y20=0/Y21=1)
/// </summary>
MO_56_BeforeAfterCylinderAfter
=
3156
,
/// <summary>
/// 移载(流水线)装置出库处理,,, 上下气缸1下降(Y22=0/Y23=1)
/// </summary>
MO_58_UpDownCylinderDown
=
3158
,
/// <summary>
/// 移载(流水线)装置出库处理,, 夹料气缸1放松( Y25=1/Y24=0)
/// </summary>
MO_59_ClampCylinderTighten
=
3159
,
/// <summary>
/// 移载(流水线)装置出库处理,, ,上下气缸1上升(Y22=1/Y23=0)
/// </summary>
MO_60_UpDownCylinderUp
=
3160
,
#
endregion
#
region
移载装置入库处理
/// <summary>
///移载装置入库处理,,检测 夹具编码( X1 3,X14,X15)
/// </summary>
MI_05_CodeCheck
=
3005
,
/// <summary>
/// 移载装置入库处理,,等待box等待状态才能继续操作
/// </summary>
MI_10_WaitBox
=
3006
,
/// <summary>
///移载装置入库处理,,编码与仓位一致,,上下气缸1下降(Y22=0/Y23=1)
/// </summary>
MI_07_UpDownCylinderDown
=
3007
,
/// <summary>
///移载装置入库处理,,编码与仓位一致,,上下气缸1下降后,等待0.3秒,防止没有 下降到位就夹紧
/// </summary>
MI_07_UpDownCylinderDownWait
=
3024
,
/// <summary>
///移载装置入库处理,, 夹料气缸1夹紧( Y25=0/Y24=1)
/// </summary>
MI_08_ClampCylinderSlack
=
3008
,
/// <summary>
///移载装置入库处理,, 上下气缸1上升(Y22=1/Y23=0)
/// </summary>
MI_09_UpDownCylinderUp
=
3009
,
/// <summary>
///移载装置入库处理,, ,前后气缸1前进( Y20=1/Y21=0)
/// </summary>
MI_10_BeforeAfterCylinderBefore
=
3010
,
/// <summary>
///移载装置入库处理,, 上下气缸1下降(Y22=0/Y23=1)
/// </summary>
MI_11_UpDownCylinderDown
=
3011
,
/// <summary>
///移载装置入库处理,, ,夹料气缸1放松( Y25=1/Y24=0)
/// </summary>
MI_12_ClampCylinderTighten
=
3012
,
/// <summary>
///移载装置入库处理,, 上下气缸1上升(Y22=1/Y23=0)
/// </summary>
MI_13_UpdownCylinderUp
=
3013
,
/// <summary>
///移载装置入库处理,, ,前后气缸1后退( Y20=0/Y21=1)
/// </summary>
MI_14_BeforeAfterCylinderAfter
=
3014
,
/// <summary>
///移载装置入库处理,, 检测到X102-1=1送料流程完成
/// </summary>
MI_15_SendEnd
=
3015
,
/// <summary>
///移载装置入库处理,,编码不一致,,顶升气缸1下降(Y16=0/Y17=1)
/// </summary>
MI_20_TopCylinderDown
=
3020
,
/// <summary>
///移载装置入库处理,,阻挡气缸1-2下降( Y15=1),
/// </summary>
MI_21_StopCylinderDown
=
3021
,
/// <summary>
///移载装置入库处理,检测Check4=0,
/// </summary>
MI_22_FixtureCheck_Low
=
3022
,
/// <summary>
///移载装置入库处理,,,阻挡气缸1-2 上升( Y15=0),等待200毫秒
/// </summary>
MI_23_StopCylinderReset
=
3023
,
#
endregion
//后面的是双层料仓的类型 值从20000开始
#
region
双层流水线调宽和处理
/// <summary>
/// 双层料仓流水线模块 。检测到板子进入,打开流水线
/// </summary>
LINEIN_OpenLine
=
20000
,
/// <summary>
/// 双层料仓流水线模块 。等待下位机要料信号=High
/// </summary>
LINEIN_WaitOutSingle
=
20001
,
/// <summary>
/// 双层料仓流水线模块 。检测到出料口信号=Low
/// </summary>
LINEIN_WaitOutSingleLow
=
20002
,
/// <summary>
/// 关闭皮带
/// </summary>
LINEIN_CloseLine
=
20003
,
/// <summary>
/// 等待下位机要料信号
/// </summary>
LINEIN_WatiMachineSingle
=
20004
,
/// <summary>
/// 双层料仓流水线模块 。线体调宽回原点
/// </summary>
LINECW_LineReturnHome
=
20010
,
/// <summary>
/// 双层料仓流水线模块 。线体调宽回原点
/// </summary>
LINECW_LineChangeWidth
=
20011
,
/// <summary>
/// 流水线原点返回,设置速度
/// </summary>
LINEH_SetSpeed_001
=
20020
,
/// <summary>
/// 流水线原点返回,反反向走到20000
/// </summary>
LINEH_RevertMove_002
=
20021
,
/// <summary>
/// 流水线原点返回,开始原点返回
/// </summary>
LINEH_LineHome_003
=
20022
,
#
endregion
#
region
在线料仓入库处理
/// <summary>
///在线双层料仓:入仓: 等待料盘进入
/// </summary>
DB_SI_00_WaitIO
=
20100
,
/// <summary>
///在线双层料仓:入仓:扫描二维码中
/// </summary>
DB_SI_01_Scanning
=
20101
,
/// <summary>
/// 在线双层料仓:入仓:根据二维码从服务器获取仓位号
/// </summary>
DB_SI_02_GetBoxNum
=
20102
,
/// <summary>
///在线双层料仓: 同时动作
/// 电缸运行到入料口下方的位置 , 料仓旋转到对应的位置
/// </summary>
DB_SI_03_InStoreReadyMove
=
20103
,
/// <summary>
/// 在线双层料仓:入仓:(取料叉子进入料口)、
/// </summary>
DB_SI_04_TakeDeviceToDoor
=
20104
,
/// <summary>
/// 在线双层料仓:入仓:(电缸稍微移动到料口上端位置),
/// </summary>
DB_SI_05_ModbusUpToDoor
=
20105
,
/// <summary>
///在线双层料仓: 取出料盘
/// </summary>
DB_SI_06_TakeSITray
=
20106
,
/// <summary>
/// 在线双层料仓:入仓(电缸运行到对应仓位的下方,,旋转电机2正转)
/// </summary>
DB_SI_07_MoveToRoom
=
20107
,
/// <summary>
/// 在线双层料仓:入仓(取料叉子进入仓位)
/// </summary>
DB_SI_08_TakeDeviceToRoom
=
20108
,
/// <summary>
///在线双层料仓: 入仓(电缸微动至对应料仓的下端位置)
/// </summary>
DB_SI_09_PutToRoom
=
20109
,
/// <summary>
/// 在线双层料仓:从仓位出来
/// </summary>
DB_SI_10_SIFromRoom
=
20110
,
/// <summary>
///在线双层料仓: 旋转电机2反转,回到中间等待位置
/// </summary>
DB_SI_11_MoveSIFromRoom
=
20111
,
/// <summary>
/// 在线双层料仓:关闭仓门
/// </summary>
DB_SI_12_CloseDoor
=
20112
,
#
endregion
#
region
在线料仓出库处理
/// <summary>
///在线双层料仓:: 出库处理:等待执行出库
/// </summary>
DB_SO_00_WaitStart
=
20200
,
/// <summary>
///在线双层料仓:
/// </summary>
DB_SO_01_Scanning
=
20201
,
/// <summary>
/// 在线双层料仓:
/// </summary>
DB_SO_02_GetBoxNum
=
20202
,
/// <summary>
///在线双层料仓:出库执行 同时动作
/// 电缸运行到入料口下方的位置 ,料仓旋转到对应的位置,旋转电机2正传
/// </summary>
DB_SO_03_ReadyMove
=
20203
,
/// <summary>
/// 在线双层料仓: 出仓:(取料叉子进入料仓)叉子前进
/// </summary>
DB_SO_04_TakeDeviceToDoor
=
20204
,
/// <summary>
/// 在线双层料仓: 出仓:(电缸稍微移动到料仓上端位置)
/// </summary>
DB_SO_05_ModbusUpToDoor
=
20205
,
/// <summary>
///在线双层料仓: 取出料盘,叉子后退
/// </summary>
DB_SO_06_TakeOutTray
=
20206
,
/// <summary>
/// 在线双层料仓: 出库执行(电缸移动至入料口的上端位置 旋转电机2正转)
/// </summary>
DB_SO_07_MoveToRoom
=
20207
,
/// <summary>
/// 在线双层料仓:出库执行 (叉子前进)
/// </summary>
DB_SO_08_TakeDeviceToRoom
=
20208
,
/// <summary>
///在线双层料仓: 出库执行 (电缸微动至对应料口的下端位置)
/// </summary>
DB_SO_09_PutToRoom
=
20209
,
/// <summary>
/// 在线双层料仓:出库执行 叉子后退
/// </summary>
DB_SO_10_OutFromRoom
=
20210
,
/// <summary>
/// 在线双层料仓:等待物料到达
/// </summary>
DB_SO_11_WaitTrayToDoor
=
20211
,
/// <summary>
/// 在线双层料仓:等待拿走料盘
/// </summary>
DB_SO_12_WaitTrayLeave
=
20212
,
///// <summary>
/////在线双层料仓:出库执行 旋转电机2反转,回到中间等待位置
///// </summary>
//DB_SO_11_MoveOutFromRoom = 20211,
///// <summary>
///// 在线双层料仓:出库执行(关闭仓门
///// </summary>
//DB_SO_CloseDoor = 20213,
#
endregion
/// <summary>
/// 在线双层料仓:回原点:叉子退回
/// </summary>
DB_H_01_ForkBack
=
20301
,
/// <summary>
/// 在线双层料仓:回原点:同时动作:转盘低速旋转 , 电缸回到原位 ,( I/O点控制) 旋转气缸旋回
/// </summary>
DB_H_02_BackHome
=
20302
,
/// <summary>
/// 在线双层料仓:回原点:旋回完成
/// </summary>
DB_H_03_BackEnd
=
20303
,
/// <summary>
/// 在线双层料仓:回原点:原点开关点亮,原点开关点亮,旋回端开关点亮,,转盘停止 ,电缸停止, 清理电钢和转盘的位置信息
/// </summary>
DB_H_04_ClearPosition
=
20304
,
}
}
public
enum
StoreAlarmType
public
enum
StoreAlarmType
...
...
source/LoadCVSLibrary/position/ACStorePosition.cs
查看文件 @
41b47a4
...
@@ -24,12 +24,12 @@ namespace OnlineStore.LoadCSVLibrary
...
@@ -24,12 +24,12 @@ namespace OnlineStore.LoadCSVLibrary
/// 升降轴(库位出料前点)P5
/// 升降轴(库位出料前点)P5
/// </summary>
/// </summary>
[
CSVAttribute
(
"升降轴库位出料前点P5"
)]
[
CSVAttribute
(
"升降轴库位出料前点P5"
)]
public
int
UpDownAxis_O
H
Position_P5
{
get
;
set
;
}
public
int
UpDownAxis_O
L
Position_P5
{
get
;
set
;
}
/// <summary>
/// <summary>
/// 升降轴(库位出料缓冲点)P6
/// 升降轴(库位出料缓冲点)P6
/// </summary>
/// </summary>
[
CSVAttribute
(
"升降轴库位出料缓冲点P6"
)]
[
CSVAttribute
(
"升降轴库位出料缓冲点P6"
)]
public
int
UpDownAxis_O
L
Position_P6
{
get
;
set
;
}
public
int
UpDownAxis_O
H
Position_P6
{
get
;
set
;
}
/// <summary>
/// <summary>
/// 升降轴(库位入料前点)P3
/// 升降轴(库位入料前点)P3
/// </summary>
/// </summary>
...
@@ -107,12 +107,12 @@ namespace OnlineStore.LoadCSVLibrary
...
@@ -107,12 +107,12 @@ namespace OnlineStore.LoadCSVLibrary
LogUtil
.
error
(
position
.
PositionNum
+
" UpDownAxis_ILPosition_P4位置超出"
+
Config
.
UpDown_Axis
.
Explain
+
"上下限("
+
uMin
+
"-"
+
uMax
+
")"
);
LogUtil
.
error
(
position
.
PositionNum
+
" UpDownAxis_ILPosition_P4位置超出"
+
Config
.
UpDown_Axis
.
Explain
+
"上下限("
+
uMin
+
"-"
+
uMax
+
")"
);
return
false
;
return
false
;
}
}
if
(
uMin
>
position
.
UpDownAxis_O
HPosition_P5
||
uMax
<
position
.
UpDownAxis_OH
Position_P5
)
if
(
uMin
>
position
.
UpDownAxis_O
LPosition_P5
||
uMax
<
position
.
UpDownAxis_OL
Position_P5
)
{
{
LogUtil
.
error
(
position
.
PositionNum
+
" UpDownAxis_OHPosition_P5位置超出"
+
Config
.
UpDown_Axis
.
Explain
+
"上下限("
+
uMin
+
"-"
+
uMax
+
")"
);
LogUtil
.
error
(
position
.
PositionNum
+
" UpDownAxis_OHPosition_P5位置超出"
+
Config
.
UpDown_Axis
.
Explain
+
"上下限("
+
uMin
+
"-"
+
uMax
+
")"
);
return
false
;
return
false
;
}
}
if
(
uMin
>
position
.
UpDownAxis_O
LPosition_P6
||
uMax
<
position
.
UpDownAxis_OL
Position_P6
)
if
(
uMin
>
position
.
UpDownAxis_O
HPosition_P6
||
uMax
<
position
.
UpDownAxis_OH
Position_P6
)
{
{
LogUtil
.
error
(
position
.
PositionNum
+
" UpDownAxis_OLPosition_P6位置超出"
+
Config
.
UpDown_Axis
.
Explain
+
"上下限("
+
uMin
+
"-"
+
uMax
+
")"
);
LogUtil
.
error
(
position
.
PositionNum
+
" UpDownAxis_OLPosition_P6位置超出"
+
Config
.
UpDown_Axis
.
Explain
+
"上下限("
+
uMin
+
"-"
+
uMax
+
")"
);
return
false
;
return
false
;
...
...
source/LoadCVSLibrary/position/CSVPositionReader.cs
查看文件 @
41b47a4
...
@@ -178,7 +178,7 @@ namespace OnlineStore.LoadCSVLibrary
...
@@ -178,7 +178,7 @@ namespace OnlineStore.LoadCSVLibrary
}
}
else
else
{
{
if
(
array
.
Length
=
=
titleIndex
.
Count
)
if
(
array
.
Length
>
=
titleIndex
.
Count
)
{
{
if
(
csvIndex
<
0
)
if
(
csvIndex
<
0
)
{
{
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论