Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
RC1250-ACPackingStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 2bb7cd24
由
LN
编写于
2020-01-05 17:28:43 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
压紧轴配置修改。压紧点高度需大于待机点
1 个父辈
57efebb1
隐藏空白字符变更
内嵌
并排
正在显示
9 个修改的文件
包含
126 行增加
和
44 行删除
source/ACPackingStore/FrmBox.Designer.cs
source/ACPackingStore/FrmBox.cs
source/ACPackingStore/FrmStore.Designer.cs
source/ACPackingStore/FrmStore.cs
source/DeviceLibrary/StoreConfig/BoxConfig_1.csv
source/DeviceLibrary/StoreConfig/BoxConfig_2.csv
source/DeviceLibrary/StoreConfig/shelfPosition_1.csv
source/DeviceLibrary/StoreConfig/shelfPosition_2.csv
source/LoadCVSLibrary/storeConfig/config/AC_Box_Config.cs
source/ACPackingStore/FrmBox.Designer.cs
查看文件 @
2bb7cd2
...
...
@@ -1483,9 +1483,9 @@
this
.
label1
.
Location
=
new
System
.
Drawing
.
Point
(
15
,
175
);
this
.
label1
.
Name
=
"label1"
;
this
.
label1
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
label1
.
Size
=
new
System
.
Drawing
.
Size
(
35
,
17
);
this
.
label1
.
Size
=
new
System
.
Drawing
.
Size
(
62
,
17
);
this
.
label1
.
TabIndex
=
175
;
this
.
label1
.
Text
=
"盘高:"
;
this
.
label1
.
Text
=
"盘高
/mm
:"
;
this
.
label1
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
//
// groupBox3
...
...
source/ACPackingStore/FrmBox.cs
查看文件 @
2bb7cd2
...
...
@@ -302,7 +302,10 @@ namespace OnlineStore.ACPackingStore
txtUpDownP4
.
Text
=
acPosition
.
UpdownAxis_IL_P4
.
ToString
();
txtUpDownP5
.
Text
=
acPosition
.
UpdownAxis_OH_P5
.
ToString
();
txtUpDownP6
.
Text
=
acPosition
.
UpdownAxis_OL_P6
.
ToString
();
int
comP2
=
BoxBean
.
Config
.
GetComP2
(
acPosition
.
BagHigh
).
TargetComP2
();
txtComP2
.
Text
=
comP2
.
ToString
();
txtComP3
.
Text
=
(
comP2
+
BoxBean
.
Config
.
CompAxis_P3_P2_Value
).
ToString
();
btnComP2
.
Text
=
""
+
acPosition
.
BagHigh
+
"mm压紧点P2:"
;
...
...
@@ -863,6 +866,14 @@ namespace OnlineStore.ACPackingStore
int
minValue
=
FormUtil
.
GetIntValue
(
txtComMin
);
int
maxValue
=
FormUtil
.
GetIntValue
(
txtComMax
);
ComP2Info
p2Info
=
new
ComP2Info
(
height
,
minValue
,
maxValue
);
if
(
minValue
>
BoxBean
.
Config
.
CompAxis_P1_Position
&&
maxValue
>
BoxBean
.
Config
.
CompAxis_P1_Position
)
{
}
else
{
MessageBox
.
Show
(
"保存失败:"
+
" 盘高【"
+
height
+
"】范围【"
+
minValue
+
"~"
+
maxValue
+
"】无效,压紧点需大于待机点【"
+
BoxBean
.
Config
.
CompAxis_P1_Position
+
"】"
);
return
;
}
BoxBean
.
Config
.
UpdateComP2
(
height
,
p2Info
);
BoxBean
.
Config
.
CompAxis_P4_Position
=
FormUtil
.
GetIntValue
(
txtComP4
);
...
...
source/ACPackingStore/FrmStore.Designer.cs
查看文件 @
2bb7cd2
...
...
@@ -32,6 +32,7 @@
System
.
ComponentModel
.
ComponentResourceManager
resources
=
new
System
.
ComponentModel
.
ComponentResourceManager
(
typeof
(
FrmStore
));
this
.
tabControl1
=
new
System
.
Windows
.
Forms
.
TabControl
();
this
.
tabPage1
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
chbDoorCanMove
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
chbAutoShelfInstore
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
chbUseBuzzer
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
chkDebug
=
new
System
.
Windows
.
Forms
.
CheckBox
();
...
...
@@ -90,6 +91,7 @@
//
// tabPage1
//
this
.
tabPage1
.
Controls
.
Add
(
this
.
chbDoorCanMove
);
this
.
tabPage1
.
Controls
.
Add
(
this
.
chbAutoShelfInstore
);
this
.
tabPage1
.
Controls
.
Add
(
this
.
chbUseBuzzer
);
this
.
tabPage1
.
Controls
.
Add
(
this
.
chkDebug
);
...
...
@@ -104,6 +106,18 @@
this
.
tabPage1
.
Text
=
" 日志信息 "
;
this
.
tabPage1
.
UseVisualStyleBackColor
=
true
;
//
// chbDoorCanMove
//
this
.
chbDoorCanMove
.
AutoSize
=
true
;
this
.
chbDoorCanMove
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
chbDoorCanMove
.
Location
=
new
System
.
Drawing
.
Point
(
923
,
13
);
this
.
chbDoorCanMove
.
Name
=
"chbDoorCanMove"
;
this
.
chbDoorCanMove
.
Size
=
new
System
.
Drawing
.
Size
(
126
,
24
);
this
.
chbDoorCanMove
.
TabIndex
=
197
;
this
.
chbDoorCanMove
.
Text
=
"启用入料口移门"
;
this
.
chbDoorCanMove
.
UseVisualStyleBackColor
=
true
;
this
.
chbDoorCanMove
.
CheckedChanged
+=
new
System
.
EventHandler
(
this
.
chbDoorCanMove_CheckedChanged
);
//
// chbAutoShelfInstore
//
this
.
chbAutoShelfInstore
.
AutoSize
=
true
;
...
...
@@ -453,6 +467,7 @@
private
System
.
Windows
.
Forms
.
ToolStripMenuItem
托盘编码
ToolStripMenuItem
;
private
System
.
Windows
.
Forms
.
ToolStripSeparator
toolStripSeparator8
;
private
System
.
Windows
.
Forms
.
CheckBox
chbAutoShelfInstore
;
private
System
.
Windows
.
Forms
.
CheckBox
chbDoorCanMove
;
}
}
source/ACPackingStore/FrmStore.cs
查看文件 @
2bb7cd2
...
...
@@ -53,7 +53,8 @@ namespace OnlineStore.ACPackingStore
chbAutoRun
.
Checked
=
store
.
UseBuzzer
;
chbAutoShelfInstore
.
Checked
=
store
.
AutoShelfInstore
;
this
.
Text
=
ConfigAppSettings
.
GetValue
(
Setting_Init
.
App_Title
);
chbAutoRun
.
Checked
=
ConfigAppSettings
.
GetValue
(
Setting_Init
.
App_AutoRun
).
Equals
(
1
);
chbAutoRun
.
Checked
=(
ConfigAppSettings
.
GetIntValue
(
Setting_Init
.
App_AutoRun
).
Equals
(
1
));
chbDoorCanMove
.
Checked
=(
ConfigAppSettings
.
GetIntValue
(
Setting_Init
.
UseDoor
).
Equals
(
1
));
// LogUtil.logBox = this.logBox;
// HideForm();
LoadOk
=
true
;
...
...
@@ -482,5 +483,26 @@ namespace OnlineStore.ACPackingStore
}
}
}
private
void
chbDoorCanMove_CheckedChanged
(
object
sender
,
EventArgs
e
)
{
if
(!
LoadOk
)
{
return
;
}
if
(
chbDoorCanMove
.
Checked
)
{
store
.
AutoShelfInstore
=
true
;
ConfigAppSettings
.
SaveValue
(
Setting_Init
.
UseDoor
,
1
);
LogUtil
.
info
(
"勾选:启用入料口移门"
);
}
else
{
store
.
AutoShelfInstore
=
false
;
ConfigAppSettings
.
SaveValue
(
Setting_Init
.
UseDoor
,
0
);
LogUtil
.
info
(
"去掉:启用入料口移门"
);
}
}
}
}
source/DeviceLibrary/StoreConfig/BoxConfig_1.csv
查看文件 @
2bb7cd2
...
...
@@ -56,11 +56,11 @@ PRO,升降轴(轴2)P2扫码放料高点缓冲点,UpDownAxis_P2,600000,,,,,,,
PRO,旋转轴(轴1)P1待机点/扫码放料点,MiddleAxis_P1,310700,,,,,,,
PRO,进出轴(轴3)P1待机点,InOutAxis_P1_Position,1000,,,,,,,
PRO,压紧轴(轴4)P1待机点,CompAxis_P1_Position,97900,,,,,,,
PRO,压紧轴(轴4)
P3最大压紧前点,CompAxis_Max_P3,979
00,,,,,,,
PRO,压紧轴(轴4)P4目标压紧点,CompAxis_P4_Position,
100000
,,,,,,,
PRO,压紧轴(轴4)取料时的压紧前点相对压紧点的位置,CompAxis_P3_P2_Value,-
5
0000,,,,,,,
PRO,压紧轴(轴4)压紧确认信号收到之后下降的位置,CompAxis_Down_Position,2000,,,,,,,
PRO,压紧轴(轴4)P2压紧点范围对应值(8=1000;2000#),CompAxis_P2_List,8=
1000;2000#12=2001;3000#16=3001;4000#20=4001;5000#22=5001;6000#24=6001;7000#
,,,,,,,
PRO,压紧轴(轴4)
最大压紧前点,CompAxis_Max_P3,2200
00,,,,,,,
PRO,压紧轴(轴4)P4目标压紧点,CompAxis_P4_Position,
380001
,,,,,,,
PRO,压紧轴(轴4)取料时的压紧前点相对压紧点的位置,CompAxis_P3_P2_Value,-
10
0000,,,,,,,
PRO,压紧轴(轴4)压紧确认信号收到之后下降的位置,CompAxis_Down_Position,2000
0
,,,,,,,
PRO,压紧轴(轴4)P2压紧点范围对应值(8=1000;2000#),CompAxis_P2_List,8=
401101;421200#12=389051;401100#16=358501;389050#24=306901;358500#32=232301;306900#48=157700;232300#
,,,,,,,
,,,,,,,,,,
PRO,(轴一)旋转轴目标速度,MiddleAxis_TargetSpeed,250,,,,,,,
PRO,(轴一)旋转轴加速度,MiddleAxis_AddSpeed,1000,,,,,,,
...
...
source/DeviceLibrary/StoreConfig/BoxConfig_2.csv
查看文件 @
2bb7cd2
...
...
@@ -44,22 +44,22 @@ AXIS,(轴二)升降轴轴,UpDown_Axis,2,COM4,0,,,,,
AXIS,(轴三)进出轴,InOut_Axis,3,COM4,0,,,,,
AXIS,(轴四)压紧轴,Comp_Axis,4,COM4,0,,,,,
,,,,,,,,,,
PRO,升降轴(轴2)P11-NG放料低点,UpDownAxis_P11,
10216
00,,,,,,,
PRO,升降轴(轴2)P12-NG放料高点缓冲点,UpDownAxis_P12,10
0215
0,,,,,,,
PRO,旋转轴(轴1)P11-NG放料点,MiddleAxis_P11,30
8
300,,,,,,,
PRO,升降轴(轴2)P11-NG放料低点,UpDownAxis_P11,
9960
00,,,,,,,
PRO,升降轴(轴2)P12-NG放料高点缓冲点,UpDownAxis_P12,10
2000
0,,,,,,,
PRO,旋转轴(轴1)P11-NG放料点,MiddleAxis_P11,30
7
300,,,,,,,
PRO,进出轴(轴3)P2-扫码放料点,InOutAxis_P2_Position,130000,,,,,,,
PRO,进出轴(轴3)P11-NG放料点,InOutAxis_P11_Position,1
408
00,,,,,,,
PRO,进出轴(轴3)P11-NG放料点,InOutAxis_P11_Position,1
520
00,,,,,,,
,,,,,,,,,,
PRO,升降轴(轴2)P1待机点/扫码放料低点,UpDownAxis_P1,591000,,,,,,,
PRO,升降轴(轴2)P2扫码放料高点缓冲点,UpDownAxis_P2,602500,,,,,,,
PRO,旋转轴(轴1)P1待机点/扫码放料点,MiddleAxis_P1,308300,,,,,,,
PRO,进出轴(轴3)P1待机点,InOutAxis_P1_Position,1000,,,,,,,
PRO,压紧轴(轴4)P1待机点,CompAxis_P1_Position,
30
000,,,,,,,
PRO,压紧轴(轴4)
P3最大压紧前点,CompAxis_Max_P3,979
00,,,,,,,
PRO,压紧轴(轴4)P4目标压紧点,CompAxis_P4_Position,
10
0000,,,,,,,
PRO,压紧轴(轴4)取料时的压紧前点相对压紧点的位置,CompAxis_P3_P2_Value,-
5
0000,,,,,,,
PRO,压紧轴(轴4)压紧确认信号收到之后下降的位置,CompAxis_Down_Position,
20
00,,,,,,,
PRO,压紧轴(轴4)P2压紧点范围对应值(8=1000;2000#),CompAxis_P2_List,8=
1000;2000#12=2001;3000#16=3001;4000#20=4001;5000#22=5001;6000#24=6001;7000#
,,,,,,,
PRO,压紧轴(轴4)P1待机点,CompAxis_P1_Position,
55
000,,,,,,,
PRO,压紧轴(轴4)
最大压紧前点,CompAxis_Max_P3,2200
00,,,,,,,
PRO,压紧轴(轴4)P4目标压紧点,CompAxis_P4_Position,
39
0000,,,,,,,
PRO,压紧轴(轴4)取料时的压紧前点相对压紧点的位置,CompAxis_P3_P2_Value,-
10
0000,,,,,,,
PRO,压紧轴(轴4)压紧确认信号收到之后下降的位置,CompAxis_Down_Position,
986
00,,,,,,,
PRO,压紧轴(轴4)P2压紧点范围对应值(8=1000;2000#),CompAxis_P2_List,8=
401101;421200#12=389051;401100#16=358501;389050#24=306901;358500#32=232301;306900#48=157700;232300#
,,,,,,,
,,,,,,,,,,
PRO,(轴一)旋转轴目标速度,MiddleAxis_TargetSpeed,250,,,,,,,
PRO,(轴一)旋转轴加速度,MiddleAxis_AddSpeed,1000,,,,,,,
...
...
@@ -135,8 +135,8 @@ PRO,需要吹气的温度(温度标准),Max_Temperature,0,,,,,,,
PRO,需要吹气的湿度(湿度标准),Max_Humidity,10,,,,,,,
PRO,每次吹气的时间(分钟),BlowAir_Time,10,,,,,,,
PRO,两次吹气间隔(分钟),BlowAir_Interval,10,,,,,,,
PRO,温湿度端口号,Humiture_Port,COM
1
,,,,,,,
PRO,温湿度端口号,Humiture_Port,COM
5
,,,,,,,
,,,,,,,,,,
PRO,扫码的相机名称(多个用#分隔),CameraNameList,GigE:MV-CE200-10GC (00D77519098),,,,,,,
PRO,RFID读卡器IP,RFID_IP,192.168.106.102,,,,,,,
PRO,是否是调试状态,IsInDebug,
1
,,,,,,,
PRO,是否是调试状态,IsInDebug,
0
,,,,,,,
source/DeviceLibrary/StoreConfig/shelfPosition_1.csv
查看文件 @
2bb7cd2
位置,优先级,高度,宽度,料仓ID,旋转轴位置P101,升降轴低点P101,升降轴高点P102,进出轴位置P101
1#S_1_1,
1,8,7,1,311800,83300,98000,810
00
1#S_1_2,
2,8,7,1,311800,114000,128700,810
00
1#S_1_3,
3,8,7,1,311800,144700,159400,810
00
1#S_1_4,
4,8,7,1,311800,175400,190100,810
00
1#S_1_5,5,8,7,1,311800,
206100,220800,810
00
1#S_1_6,
6,8,7,1,311800,236800,251500,810
00
1#S_1_7,
7,8,7,1,311800,267500,282200,810
00
1#S_1_8,
8,8,7,1,311800,298200,312900,810
00
1#S_1_9,
9,8,7,1,311800,328900,343600,810
00
1#S_1_1,
9,8,7,1,311800,95000,110000,1448
00
1#S_1_2,
8,8,7,1,311800,149000,164000,1448
00
1#S_1_3,
7,8,7,1,311800,201000,216000,1448
00
1#S_1_4,
6,8,7,1,311800,254000,269000,1448
00
1#S_1_5,5,8,7,1,311800,
302000,317000,1448
00
1#S_1_6,
4,8,7,1,311800,350000,365000,1448
00
1#S_1_7,
3,8,7,1,311800,402000,417000,1448
00
1#S_1_8,
2,8,7,1,311800,454000,469000,1448
00
1#S_1_9,
1,8,7,1,311800,505000,520000,1448
00
source/DeviceLibrary/StoreConfig/shelfPosition_2.csv
查看文件 @
2bb7cd2
位置,优先级,高度,宽度,料仓ID,旋转轴位置P101,升降轴低点P101,升降轴高点P102,进出轴位置P101
2#S_1_1,
1,8,7,2,311800,83300,98000,810
00
2#S_1_2,
2,8,7,2,311800,114000,128700,810
00
2#S_1_3,
3,8,7,2,311800,144700,159400,810
00
2#S_1_4,
4,8,7,2,311800,175400,190100,810
00
2#S_1_5,5,8,7,2,3
11800,206100,220800,810
00
2#S_1_6,
6,8,7,2,311800,236800,251500,810
00
2#S_1_7,
7,8,7,2,311800,267500,282200,810
00
2#S_1_8,
8,8,7,2,311800,298200,312900,810
00
2#S_1_9,
9,8,7,2,311800,328900,343600,810
00
2#S_1_1,
9,8,7,2,308300,95000,110000,1448
00
2#S_1_2,
8,8,7,2,308300,149000,164000,1448
00
2#S_1_3,
7,8,7,2,308300,201000,216000,1448
00
2#S_1_4,
6,8,7,2,308300,254000,269000,1448
00
2#S_1_5,5,8,7,2,3
08300,302000,317000,1448
00
2#S_1_6,
4,8,7,2,308300,350000,365000,1448
00
2#S_1_7,
3,8,7,2,308300,402000,417000,1448
00
2#S_1_8,
2,8,7,2,308300,454000,469000,1448
00
2#S_1_9,
1,8,7,2,308300,505000,520000,1448
00
source/LoadCVSLibrary/storeConfig/config/AC_Box_Config.cs
查看文件 @
2bb7cd2
...
...
@@ -536,24 +536,51 @@ namespace OnlineStore.LoadCSVLibrary
private
List
<
ComP2Info
>
ComP2List
=
null
;
public
ComP2Info
GetComP2
(
int
plateh
)
{
//查找指定的高度
analysisComP2
();
List
<
ComP2Info
>
list
=
(
from
m
in
ComP2List
where
m
.
PlateH
.
Equals
(
plateh
)
select
m
).
ToList
<
ComP2Info
>();
if
(
list
.
Count
>
0
)
{
return
list
[
0
];
}
return
ComP2List
.
Count
>
0
?
ComP2List
[
0
]
:
null
;
//查找类似的高度
list
=
(
from
com
in
ComP2List
orderby
com
.
PlateH
descending
select
com
).
ToList
<
ComP2Info
>();
foreach
(
ComP2Info
comp2
in
list
)
{
if
(
plateh
>=
comp2
.
PlateH
)
{
return
comp2
;
}
}
return
new
ComP2Info
(
plateh
,
CompAxis_P4_Position
,
CompAxis_P4_Position
+
CompAxis_Down_Position
);
}
public
int
GetComP2PlateH
(
int
currP
)
{
analysisComP2
();
analysisComP2
();
List
<
ComP2Info
>
list
=
(
from
com
in
ComP2List
where
com
.
MinComP
<=
currP
&&
com
.
MaxComP
>=
currP
select
com
).
ToList
<
ComP2Info
>();
if
(
list
.
Count
>
0
)
{
return
list
[
0
].
PlateH
;
}
LOGGER
.
Error
(
"GetComP2PlateH ["
+
currP
+
"] 未找到对应的盘高"
);
return
8
;
//查找最相似的盘高
int
height
=
8
;
list
=
(
from
com
in
ComP2List
orderby
com
.
PlateH
descending
select
com
).
ToList
<
ComP2Info
>();
foreach
(
ComP2Info
comp2
in
list
)
{
if
(
currP
<=
comp2
.
MinComP
)
{
height
=
comp2
.
PlateH
+
4
;
break
;
}
}
if
(
currP
>
CompAxis_P4_Position
)
{
height
=
8
;
}
LOGGER
.
Error
(
"GetComP2PlateH ["
+
currP
+
"] 未找到对应的盘高,使用相似盘高 ["
+
height
+
"]"
);
return
height
;
}
public
void
UpdateComP2
(
int
height
,
ComP2Info
p2Info
)
...
...
@@ -608,8 +635,15 @@ namespace OnlineStore.LoadCSVLibrary
if
(
pArray
.
Length
.
Equals
(
2
))
{
int
minP
=
Convert
.
ToInt32
(
pArray
[
0
]);
int
maxP
=
Convert
.
ToInt32
(
pArray
[
1
]);
ComP2List
.
Add
(
new
ComP2Info
(
plateH
,
minP
,
maxP
));
int
maxP
=
Convert
.
ToInt32
(
pArray
[
1
]);
if
(
minP
>
CompAxis_P1_Position
&&
maxP
>
CompAxis_P1_Position
)
{
ComP2List
.
Add
(
new
ComP2Info
(
plateH
,
minP
,
maxP
));
}
else
{
LOGGER
.
Error
(
DeviceID
+
"压紧轴P2 盘高【"
+
plateH
+
"】范围【"
+
minP
+
"~"
+
maxP
+
"】无效,位置小于待机点P1【"
+
CompAxis_P1_Position
+
"】"
);
}
}
}
}
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论