Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
李娜
/
RC1271-DUOStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 181d32e7
由
LN
编写于
2020-08-11 13:38:44 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
出入库逻辑
1 个父辈
c1af307d
全部展开
显示空白字符变更
内嵌
并排
正在显示
11 个修改的文件
包含
117 行增加
和
112 行删除
source/DUOStore/FrmBox.Designer.cs
source/DUOStore/FrmBox.cs
source/DUOStore/FrmStore.cs
source/DUOStore/记录.txt
source/DeviceLibrary/duoStore/BoxBean.cs
source/DeviceLibrary/duoStore/BoxBean_Partial.cs
source/DeviceLibrary/duoStore/BoxBean_Shelf.cs
source/DeviceLibrary/duoStore/DUOStoreBean.cs
source/DeviceLibrary/duoStore/DUOStoreBean_Partial.cs
source/DeviceLibrary/duoStore/HumitureBean.cs
source/DeviceLibrary/store/AutoInoutInfo.cs
source/DUOStore/FrmBox.Designer.cs
查看文件 @
181d32e
...
@@ -109,6 +109,7 @@ namespace OnlineStore.DUOStore
...
@@ -109,6 +109,7 @@ namespace OnlineStore.DUOStore
this
.
btnStoreStart
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnStoreStart
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
lblWarnMsg
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
lblWarnMsg
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
lblThisSta
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
lblThisSta
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
lblCanOut
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
groupBox4
.
SuspendLayout
();
this
.
groupBox4
.
SuspendLayout
();
this
.
groupBox1
.
SuspendLayout
();
this
.
groupBox1
.
SuspendLayout
();
this
.
tabControl1
.
SuspendLayout
();
this
.
tabControl1
.
SuspendLayout
();
...
@@ -1238,6 +1239,7 @@ namespace OnlineStore.DUOStore
...
@@ -1238,6 +1239,7 @@ namespace OnlineStore.DUOStore
//
//
this
.
groupBox3
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)(((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)
this
.
groupBox3
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)(((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
groupBox3
.
Controls
.
Add
(
this
.
lblCanOut
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
lblMoveEquipInfo
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
lblMoveEquipInfo
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
btnSotreReset
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
btnSotreReset
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
btnStoreStop
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
btnStoreStop
);
...
@@ -1303,7 +1305,7 @@ namespace OnlineStore.DUOStore
...
@@ -1303,7 +1305,7 @@ namespace OnlineStore.DUOStore
this
.
lblWarnMsg
.
ForeColor
=
System
.
Drawing
.
Color
.
Red
;
this
.
lblWarnMsg
.
ForeColor
=
System
.
Drawing
.
Color
.
Red
;
this
.
lblWarnMsg
.
Location
=
new
System
.
Drawing
.
Point
(
407
,
14
);
this
.
lblWarnMsg
.
Location
=
new
System
.
Drawing
.
Point
(
407
,
14
);
this
.
lblWarnMsg
.
Name
=
"lblWarnMsg"
;
this
.
lblWarnMsg
.
Name
=
"lblWarnMsg"
;
this
.
lblWarnMsg
.
Size
=
new
System
.
Drawing
.
Size
(
662
,
84
);
this
.
lblWarnMsg
.
Size
=
new
System
.
Drawing
.
Size
(
662
,
50
);
this
.
lblWarnMsg
.
TabIndex
=
224
;
this
.
lblWarnMsg
.
TabIndex
=
224
;
this
.
lblWarnMsg
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
this
.
lblWarnMsg
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
//
//
...
@@ -1318,6 +1320,17 @@ namespace OnlineStore.DUOStore
...
@@ -1318,6 +1320,17 @@ namespace OnlineStore.DUOStore
this
.
lblThisSta
.
TabIndex
=
216
;
this
.
lblThisSta
.
TabIndex
=
216
;
this
.
lblThisSta
.
Text
=
"等待启动"
;
this
.
lblThisSta
.
Text
=
"等待启动"
;
//
//
// lblCanOut
//
this
.
lblCanOut
.
AutoSize
=
true
;
this
.
lblCanOut
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Bold
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblCanOut
.
ForeColor
=
System
.
Drawing
.
Color
.
Green
;
this
.
lblCanOut
.
Location
=
new
System
.
Drawing
.
Point
(
949
,
74
);
this
.
lblCanOut
.
Name
=
"lblCanOut"
;
this
.
lblCanOut
.
Size
=
new
System
.
Drawing
.
Size
(
51
,
19
);
this
.
lblCanOut
.
TabIndex
=
273
;
this
.
lblCanOut
.
Text
=
"可出库"
;
//
// FrmBox
// FrmBox
//
//
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
96F
,
96F
);
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
96F
,
96F
);
...
@@ -1442,6 +1455,7 @@ namespace OnlineStore.DUOStore
...
@@ -1442,6 +1455,7 @@ namespace OnlineStore.DUOStore
public
System
.
Windows
.
Forms
.
Button
btnUpDownP4
;
public
System
.
Windows
.
Forms
.
Button
btnUpDownP4
;
private
System
.
Windows
.
Forms
.
Button
btnSingleOut
;
private
System
.
Windows
.
Forms
.
Button
btnSingleOut
;
private
System
.
Windows
.
Forms
.
Button
btnNgPro
;
private
System
.
Windows
.
Forms
.
Button
btnNgPro
;
private
System
.
Windows
.
Forms
.
Label
lblCanOut
;
}
}
}
}
source/DUOStore/FrmBox.cs
查看文件 @
181d32e
...
@@ -132,6 +132,7 @@ namespace OnlineStore.DUOStore
...
@@ -132,6 +132,7 @@ namespace OnlineStore.DUOStore
lblMoveEquipInfo
.
Text
=
""
;
lblMoveEquipInfo
.
Text
=
""
;
// lblMoveEquipInfo.Text = "";
// lblMoveEquipInfo.Text = "";
}
}
lblCanOut
.
Text
=
StoreManager
.
Store
.
CanOut
()
?
"可出库"
:
"不可出库"
;
//ReadPosistion();
//ReadPosistion();
if
(
BoxBean
.
runStatus
>
StoreRunStatus
.
Wait
)
if
(
BoxBean
.
runStatus
>
StoreRunStatus
.
Wait
)
{
{
...
@@ -660,9 +661,9 @@ namespace OnlineStore.DUOStore
...
@@ -660,9 +661,9 @@ namespace OnlineStore.DUOStore
private
void
btnSelTemp_Click
(
object
sender
,
EventArgs
e
)
private
void
btnSelTemp_Click
(
object
sender
,
EventArgs
e
)
{
{
//
HumitureParam param = BoxBean.humBean.QueryData();
HumitureParam
param
=
BoxBean
.
humBean
.
QueryData
();
//
txtTemp.Text = param.Temperate.ToString();
txtTemp
.
Text
=
param
.
Temperate
.
ToString
();
//
txtHum.Text = param.Humidity.ToString();
txtHum
.
Text
=
param
.
Humidity
.
ToString
();
}
}
internal
void
DebugStatus
(
bool
isDebug
)
internal
void
DebugStatus
(
bool
isDebug
)
...
...
source/DUOStore/FrmStore.cs
查看文件 @
181d32e
source/DUOStore/记录.txt
查看文件 @
181d32e
多料仓软件。
多料仓软件。
有温湿度传感器,不需要吹氮气。
...
...
source/DeviceLibrary/duoStore/BoxBean.cs
查看文件 @
181d32e
...
@@ -16,19 +16,15 @@ namespace OnlineStore.DeviceLibrary
...
@@ -16,19 +16,15 @@ namespace OnlineStore.DeviceLibrary
{
{
public
partial
class
BoxBean
:
EquipBase
public
partial
class
BoxBean
:
EquipBase
{
{
private
bool
IsIntSlvBlock
=
false
;
public
AutoInoutInfo
AutoInout
=
new
AutoInoutInfo
();
public
AutoInoutInfo
AutoInout
=
new
AutoInoutInfo
();
public
string
CID
=
""
;
public
string
CID
=
""
;
public
BOX_Config
Config
;
public
BOX_Config
Config
;
public
string
lastPosId
=
""
;
public
string
lastPosId
=
""
;
public
StoreStatus
lastPosIdStatus
=
StoreStatus
.
StoreOnline
;
public
StoreStatus
lastPosIdStatus
=
StoreStatus
.
StoreOnline
;
public
List
<
ConfigMoveAxis
>
moveAxisList
=
new
List
<
ConfigMoveAxis
>();
private
List
<
ConfigMoveAxis
>
moveAxisList
=
new
List
<
ConfigMoveAxis
>();
public
List
<
string
>
PositionNumList
=
new
List
<
string
>();
public
List
<
string
>
PositionNumList
=
new
List
<
string
>();
public
HumitureBean
humBean
=
null
;
public
HumitureBean
humBean
=
null
;
public
AxisBean
UpdownAxis
=
null
;
public
AxisBean
UpdownAxis
=
null
;
public
AxisBean
MiddleAxis
=
null
;
public
AxisBean
MiddleAxis
=
null
;
public
AxisBean
ComAxis
=
null
;
public
AxisBean
ComAxis
=
null
;
...
@@ -94,7 +90,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -94,7 +90,7 @@ namespace OnlineStore.DeviceLibrary
}
}
}
}
}
}
public
void
MoveAxisConfig
()
internal
void
MoveAxisConfig
()
{
{
Config
.
UpDown_Axis
.
BreakOnDO
=
IO_Type
.
UpdownAxis_Break
;
Config
.
UpDown_Axis
.
BreakOnDO
=
IO_Type
.
UpdownAxis_Break
;
moveAxisList
=
new
List
<
ConfigMoveAxis
>();
moveAxisList
=
new
List
<
ConfigMoveAxis
>();
...
@@ -103,6 +99,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -103,6 +99,8 @@ namespace OnlineStore.DeviceLibrary
moveAxisList
.
Add
(
Config
.
InOut_Axis
);
moveAxisList
.
Add
(
Config
.
InOut_Axis
);
moveAxisList
.
Add
(
Config
.
Comp_Axis
);
moveAxisList
.
Add
(
Config
.
Comp_Axis
);
}
}
public
override
bool
StartRun
(
bool
isDebug
=
false
)
public
override
bool
StartRun
(
bool
isDebug
=
false
)
{
{
if
(!
StoreManager
.
Store
.
canStart
)
if
(!
StoreManager
.
Store
.
canStart
)
...
@@ -281,6 +279,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -281,6 +279,7 @@ namespace OnlineStore.DeviceLibrary
TimeSpan
span
=
DateTime
.
Now
-
StartTime
;
TimeSpan
span
=
DateTime
.
Now
-
StartTime
;
LogInfo
(
",停止运行,总运行时间:"
+
span
.
ToString
());
LogInfo
(
",停止运行,总运行时间:"
+
span
.
ToString
());
}
}
public
override
void
Alarm
(
AlarmType
alarmType
,
string
alarmDetial
=
""
,
string
alarmMsg
=
""
,
MoveType
storeMoveType
=
MoveType
.
None
)
public
override
void
Alarm
(
AlarmType
alarmType
,
string
alarmDetial
=
""
,
string
alarmMsg
=
""
,
MoveType
storeMoveType
=
MoveType
.
None
)
{
{
base
.
Alarm
(
alarmType
,
alarmDetial
,
alarmMsg
,
storeMoveType
);
base
.
Alarm
(
alarmType
,
alarmDetial
,
alarmMsg
,
storeMoveType
);
...
...
source/DeviceLibrary/duoStore/BoxBean_Partial.cs
查看文件 @
181d32e
此文件的差异被折叠,
点击展开。
source/DeviceLibrary/duoStore/BoxBean_Shelf.cs
查看文件 @
181d32e
...
@@ -34,15 +34,26 @@ namespace OnlineStore.DeviceLibrary
...
@@ -34,15 +34,26 @@ namespace OnlineStore.DeviceLibrary
lastConTime
=
DateTime
.
Now
;
lastConTime
=
DateTime
.
Now
;
try
try
{
{
//HumitureController.QueryData();
humBean
.
HumidityProcess
(
this
);
humBean
.
HumidityProcess
(
this
);
if
(
StoreManager
.
IsConnectServer
)
if
(
StoreManager
.
IsConnectServer
)
{
{
SendLineStatus
();
SendLineStatus
();
}
//出料口状态灯处理
OutDoorLedProcess
();
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
Name
+
"定时SendLineStatus出错:"
+
ex
.
ToString
());
}
finally
{
isInProcess
=
false
;
}
}
}
private
void
OutDoorLedProcess
()
{
if
(
OutDoorReelType
.
Equals
(
1
))
if
(
OutDoorReelType
.
Equals
(
1
))
{
{
IOMove
(
IO_Type
.
DoorLed_Red
,
IO_VALUE
.
LOW
,
true
);
IOMove
(
IO_Type
.
DoorLed_Red
,
IO_VALUE
.
LOW
,
true
);
...
@@ -73,15 +84,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -73,15 +84,6 @@ namespace OnlineStore.DeviceLibrary
IOMove
(
IO_Type
.
DoorLed_Red
,
IO_VALUE
.
LOW
,
true
);
IOMove
(
IO_Type
.
DoorLed_Red
,
IO_VALUE
.
LOW
,
true
);
}
}
}
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
Name
+
"定时SendLineStatus出错:"
+
ex
.
ToString
());
}
finally
{
isInProcess
=
false
;
}
}
/// <summary>
/// <summary>
/// 获取整个料仓的状态
/// 获取整个料仓的状态
...
...
source/DeviceLibrary/duoStore/DUOStoreBean.cs
查看文件 @
181d32e
...
@@ -17,7 +17,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -17,7 +17,7 @@ namespace OnlineStore.DeviceLibrary
{
{
public
partial
class
DUOStoreBean
:
EquipBase
public
partial
class
DUOStoreBean
:
EquipBase
{
{
public
Dictionary
<
int
,
BOX_Config
>
BoxConfigMap
{
get
;
set
;
}
internal
Dictionary
<
int
,
BOX_Config
>
BoxConfigMap
{
get
;
set
;
}
public
Dictionary
<
int
,
BoxBean
>
BoxMap
=
new
Dictionary
<
int
,
BoxBean
>();
public
Dictionary
<
int
,
BoxBean
>
BoxMap
=
new
Dictionary
<
int
,
BoxBean
>();
public
Store_Config
Config
{
get
;
set
;
}
public
Store_Config
Config
{
get
;
set
;
}
...
@@ -149,11 +149,9 @@ namespace OnlineStore.DeviceLibrary
...
@@ -149,11 +149,9 @@ namespace OnlineStore.DeviceLibrary
//停止运动
//停止运动
MoveInfo
.
EndMove
();
MoveInfo
.
EndMove
();
runStatus
=
StoreRunStatus
.
Reset
;
runStatus
=
StoreRunStatus
.
Reset
;
StartResetMove
();
StartResetMove
();
foreach
(
BoxBean
equip
in
BoxMap
.
Values
)
foreach
(
BoxBean
equip
in
BoxMap
.
Values
)
{
{
if
(!
equip
.
alarmType
.
Equals
(
AlarmType
.
None
))
if
(!
equip
.
alarmType
.
Equals
(
AlarmType
.
None
))
...
@@ -188,7 +186,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -188,7 +186,6 @@ namespace OnlineStore.DeviceLibrary
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Line_Stop2_Work
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Line_Stop2_Work
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Line_Stop3_Buffer
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Line_Stop3_Buffer
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Line_Stop4_Out
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Line_Stop4_Out
,
IO_VALUE
.
LOW
));
}
}
protected
override
void
ResetProcess
()
protected
override
void
ResetProcess
()
...
@@ -221,7 +218,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -221,7 +218,7 @@ namespace OnlineStore.DeviceLibrary
else
if
(
MoveInfo
.
IsStep
(
StoreMoveStep
.
LR_03_BatchAxisHome
))
else
if
(
MoveInfo
.
IsStep
(
StoreMoveStep
.
LR_03_BatchAxisHome
))
{
{
MoveInfo
.
NextMoveStep
(
StoreMoveStep
.
LR_04_BatchToP1
);
MoveInfo
.
NextMoveStep
(
StoreMoveStep
.
LR_04_BatchToP1
);
LogUtil
.
info
(
Name
+
"复位 "
+
MoveInfo
.
MoveStep
+
" :提升轴到P1点
,上下轴到待机点P2
"
);
LogUtil
.
info
(
Name
+
"复位 "
+
MoveInfo
.
MoveStep
+
" :提升轴到P1点
["
+
Config
.
BatchAxis_P1
+
"],上下轴到待机点P2["
+
Config
.
UpdownAxis_P2
+
"]
"
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
1000
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
1000
));
T1_BatchAxis
.
AbsMove
(
MoveInfo
,
Config
.
BatchAxis_P1
,
Config
.
BatchAxis_P1Speed
);
T1_BatchAxis
.
AbsMove
(
MoveInfo
,
Config
.
BatchAxis_P1
,
Config
.
BatchAxis_P1Speed
);
T3_UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
UpdownAxis_P2
,
Config
.
UpdownAxis_P2Speed
);
T3_UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
UpdownAxis_P2
,
Config
.
UpdownAxis_P2Speed
);
...
@@ -238,10 +235,10 @@ namespace OnlineStore.DeviceLibrary
...
@@ -238,10 +235,10 @@ namespace OnlineStore.DeviceLibrary
else
if
(
MoveInfo
.
IsStep
(
StoreMoveStep
.
LR_05_Hoister_Back
))
else
if
(
MoveInfo
.
IsStep
(
StoreMoveStep
.
LR_05_Hoister_Back
))
{
{
MoveInfo
.
NextMoveStep
(
StoreMoveStep
.
LR_06_TopDown
);
MoveInfo
.
NextMoveStep
(
StoreMoveStep
.
LR_06_TopDown
);
LogUtil
.
info
(
Name
+
"复位 "
+
MoveInfo
.
MoveStep
+
" :顶升气缸下降,旋转轴到待机点P1"
);
LogUtil
.
info
(
Name
+
"复位 "
+
MoveInfo
.
MoveStep
+
" :顶升气缸下降,旋转轴到待机点P1
["
+
Config
.
MiddleAxis_P1
+
"]
"
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
1000
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
1000
));
CylinderMove
(
MoveInfo
,
IO_Type
.
TopCylinder_Up
,
IO_Type
.
TopCylinder_Down
);
CylinderMove
(
MoveInfo
,
IO_Type
.
TopCylinder_Up
,
IO_Type
.
TopCylinder_Down
);
T2_MiddleAxis
.
AbsMove
(
MoveInfo
,
Config
.
MiddleAxis_P
2
,
Config
.
MiddleAxis_P2
Speed
);
T2_MiddleAxis
.
AbsMove
(
MoveInfo
,
Config
.
MiddleAxis_P
1
,
Config
.
MiddleAxis_P1
Speed
);
}
}
else
if
(
MoveInfo
.
IsStep
(
StoreMoveStep
.
LR_06_TopDown
))
else
if
(
MoveInfo
.
IsStep
(
StoreMoveStep
.
LR_06_TopDown
))
{
{
...
@@ -329,7 +326,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -329,7 +326,7 @@ namespace OnlineStore.DeviceLibrary
DateTime
time
=
DateTime
.
Now
;
DateTime
time
=
DateTime
.
Now
;
bool
isNeedAlarmLed
=
false
;
bool
isNeedAlarmLed
=
false
;
bool
isInOut
=
false
;
bool
isInOut
=
false
;
StoreRunStatus
runs
=
StoreRunStatus
.
Wait
;
bool
isReset
=
false
;
foreach
(
BoxBean
box
in
BoxMap
.
Values
)
foreach
(
BoxBean
box
in
BoxMap
.
Values
)
{
{
...
@@ -341,14 +338,14 @@ namespace OnlineStore.DeviceLibrary
...
@@ -341,14 +338,14 @@ namespace OnlineStore.DeviceLibrary
{
{
isInOut
=
true
;
isInOut
=
true
;
}
}
if
(
box
.
runStatus
>
runs
)
if
(
box
.
runStatus
.
Equals
(
StoreRunStatus
.
HomeMoving
)
||
box
.
runStatus
.
Equals
(
StoreRunStatus
.
Reset
)
)
{
{
runs
=
box
.
runStatus
;
isReset
=
true
;
}
}
}
}
//
黄灯
//
复位过程中黄灯闪烁
if
(
run
s
.
Equals
(
StoreRunStatus
.
HomeMoving
)
||
runs
.
Equals
(
StoreRunStatus
.
Reset
)
)
if
(
run
Status
.
Equals
(
StoreRunStatus
.
HomeMoving
)
||
runStatus
.
Equals
(
StoreRunStatus
.
Reset
)||
isReset
)
{
{
//开机执行中时黄灯闪烁
//开机执行中时黄灯闪烁
if
(
IsDoValue
(
IO_Type
.
RunSign_HddLed
,
IO_VALUE
.
HIGH
))
if
(
IsDoValue
(
IO_Type
.
RunSign_HddLed
,
IO_VALUE
.
HIGH
))
...
@@ -367,10 +364,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -367,10 +364,7 @@ namespace OnlineStore.DeviceLibrary
IOMove
(
IO_Type
.
RunSign_HddLed
,
IO_VALUE
.
LOW
);
IOMove
(
IO_Type
.
RunSign_HddLed
,
IO_VALUE
.
LOW
);
}
}
}
}
if
(
alarmType
.
Equals
(
AlarmType
.
None
).
Equals
(
false
)
||
isNoAirCheck
||
isInSuddenDown
)
{
isNeedAlarmLed
=
true
;
}
//忙碌中,判断是否有移栽在出入库执行,绿灯闪烁
//忙碌中,判断是否有移栽在出入库执行,绿灯闪烁
if
(
isInOut
)
if
(
isInOut
)
{
{
...
@@ -389,6 +383,10 @@ namespace OnlineStore.DeviceLibrary
...
@@ -389,6 +383,10 @@ namespace OnlineStore.DeviceLibrary
}
}
//报警中 ,红灯闪烁
//报警中 ,红灯闪烁
if
(
alarmType
.
Equals
(
AlarmType
.
None
).
Equals
(
false
)
||
isNoAirCheck
||
isInSuddenDown
)
{
isNeedAlarmLed
=
true
;
}
if
(
isNeedAlarmLed
)
if
(
isNeedAlarmLed
)
{
{
if
(
IsDoValue
(
IO_Type
.
Alarm_HddLed
,
IO_VALUE
.
LOW
))
if
(
IsDoValue
(
IO_Type
.
Alarm_HddLed
,
IO_VALUE
.
LOW
))
...
@@ -420,7 +418,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -420,7 +418,6 @@ namespace OnlineStore.DeviceLibrary
private
IO_VALUE
preAirValue
=
IO_VALUE
.
HIGH
;
private
IO_VALUE
preAirValue
=
IO_VALUE
.
HIGH
;
private
void
AirCheckProcess
()
private
void
AirCheckProcess
()
{
{
IO_VALUE
currAirValue
=
IOValue
(
IO_Type
.
Airpressure_Check
);
IO_VALUE
currAirValue
=
IOValue
(
IO_Type
.
Airpressure_Check
);
if
(
isInSuddenDown
)
if
(
isInSuddenDown
)
{
{
...
@@ -545,22 +542,20 @@ namespace OnlineStore.DeviceLibrary
...
@@ -545,22 +542,20 @@ namespace OnlineStore.DeviceLibrary
ShowTimeLog
(
"IOTimeOutProcess"
);
ShowTimeLog
(
"IOTimeOutProcess"
);
//判断是否需要处理料架入库
//判断是否需要处理料架入库
StartInStoreP
();
StartInStoreP
();
}
}
//检查运动轴报警
//检查运动轴报警
if
(
runStatus
>
StoreRunStatus
.
Wait
&&
(!
isInSuddenDown
)
&&
(!
isNoAirCheck
))
if
(
runStatus
>
StoreRunStatus
.
Wait
&&
(!
isInSuddenDown
)
&&
(!
isNoAirCheck
))
{
{
ShowTimeLog
(
"开始检测轴报警"
);
CheckAxisAlarm
(
new
AxisBean
[]
{
T1_BatchAxis
,
T2_MiddleAxis
,
T3_UpdownAxis
});
CheckAxisAlarm
(
new
AxisBean
[]
{
T1_BatchAxis
,
T2_MiddleAxis
,
T3_UpdownAxis
});
ShowTimeLog
(
"轴报警检测完成"
);
ShowTimeLog
(
"轴报警检测完成"
);
}
}
if
(
runStatus
.
Equals
(
StoreRunStatus
.
Runing
)
||
runStatus
.
Equals
(
StoreRunStatus
.
Busy
))
if
(
runStatus
.
Equals
(
StoreRunStatus
.
Runing
)
||
runStatus
.
Equals
(
StoreRunStatus
.
Busy
))
{
{
ShelfOutProcess
();
ShelfOutProcess
();
ShowTimeLog
(
"ShelfOutProcess"
);
}
}
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
...
...
source/DeviceLibrary/duoStore/DUOStoreBean_Partial.cs
查看文件 @
181d32e
此文件的差异被折叠,
点击展开。
source/DeviceLibrary/duoStore/HumitureBean.cs
查看文件 @
181d32e
...
@@ -69,32 +69,29 @@ namespace OnlineStore.DeviceLibrary
...
@@ -69,32 +69,29 @@ namespace OnlineStore.DeviceLibrary
public
string
currTempStr
=
""
;
public
string
currTempStr
=
""
;
internal
void
HumidityProcess
(
BoxBean
box
)
internal
void
HumidityProcess
(
BoxBean
box
)
{
{
//try
try
//{
{
// if ((DateTime.Now - preLogTime).TotalSeconds > 10)
if
((
DateTime
.
Now
-
preLogTime
).
TotalSeconds
>
10
)
// {
{
// preLogTime = DateTime.Now;
preLogTime
=
DateTime
.
Now
;
// //用最大的湿度判断是否需要吹气,开始吹气的值=发过来的值-4
HumitureParam
param
=
QueryData
();
// //温湿度
double
humidity
=
0
;
// //ASTemperateParam param = HumitureServer.GetTemperateParam(Config.GetTempAddrList());
double
temp
=
0
;
// HumitureParam param = QueryData();
if
(
param
!=
null
)
// double humidity = 0;
{
// double temp = 0;
humidity
=
param
.
Humidity
;
// if (param != null)
temp
=
param
.
Temperate
;
// {
currTempStr
=
Name
+
(
"湿度:"
+
humidity
.
ToString
()
+
",温度:"
+
temp
);
// humidity = param.Humidity;
}
// temp = param.Temperate;
//double currMaxHumidity = HumitureServer.GetMaxHumidity(Config.GetTempAddrList());
// currTempStr = Name + ("湿度:" + humidity.ToString() + ",温度:" + temp);
double
currMaxHumidity
=
param
.
Humidity
;
// }
float
startBlowHumidity
=
Max_Humidity
-
StartBlowValue
;
// //double currMaxHumidity = HumitureServer.GetMaxHumidity(Config.GetTempAddrList());
float
stopBlowHumidity
=
Max_Humidity
-
StopBlowValue
;
// double currMaxHumidity = param.Humidity;
// float startBlowHumidity = Max_Humidity - StartBlowValue;
// float stopBlowHumidity = Max_Humidity - StopBlowValue;
//
//判断是否需要吹气
//
//判断是否需要吹气
//
if (startBlowHumidity > 0 && startBlowHumidity < currMaxHumidity && IsInBlowing.Equals(false))
//
if (startBlowHumidity > 0 && startBlowHumidity < currMaxHumidity && IsInBlowing.Equals(false))
//
{
//
{
// //判断是否距离上次结束指定的时间
// //判断是否距离上次结束指定的时间
// TimeSpan span = DateTime.Now - LastEndBlowTime;
// TimeSpan span = DateTime.Now - LastEndBlowTime;
// if (span.TotalMinutes > StoreManager.Config.BlowAir_Interval)
// if (span.TotalMinutes > StoreManager.Config.BlowAir_Interval)
...
@@ -106,17 +103,17 @@ namespace OnlineStore.DeviceLibrary
...
@@ -106,17 +103,17 @@ namespace OnlineStore.DeviceLibrary
// LastBeginBlowTime = DateTime.Now;
// LastBeginBlowTime = DateTime.Now;
// LastEndBlowTime = DateTime.Now;
// LastEndBlowTime = DateTime.Now;
// }
// }
//
}
//
}
//
if (IsInBlowing && stopBlowHumidity > currMaxHumidity)
//
if (IsInBlowing && stopBlowHumidity > currMaxHumidity)
//
{
//
{
// LogUtil.info(Name + "当前最大湿度:" + currMaxHumidity.ToString() + ",停止吹气湿度:" + stopBlowHumidity + ",停止吹气!");
// LogUtil.info(Name + "当前最大湿度:" + currMaxHumidity.ToString() + ",停止吹气湿度:" + stopBlowHumidity + ",停止吹气!");
// IsInBlowing = false;
// IsInBlowing = false;
// box.IOMove(IO_Type.StartOrStopBlow, IO_VALUE.LOW);
// box.IOMove(IO_Type.StartOrStopBlow, IO_VALUE.LOW);
// LastEndBlowTime = DateTime.Now;
// LastEndBlowTime = DateTime.Now;
//
}
//
}
//
if (IsInBlowing)
//
if (IsInBlowing)
//
{
//
{
// //判断是否需要结束吹气
// //判断是否需要结束吹气
// TimeSpan span = DateTime.Now - LastBeginBlowTime;
// TimeSpan span = DateTime.Now - LastBeginBlowTime;
// if (span.TotalMinutes > StoreManager.Config.BlowAir_Time)
// if (span.TotalMinutes > StoreManager.Config.BlowAir_Time)
...
@@ -127,44 +124,42 @@ namespace OnlineStore.DeviceLibrary
...
@@ -127,44 +124,42 @@ namespace OnlineStore.DeviceLibrary
// box.IOMove(IO_Type.StartOrStopBlow, IO_VALUE.LOW);
// box.IOMove(IO_Type.StartOrStopBlow, IO_VALUE.LOW);
// LastEndBlowTime = DateTime.Now;
// LastEndBlowTime = DateTime.Now;
// }
// }
// }
//}
// bool needAlarm = false;
bool
needAlarm
=
false
;
// //如果开始吹气并且当前达到报警值
//如果开始吹气并且当前达到报警值
// if (IsInBlowing && humidity > Max_Humidity)
if
(
IsInBlowing
&&
humidity
>
Max_Humidity
)
// {
{
// needAlarm = true;
needAlarm
=
true
;
// }
}
// else if (temp > Max_Temperature && Max_Temperature > 0)
else
if
(
temp
>
Max_Temperature
&&
Max_Temperature
>
0
)
// {
{
// LogUtil.info(Name + "当前温度【" + param.Temperate + "】超过最高温度【" + Max_Temperature + "】,开始报警!");
LogUtil
.
info
(
Name
+
"当前温度【"
+
param
.
Temperate
+
"】超过最高温度【"
+
Max_Temperature
+
"】,开始报警!"
);
// needAlarm = true;
needAlarm
=
true
;
// //Thread.Sleep(100);
// box.IOMove(IO_Type.StartOrStopBlow, IO_VALUE.LOW);
// box.IOMove(IO_Type.StartOrStopBlow, IO_VALUE.LOW);
// }
}
// else if (temp < Max_Temperature)
else
if
(
temp
<
Max_Temperature
)
// {
{
// if (IsInBlowing.Equals(false) && TempOrHumidityIsAlarm)
if
(
IsInBlowing
.
Equals
(
false
)
&&
TempOrHumidityIsAlarm
)
// {
{
// LogUtil.info(Name + "不在吹气中,且当前温度【" + param.Temperate + "】低于【" + Max_Temperature + "】,关闭报警!");
LogUtil
.
info
(
Name
+
"不在吹气中,且当前温度【"
+
param
.
Temperate
+
"】低于【"
+
Max_Temperature
+
"】,关闭报警!"
);
// TempOrHumidityIsAlarm = false;
TempOrHumidityIsAlarm
=
false
;
// //Thread.Sleep(100);
// box.IOMove(IO_Type.StartOrStopBlow, IO_VALUE.LOW);
// box.IOMove(IO_Type.StartOrStopBlow, IO_VALUE.LOW);
//
}
}
//
}
}
//
else
else
//
{
{
//
TempOrHumidityIsAlarm = false;
TempOrHumidityIsAlarm
=
false
;
//
}
}
//
if (needAlarm)
if
(
needAlarm
)
//
{
{
//
HTAlarm();
HTAlarm
();
//
}
}
//
}
}
//
}
}
//
catch (Exception ex)
catch
(
Exception
ex
)
//
{
{
//
LogUtil.error(Name + "HumidityProcess出错:" + ex.ToString());
LogUtil
.
error
(
Name
+
"HumidityProcess出错:"
+
ex
.
ToString
());
//
}
}
}
}
private
void
HTAlarm
()
private
void
HTAlarm
()
{
{
...
...
source/DeviceLibrary/store/AutoInoutInfo.cs
查看文件 @
181d32e
...
@@ -75,9 +75,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -75,9 +75,7 @@ namespace OnlineStore.DeviceLibrary
positionIndex
=
newIndex
;
positionIndex
=
newIndex
;
string
posid
=
boxBean
.
PositionNumList
[
positionIndex
];
string
posid
=
boxBean
.
PositionNumList
[
positionIndex
];
InOutParam
param
=
new
InOutParam
(
MoveType
.
OutStore
,
"AutoOut"
,
posid
);
InOutParam
param
=
new
InOutParam
(
MoveType
.
OutStore
,
"AutoOut"
,
posid
,
1
);
//param.NeedOutShelf = false;
//param.NeedEnterShelf = false;
//判断是否需要重置
//判断是否需要重置
if
(
CurrInOutACount
>=
StoreManager
.
Config
.
Box_ResetACount
)
if
(
CurrInOutACount
>=
StoreManager
.
Config
.
Box_ResetACount
)
{
{
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论