Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
RC1250-ACPackingStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 3078ab8b
由
LN
编写于
2020-01-13 10:16:30 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
1
1 个父辈
cf79dc62
全部展开
显示空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
15 行增加
和
124 行删除
source/ACPackingStore/FrmRFIPEdit.Designer.cs
source/ACPackingStore/FrmRFIPEdit.cs
source/DeviceLibrary/ACPackingStore/AC_BOX_Bean_Partial.cs
source/DeviceLibrary/device/halcon/CodeManager-back.cs
source/ACPackingStore/FrmRFIPEdit.Designer.cs
查看文件 @
3078ab8
...
...
@@ -39,16 +39,9 @@
this
.
button1
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
label4
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
numNum
=
new
System
.
Windows
.
Forms
.
NumericUpDown
();
this
.
txtSearchIp
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
btnSearch
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
cmbLocalIp
=
new
System
.
Windows
.
Forms
.
ComboBox
();
this
.
label5
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
groupBox1
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
label6
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
groupBox2
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
lblResult
=
new
System
.
Windows
.
Forms
.
Label
();
((
System
.
ComponentModel
.
ISupportInitialize
)(
this
.
numNum
)).
BeginInit
();
this
.
groupBox1
.
SuspendLayout
();
this
.
groupBox2
.
SuspendLayout
();
this
.
SuspendLayout
();
//
...
...
@@ -168,75 +161,6 @@
this
.
numNum
.
Size
=
new
System
.
Drawing
.
Size
(
120
,
26
);
this
.
numNum
.
TabIndex
=
283
;
//
// txtSearchIp
//
this
.
txtSearchIp
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
txtSearchIp
.
Location
=
new
System
.
Drawing
.
Point
(
196
,
87
);
this
.
txtSearchIp
.
Name
=
"txtSearchIp"
;
this
.
txtSearchIp
.
Size
=
new
System
.
Drawing
.
Size
(
233
,
26
);
this
.
txtSearchIp
.
TabIndex
=
286
;
//
// btnSearch
//
this
.
btnSearch
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnSearch
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnSearch
.
Location
=
new
System
.
Drawing
.
Point
(
446
,
68
);
this
.
btnSearch
.
Name
=
"btnSearch"
;
this
.
btnSearch
.
Size
=
new
System
.
Drawing
.
Size
(
120
,
45
);
this
.
btnSearch
.
TabIndex
=
287
;
this
.
btnSearch
.
Text
=
"搜索IP"
;
this
.
btnSearch
.
UseVisualStyleBackColor
=
false
;
this
.
btnSearch
.
Click
+=
new
System
.
EventHandler
(
this
.
btnSearch_Click
);
//
// cmbLocalIp
//
this
.
cmbLocalIp
.
DropDownStyle
=
System
.
Windows
.
Forms
.
ComboBoxStyle
.
DropDownList
;
this
.
cmbLocalIp
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
cmbLocalIp
.
FormattingEnabled
=
true
;
this
.
cmbLocalIp
.
Location
=
new
System
.
Drawing
.
Point
(
196
,
38
);
this
.
cmbLocalIp
.
Name
=
"cmbLocalIp"
;
this
.
cmbLocalIp
.
Size
=
new
System
.
Drawing
.
Size
(
233
,
28
);
this
.
cmbLocalIp
.
TabIndex
=
288
;
//
// label5
//
this
.
label5
.
AutoSize
=
true
;
this
.
label5
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label5
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
this
.
label5
.
Location
=
new
System
.
Drawing
.
Point
(
81
,
38
);
this
.
label5
.
Name
=
"label5"
;
this
.
label5
.
Size
=
new
System
.
Drawing
.
Size
(
106
,
20
);
this
.
label5
.
TabIndex
=
289
;
this
.
label5
.
Text
=
"请选择本地IP:"
;
this
.
label5
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
//
// groupBox1
//
this
.
groupBox1
.
Controls
.
Add
(
this
.
label6
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
cmbLocalIp
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label5
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
txtSearchIp
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
btnSearch
);
this
.
groupBox1
.
Location
=
new
System
.
Drawing
.
Point
(
22
,
12
);
this
.
groupBox1
.
Name
=
"groupBox1"
;
this
.
groupBox1
.
Size
=
new
System
.
Drawing
.
Size
(
614
,
138
);
this
.
groupBox1
.
TabIndex
=
290
;
this
.
groupBox1
.
TabStop
=
false
;
this
.
groupBox1
.
Text
=
"搜索RFID"
;
this
.
groupBox1
.
Visible
=
false
;
//
// label6
//
this
.
label6
.
AutoSize
=
true
;
this
.
label6
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label6
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
this
.
label6
.
Location
=
new
System
.
Drawing
.
Point
(
108
,
90
);
this
.
label6
.
Name
=
"label6"
;
this
.
label6
.
Size
=
new
System
.
Drawing
.
Size
(
79
,
20
);
this
.
label6
.
TabIndex
=
290
;
this
.
label6
.
Text
=
"搜素结果:"
;
this
.
label6
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
//
// groupBox2
//
this
.
groupBox2
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Bottom
)
...
...
@@ -253,9 +177,9 @@
this
.
groupBox2
.
Controls
.
Add
(
this
.
label3
);
this
.
groupBox2
.
Controls
.
Add
(
this
.
label4
);
this
.
groupBox2
.
Controls
.
Add
(
this
.
comType
);
this
.
groupBox2
.
Location
=
new
System
.
Drawing
.
Point
(
22
,
12
);
this
.
groupBox2
.
Location
=
new
System
.
Drawing
.
Point
(
22
,
6
);
this
.
groupBox2
.
Name
=
"groupBox2"
;
this
.
groupBox2
.
Size
=
new
System
.
Drawing
.
Size
(
489
,
325
);
this
.
groupBox2
.
Size
=
new
System
.
Drawing
.
Size
(
505
,
331
);
this
.
groupBox2
.
TabIndex
=
291
;
this
.
groupBox2
.
TabStop
=
false
;
this
.
groupBox2
.
Text
=
"读取RFID"
;
...
...
@@ -278,14 +202,11 @@
this
.
AutoScaleMode
=
System
.
Windows
.
Forms
.
AutoScaleMode
.
Font
;
this
.
ClientSize
=
new
System
.
Drawing
.
Size
(
560
,
361
);
this
.
Controls
.
Add
(
this
.
groupBox2
);
this
.
Controls
.
Add
(
this
.
groupBox1
);
this
.
Icon
=
((
System
.
Drawing
.
Icon
)(
resources
.
GetObject
(
"$this.Icon"
)));
this
.
Name
=
"FrmRFIPEdit"
;
this
.
Text
=
"托盘编码"
;
this
.
Load
+=
new
System
.
EventHandler
(
this
.
FrmPwd_Load
);
((
System
.
ComponentModel
.
ISupportInitialize
)(
this
.
numNum
)).
EndInit
();
this
.
groupBox1
.
ResumeLayout
(
false
);
this
.
groupBox1
.
PerformLayout
();
this
.
groupBox2
.
ResumeLayout
(
false
);
this
.
groupBox2
.
PerformLayout
();
this
.
ResumeLayout
(
false
);
...
...
@@ -304,13 +225,7 @@
private
System
.
Windows
.
Forms
.
Button
button1
;
private
System
.
Windows
.
Forms
.
Label
label4
;
private
System
.
Windows
.
Forms
.
NumericUpDown
numNum
;
private
System
.
Windows
.
Forms
.
TextBox
txtSearchIp
;
private
System
.
Windows
.
Forms
.
Button
btnSearch
;
private
System
.
Windows
.
Forms
.
ComboBox
cmbLocalIp
;
private
System
.
Windows
.
Forms
.
Label
label5
;
private
System
.
Windows
.
Forms
.
GroupBox
groupBox1
;
private
System
.
Windows
.
Forms
.
GroupBox
groupBox2
;
private
System
.
Windows
.
Forms
.
Label
label6
;
private
System
.
Windows
.
Forms
.
Label
lblResult
;
}
}
\ No newline at end of file
source/ACPackingStore/FrmRFIPEdit.cs
查看文件 @
3078ab8
...
...
@@ -38,18 +38,7 @@ namespace OnlineStore.ACPackingStore
string
hostN
=
Dns
.
GetHostName
();
IPAddress
[]
addresss
=
Dns
.
GetHostAddresses
(
hostN
);
cmbLocalIp
.
Items
.
Clear
();
if
(
addresss
!=
null
&&
addresss
.
Length
>
0
)
{
foreach
(
IPAddress
ip
in
addresss
)
{
if
(
ip
.
AddressFamily
.
Equals
(
AddressFamily
.
InterNetwork
))
{
cmbLocalIp
.
Items
.
Add
(
ip
.
ToString
());
}
}
cmbLocalIp
.
SelectedIndex
=
0
;
}
}
private
void
btnBack_Click
(
object
sender
,
EventArgs
e
)
...
...
@@ -90,14 +79,5 @@ namespace OnlineStore.ACPackingStore
}
}
}
private
void
btnSearch_Click
(
object
sender
,
EventArgs
e
)
{
string
text
=
cmbLocalIp
.
Text
;
// string ip = RFIDManager.SearchIP(text);
// txtSearchIp.Text = ip;
}
}
}
source/DeviceLibrary/ACPackingStore/AC_BOX_Bean_Partial.cs
查看文件 @
3078ab8
...
...
@@ -110,7 +110,7 @@ namespace OnlineStore.DeviceLibrary
if
(!
wait
.
IsEnd
&&
span
.
TotalSeconds
>
10
)
{
//如果是等待AGV到达,等待有料架信号也算结束
if
(
wait
.
TargetPosition
.
Equals
((
int
)
Asa
.
Actions
.
Arrive
)
&&
MoveInfo
.
MoveStep
.
Equals
(
StoreMoveStep
.
BI_01_ReadyShelf
))
if
(
wait
.
TargetPosition
.
Equals
((
int
)
Asa
.
Actions
.
Arrive
)
&&
MoveInfo
.
MoveStep
.
Equals
(
StoreMoveStep
.
BI_01_ReadyShelf
))
{
if
(
IOValue
(
IO_Type
.
LineTake_Check
).
Equals
(
IO_VALUE
.
HIGH
))
{
...
...
@@ -206,7 +206,7 @@ namespace OnlineStore.DeviceLibrary
||
(!
MoveInfo
.
MoveType
.
Equals
(
StoreMoveType
.
None
)))
{
LogUtil
.
error
(
Name
+
" 启动出库出错,忙碌或报警中 ,storeStatus="
+
storeRunStatus
+
",MoveType="
+
MoveInfo
.
MoveType
+
",isInSuddenDown="
+
isInSuddenDown
+
",isNoAirCheck"
+
isNoAirCheck
);
return
;
return
;
}
if
(!
StoreManager
.
LoadInoutParam
(
param
,
true
,
this
))
...
...
@@ -216,7 +216,7 @@ namespace OnlineStore.DeviceLibrary
}
param
.
NeedEnterShelf
=
false
;
param
.
NeedOutShelf
=
false
;
LogInfo
(
" 启动入库【"
+
param
.
ToStr
()
+
"】,压紧点P2【"
+
param
.
MoveP
.
ComPress_P2
+
"】压紧前点P3【"
+
param
.
MoveP
.
ComPress_P3
+
"】"
);
LogInfo
(
" 启动入库【"
+
param
.
ToStr
()
+
"】,压紧点P2【"
+
param
.
MoveP
.
ComPress_P2
+
"】压紧前点P3【"
+
param
.
MoveP
.
ComPress_P3
+
"】"
);
storeRunStatus
=
StoreRunStatus
.
Busy
;
storeStatus
=
StoreStatus
.
InStoreExecute
;
MoveInfo
.
NewMove
(
StoreMoveType
.
InStore
,
param
);
...
...
@@ -224,7 +224,7 @@ namespace OnlineStore.DeviceLibrary
//新的料架库位
MoveInfo
.
NextMoveStep
(
StoreMoveStep
.
BI_11_InoutToP1
);
MoveInfo
.
SingleInstore
=
true
;
InOutStoreLog
(
"料架取料:"
+
MoveInfo
.
SLog
+
" 叉子后退到待机点P1, 重置盘信息"
);
InOutStoreLog
(
"料架取料:"
+
MoveInfo
.
SLog
+
" 叉子后退到待机点P1, 重置盘信息"
);
ACAxisMove
(
Config
.
InOut_Axis
,
Config
.
InOutAxis_P1_Position
,
Config
.
InOutAxis_P1_Speed
);
ClearLastTrayInfo
();
}
...
...
@@ -237,7 +237,7 @@ namespace OnlineStore.DeviceLibrary
{
bool
canStart
=
(
storeRunStatus
.
Equals
(
StoreRunStatus
.
Runing
)
&&
MoveInfo
.
MoveType
.
Equals
(
StoreMoveType
.
None
)
);
&&
MoveInfo
.
MoveType
.
Equals
(
StoreMoveType
.
None
));
if
(!
canStart
||
isInSuddenDown
||
isNoAirCheck
||
(
alarmType
.
Equals
(
StoreAlarmType
.
None
).
Equals
(
false
)))
{
return
;
...
...
@@ -280,7 +280,7 @@ namespace OnlineStore.DeviceLibrary
private
void
UpdateShelfId
()
{
//读取RFID
RFIDData
data
=
RFIDManager
.
ReadRFID
(
Config
.
RFID_IP
,
true
);
RFIDData
data
=
RFIDManager
.
ReadRFID
(
Config
.
RFID_IP
,
true
);
LogUtil
.
info
(
Name
+
"更新当前料架号【"
+
data
.
NumStr
()
+
"】"
);
//TODO 判断料架是否正确
if
(
data
.
RFType
.
Equals
(
"A"
))
...
...
@@ -288,16 +288,12 @@ namespace OnlineStore.DeviceLibrary
CurrShelfID
=
data
.
NumStr
();
AgvClient
.
SendRFID
(
Config
.
AgvNodeName
,
CurrShelfID
);
}
//else
//{
// LogUtil.error(Name + "检测到入料口有料架,读取RFID数据错误:" + data.NumStr());
//}
}
private
void
StartMoveToBag
()
{
MoveInfo
.
NextMoveStep
(
StoreMoveStep
.
BI_51_MoveToBag
);
InOutStoreLog
(
"入库 "
+
MoveInfo
.
SLog
+
":
移动
到库位点,旋转轴至P2( 库位点)轴2(上下) 至P3(库位入库前点)"
);
InOutStoreLog
(
"入库 "
+
MoveInfo
.
SLog
+
":到库位点,旋转轴至P2( 库位点)轴2(上下) 至P3(库位入库前点)"
);
ACAxisMove
(
Config
.
Middle_Axis
,
MoveInfo
.
MoveParam
.
MoveP
.
Middle_P2
,
Config
.
MiddleAxis_P2_Speed
);
ACAxisMove
(
Config
.
UpDown_Axis
,
MoveInfo
.
MoveParam
.
MoveP
.
UpDown_P3
,
Config
.
UpDownAxis_P3_Speed
);
}
...
...
@@ -345,7 +341,7 @@ namespace OnlineStore.DeviceLibrary
else
if
(
MoveInfo
.
MoveStep
.
Equals
(
StoreMoveStep
.
BI_11_InoutToP1
))
{
MoveInfo
.
NextMoveStep
(
StoreMoveStep
.
BI_12_MoveToShelf
);
InOutStoreLog
(
"料架取料 "
+
MoveInfo
.
SLog
+
":升降轴
移动到P101低点,旋转轴移动
到P101点,压紧轴到压紧前点"
);
InOutStoreLog
(
"料架取料 "
+
MoveInfo
.
SLog
+
":升降轴
到P101低点,旋转轴
到P101点,压紧轴到压紧前点"
);
ACAxisMove
(
Config
.
UpDown_Axis
,
moveP
.
UpDown_LP101
,
Config
.
UpDownAxis_P101_Speed
);
ACAxisMove
(
Config
.
Middle_Axis
,
moveP
.
Middle_P101
,
Config
.
MiddleAxis_P101_Speed
);
ACAxisMove
(
Config
.
Comp_Axis
,
Config
.
CompAxis_Max_P3
,
Config
.
CompAxis_P3_Speed
);
...
...
@@ -367,7 +363,7 @@ namespace OnlineStore.DeviceLibrary
if
(
MoveInfo
.
SingleInstore
)
{
MoveInfo
.
NextMoveStep
(
StoreMoveStep
.
BI_16_ComDownMove
);
InOutStoreLog
(
"单盘入库,料架取料 "
+
MoveInfo
.
SLog
+
":压紧轴走到压紧点P2: "
+
MoveInfo
.
MoveParam
.
MoveP
.
ComPress_P2
);
InOutStoreLog
(
"单盘入库,料架取料 "
+
MoveInfo
.
SLog
+
":压紧轴走到压紧点P2: "
+
MoveInfo
.
MoveParam
.
MoveP
.
ComPress_P2
);
ACAxisMove
(
Config
.
Comp_Axis
,
MoveInfo
.
MoveParam
.
MoveP
.
ComPress_P2
,
Config
.
CompAxis_P2_Speed
);
}
else
...
...
@@ -390,7 +386,7 @@ namespace OnlineStore.DeviceLibrary
MoveInfo
.
MoveParam
.
MoveP
.
ComPress_P2
=
targetP
;
MoveInfo
.
MoveParam
.
MoveP
.
ComPress_P3
=
targetP
+
Config
.
CompAxis_P3_P2_Value
;
InOutStoreLog
(
"料架取料 "
+
MoveInfo
.
SLog
+
":检测到Compress_Check,盘高【"
+
LastHeight
+
"】,向下压紧 ["
+
Config
.
CompAxis_Down_Position
+
"] 目标 ["
+
targetP
+
"]记录ComP2["
+
targetP
+
"]ComP3["
+
MoveInfo
.
MoveParam
.
MoveP
.
ComPress_P3
+
"]"
);
"]记录ComP2["
+
targetP
+
"]ComP3["
+
MoveInfo
.
MoveParam
.
MoveP
.
ComPress_P3
+
"]"
);
ACAxisMove
(
Config
.
Comp_Axis
,
targetP
,
Config
.
CompAxis_P1_Speed
);
...
...
@@ -411,7 +407,7 @@ namespace OnlineStore.DeviceLibrary
else
{
MoveInfo
.
NextMoveStep
(
StoreMoveStep
.
BI_21_ToScanPosition
);
InOutStoreLog
(
"扫码 "
+
MoveInfo
.
SLog
+
":升降轴
移动到P2,旋转轴移动
到P1"
);
InOutStoreLog
(
"扫码 "
+
MoveInfo
.
SLog
+
":升降轴
到P2,旋转轴
到P1"
);
ACAxisMove
(
Config
.
UpDown_Axis
,
moveP
.
UpDown_P2
,
Config
.
UpDownAxis_P2_Speed
);
ACAxisMove
(
Config
.
Middle_Axis
,
moveP
.
Middle_P1
,
Config
.
MiddleAxis_P1_Speed
);
}
...
...
@@ -869,7 +865,7 @@ namespace OnlineStore.DeviceLibrary
}
else
{
string
msg
=
StoreManager
.
UpdateTrayLoc
(
Name
,
MoveInfo
.
MoveParam
.
WareCode
,
CurrShelfID
+
"@"
+
posLoc
.
ToString
());
string
msg
=
StoreManager
.
UpdateTrayLoc
(
Name
,
MoveInfo
.
MoveParam
.
WareCode
,
CurrShelfID
+
"@"
+
posLoc
.
ToString
());
if
(
String
.
IsNullOrEmpty
(
msg
).
Equals
(
false
))
{
LogUtil
.
error
(
Name
+
"【"
+
MoveInfo
.
MoveParam
.
WareCode
+
"】【"
+
CurrShelfID
+
"】【"
+
posLoc
+
"】UpdateTrayLoc 结果:"
+
msg
);
...
...
source/DeviceLibrary/device/halcon/CodeManager-back.cs
deleted
100644 → 0
查看文件 @
cf79dc6
此文件的差异被折叠,
点击展开。
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论