Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
李娜
/
SO827-AssemblyLine
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
图表
网络
创建新的问题
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit b988774b
由
LN
编写于
2021-09-08 15:04:43 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
安全门禁功能修改
1 个父辈
85534731
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
52 行增加
和
10 行删除
source/AssemblyLineClient/FrmFeedingEquip.Designer.cs
source/AssemblyLineClient/FrmFeedingEquip.cs
source/DeviceLibrary/assemblyLine/EquipBase.cs
source/AssemblyLineClient/FrmFeedingEquip.Designer.cs
查看文件 @
b988774
...
...
@@ -100,6 +100,7 @@
this
.
btnMoveto
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
txtSizePosition
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
btnScan
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
chbUse
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
panBase
.
SuspendLayout
();
this
.
groupBox1
.
SuspendLayout
();
this
.
groupBox4
.
SuspendLayout
();
...
...
@@ -118,6 +119,7 @@
//
// panBase
//
this
.
panBase
.
Controls
.
Add
(
this
.
chbUse
);
this
.
panBase
.
Controls
.
Add
(
this
.
btnScan
);
this
.
panBase
.
Size
=
new
System
.
Drawing
.
Size
(
996
,
50
);
this
.
panBase
.
Controls
.
SetChildIndex
(
this
.
chbMoveStop
,
0
);
...
...
@@ -130,6 +132,7 @@
this
.
panBase
.
Controls
.
SetChildIndex
(
this
.
lblName
,
0
);
this
.
panBase
.
Controls
.
SetChildIndex
(
this
.
btnExit
,
0
);
this
.
panBase
.
Controls
.
SetChildIndex
(
this
.
chbDebug
,
0
);
this
.
panBase
.
Controls
.
SetChildIndex
(
this
.
chbUse
,
0
);
//
// btnExit
//
...
...
@@ -137,12 +140,12 @@
//
// chbDebug
//
this
.
chbDebug
.
Location
=
new
System
.
Drawing
.
Point
(
461
,
1
2
);
this
.
chbDebug
.
Location
=
new
System
.
Drawing
.
Point
(
461
,
1
3
);
this
.
chbDebug
.
CheckedChanged
+=
new
System
.
EventHandler
(
this
.
chbDebug_CheckedChanged
);
//
// lblStoreStatus
//
this
.
lblStoreStatus
.
Location
=
new
System
.
Drawing
.
Point
(
639
,
14
);
this
.
lblStoreStatus
.
Location
=
new
System
.
Drawing
.
Point
(
734
,
15
);
//
// btnOutStore
//
...
...
@@ -155,6 +158,7 @@
//
// btnInStore
//
this
.
btnInStore
.
Location
=
new
System
.
Drawing
.
Point
(
456
,
5
);
this
.
btnInStore
.
Visible
=
false
;
//
// btnStop
...
...
@@ -163,7 +167,7 @@
//
// chbMoveStop
//
this
.
chbMoveStop
.
Location
=
new
System
.
Drawing
.
Point
(
5
50
,
12
);
this
.
chbMoveStop
.
Location
=
new
System
.
Drawing
.
Point
(
5
47
,
13
);
this
.
chbMoveStop
.
CheckedChanged
+=
new
System
.
EventHandler
(
this
.
chbMoveStop_CheckedChanged
);
//
// timer1
...
...
@@ -1276,6 +1280,17 @@
this
.
btnScan
.
UseVisualStyleBackColor
=
false
;
this
.
btnScan
.
Click
+=
new
System
.
EventHandler
(
this
.
btnScan_Click
);
//
// chbUse
//
this
.
chbUse
.
AutoSize
=
true
;
this
.
chbUse
.
Location
=
new
System
.
Drawing
.
Point
(
633
,
15
);
this
.
chbUse
.
Name
=
"chbUse"
;
this
.
chbUse
.
Size
=
new
System
.
Drawing
.
Size
(
99
,
21
);
this
.
chbUse
.
TabIndex
=
263
;
this
.
chbUse
.
Text
=
"启用安全门禁"
;
this
.
chbUse
.
UseVisualStyleBackColor
=
true
;
this
.
chbUse
.
CheckedChanged
+=
new
System
.
EventHandler
(
this
.
chbUse_CheckedChanged
);
//
// FrmFeedingEquip
//
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
7F
,
17F
);
...
...
@@ -1403,6 +1418,7 @@
private
useControl
.
ClampJawControl
clampJawControl1
;
private
System
.
Windows
.
Forms
.
Button
btnHlhasReel
;
private
System
.
Windows
.
Forms
.
CheckBox
chbPointEdit
;
private
System
.
Windows
.
Forms
.
CheckBox
chbUse
;
}
}
source/AssemblyLineClient/FrmFeedingEquip.cs
查看文件 @
b988774
...
...
@@ -270,6 +270,7 @@ namespace OnlineStore.AssemblyLine
lblTargetP3
.
Text
=
"目标P3:"
+
equipBean
.
Config
.
BatchAxisP3
;
lblTestMsg
.
Text
=
""
;
TargetP3
=
equipBean
.
Config
.
BatchAxisP3
;
chbUse
.
Checked
=
equipBean
.
UseSecurityAccess
;
PointEdit
(
false
);
IsLoad
=
true
;
...
...
@@ -911,6 +912,17 @@ namespace OnlineStore.AssemblyLine
}
chbPointEdit
.
Checked
=
false
;
}
private
void
chbUse_CheckedChanged
(
object
sender
,
EventArgs
e
)
{
if
(!
IsLoad
)
{
return
;
}
equipBean
.
UseSecurityAccess
=
chbUse
.
Checked
;
LogUtil
.
info
(
equipBean
.
Name
+
"用户切换是否启用安全门禁: "
+
equipBean
.
UseSecurityAccess
);
}
}
}
...
...
source/DeviceLibrary/assemblyLine/EquipBase.cs
查看文件 @
b988774
...
...
@@ -13,6 +13,7 @@ namespace OnlineStore.DeviceLibrary
{
public
abstract
class
EquipBase
:
KTK_Store
{
public
bool
UseSecurityAccess
=
true
;
public
bool
OnlyProOutTray
=
false
;
public
ClampJawBean
ClampJwa
=
null
;
public
bool
MoveStop
=
false
;
...
...
@@ -852,7 +853,7 @@ namespace OnlineStore.DeviceLibrary
return
;
}
if
(
CurrSecurityAccess
.
Equals
(
0
)
&&
LineManager
.
UseSecurityAccess
)
if
(
CurrSecurityAccess
.
Equals
(
0
)
&&
LineManager
.
UseSecurityAccess
&&
UseSecurityAccess
)
{
if
(
IOValue
(
IO_Type
.
SecurityAccess
).
Equals
(
IO_VALUE
.
LOW
))
{
...
...
@@ -897,12 +898,21 @@ namespace OnlineStore.DeviceLibrary
{
if
(
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
None
))
{
LogUtil
.
info
(
$
"{Name }安全门禁 { di.Explain} 被打开,停止当前运动{MoveInfo.MoveType},MoveStop={MoveStop},报警急停"
);
SetWarnMsg
(
"安全门禁被打开,报警急停"
);
Alarm
(
LineAlarmType
.
SuddenStop
);
MoveStop
=
true
;
string
msg
=
""
;
if
(
UseAxis
)
{
UpdownAxis
.
SuddenStop
();
msg
+=
$
"停止轴{UpdownAxis.Config.Explain};"
;
}
SetWarnMsg
(
"安全门禁被打开,暂停运动"
);
LogUtil
.
info
(
$
"{Name }安全门禁 { di.Explain} 被打开,暂停运动,MoveStop={MoveStop},{msg},稍后复位"
);
//LogUtil.info($"{Name }安全门禁 { di.Explain} 被打开,停止当前运动{MoveInfo.MoveType},MoveStop={MoveStop},报警急停");
//SetWarnMsg("安全门禁被打开,报警急停");
//Alarm(LineAlarmType.SuddenStop);
}
else
{
{
MoveStop
=
true
;
LogUtil
.
info
(
$
"{Name }安全门禁 { di.Explain} 被打开,停止当前运动{MoveInfo.MoveType},MoveStop={MoveStop},稍后复位"
);
SetWarnMsg
(
"安全门禁被打开,暂停当前运动"
);
...
...
@@ -920,7 +930,7 @@ namespace OnlineStore.DeviceLibrary
msg
+=
$
"停止轴{UpdownAxis.Config.Explain};"
;
}
LogUtil
.
info
(
$
"{Name }安全门禁 { di.Explain} 被打开,停止当前运动{MoveInfo.MoveType},{MoveInfo.MoveStep},{msg},稍后复位"
);
}
}
}
}
...
...
@@ -941,8 +951,12 @@ namespace OnlineStore.DeviceLibrary
if
(
baseConfig
.
DType
.
Equals
(
DeviceType
.
MoveEquip
))
{
LogUtil
.
info
(
$
"{Name }安全门禁 { di.Explain} 已关闭,恢复当前运动{MoveInfo.MoveType},MoveStop={MoveStop}"
);
if
(
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
InStore
)
||
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
OutStore
))
if
(
WarnMsg
.
Contains
(
"安全门禁被打开,暂停"
))
{
SetWarnMsg
(
""
);
}
if
(!
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
None
))
{
string
msg
=
""
;
Dictionary
<
string
,
IO_VALUE
>
values
=
MoveInfo
.
WriteDoMap
;
foreach
(
string
key
in
values
.
Keys
)
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论