Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
RC30-AutoInOutStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 438cc5b1
由
几米阳光
编写于
2019-03-05 17:17:19 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
界面增加启用调试的处理
1 个父辈
502503f2
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
58 行增加
和
18 行删除
source/ACSingleStore/FrmStoreBox.Designer.cs
source/ACSingleStore/FrmStoreBox.cs
source/Common/util/HumitureController.cs
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean.cs
source/ACSingleStore/FrmStoreBox.Designer.cs
查看文件 @
438cc5b
此文件的差异被折叠,
点击展开。
source/ACSingleStore/FrmStoreBox.cs
查看文件 @
438cc5b
...
@@ -234,7 +234,14 @@ namespace OnlineStore.AutoInOutStore
...
@@ -234,7 +234,14 @@ namespace OnlineStore.AutoInOutStore
LoadOk
=
true
;
LoadOk
=
true
;
cmbHomeType
.
SelectedIndex
=
1
;
cmbHomeType
.
SelectedIndex
=
1
;
timer1
.
Start
();
timer1
.
Start
();
store
.
ResetEvent
+=
Store_ResetEvent
;
}
}
private
void
Store_ResetEvent
()
{
DebugStatus
(
false
);
}
private
DateTime
preReadModblsTime
=
DateTime
.
Now
;
private
DateTime
preReadModblsTime
=
DateTime
.
Now
;
private
void
timer1_Tick
(
object
sender
,
EventArgs
e
)
private
void
timer1_Tick
(
object
sender
,
EventArgs
e
)
{
{
...
@@ -1264,18 +1271,7 @@ namespace OnlineStore.AutoInOutStore
...
@@ -1264,18 +1271,7 @@ namespace OnlineStore.AutoInOutStore
{
{
int
value
=
ACServerManager
.
GetHomeEndStatus
(
GetPortName
(),
GetSlaveAddr
());
int
value
=
ACServerManager
.
GetHomeEndStatus
(
GetPortName
(),
GetSlaveAddr
());
this
.
txtHomeStatus
.
Text
=
value
.
ToString
();
this
.
txtHomeStatus
.
Text
=
value
.
ToString
();
}
}
private
void
btnOpenWCF_Click
(
object
sender
,
EventArgs
e
)
{
//WCFControl.OpenWCF();
}
private
void
btnCloseWCF_Click
(
object
sender
,
EventArgs
e
)
{
//WCFControl.CloseWCF();
}
private
void
chbAuto_CheckedChanged
(
object
sender
,
EventArgs
e
)
private
void
chbAuto_CheckedChanged
(
object
sender
,
EventArgs
e
)
{
{
if
(!
LoadOk
)
if
(!
LoadOk
)
...
@@ -1303,6 +1299,7 @@ namespace OnlineStore.AutoInOutStore
...
@@ -1303,6 +1299,7 @@ namespace OnlineStore.AutoInOutStore
LogUtil
.
info
(
"切换界面显示时,没有正确输入密码"
);
LogUtil
.
info
(
"切换界面显示时,没有正确输入密码"
);
return
;
return
;
}
}
DebugStatus
(
false
);
this
.
Visible
=
true
;
this
.
Visible
=
true
;
this
.
WindowState
=
FormWindowState
.
Maximized
;
this
.
WindowState
=
FormWindowState
.
Maximized
;
this
.
notifyIcon1
.
Visible
=
false
;
this
.
notifyIcon1
.
Visible
=
false
;
...
@@ -1320,7 +1317,7 @@ namespace OnlineStore.AutoInOutStore
...
@@ -1320,7 +1317,7 @@ namespace OnlineStore.AutoInOutStore
{
{
stop_button_Click
(
null
,
null
);
stop_button_Click
(
null
,
null
);
}
}
store
.
Exit
();
KNDManager
.
CloseAllDO
();
KNDManager
.
CloseAllDO
();
StoreOpenStatus
(
false
);
StoreOpenStatus
(
false
);
KNDManager
.
CloseAllConnection
();
KNDManager
.
CloseAllConnection
();
...
@@ -1351,6 +1348,7 @@ namespace OnlineStore.AutoInOutStore
...
@@ -1351,6 +1348,7 @@ namespace OnlineStore.AutoInOutStore
this
.
ShowInTaskbar
=
false
;
this
.
ShowInTaskbar
=
false
;
this
.
notifyIcon1
.
Visible
=
true
;
this
.
notifyIcon1
.
Visible
=
true
;
this
.
Hide
();
this
.
Hide
();
DebugStatus
(
false
);
}
}
private
void
FrmStoreBox_FormClosed
(
object
sender
,
FormClosedEventArgs
e
)
private
void
FrmStoreBox_FormClosed
(
object
sender
,
FormClosedEventArgs
e
)
{
{
...
@@ -1673,6 +1671,33 @@ namespace OnlineStore.AutoInOutStore
...
@@ -1673,6 +1671,33 @@ namespace OnlineStore.AutoInOutStore
private
void
toolStripMenuItem5_Click
(
object
sender
,
EventArgs
e
)
private
void
toolStripMenuItem5_Click
(
object
sender
,
EventArgs
e
)
{
{
KND
.
IOMove
(
IO_Type
.
DisableDoorControl
,
IO_VALUE
.
LOW
);
KND
.
IOMove
(
IO_Type
.
DisableDoorControl
,
IO_VALUE
.
LOW
);
}
}
private
void
出入库调试
ToolStripMenuItem_Click
(
object
sender
,
EventArgs
e
)
{
if
(
出入库调试
ToolStripMenuItem
.
Text
.
Equals
(
"启用调试"
))
{
DebugStatus
(
true
);
}
else
{
DebugStatus
(
false
);
}
}
private
void
DebugStatus
(
bool
status
)
{
if
(
status
)
{
出入库调试
ToolStripMenuItem
.
Text
=
"禁用调试"
;
}
else
{
出入库调试
ToolStripMenuItem
.
Text
=
"启用调试"
;
}
groupAxis
.
Enabled
=
status
;
groupComAxis
.
Enabled
=
status
;
groupInout
.
Enabled
=
status
;
}
}
}
}
}
source/Common/util/HumitureController.cs
查看文件 @
438cc5b
...
@@ -64,7 +64,10 @@ namespace OnlineStore.Common
...
@@ -64,7 +64,10 @@ namespace OnlineStore.Common
/// </summary>
/// </summary>
public
static
void
Release
()
public
static
void
Release
()
{
{
sb
.
closePort
();
if
(
sb
!=
null
)
{
sb
.
closePort
();
}
IsRun
=
false
;
IsRun
=
false
;
}
}
public
static
ASTemperateParam
LastData
=
new
ASTemperateParam
(
0
,
0
);
public
static
ASTemperateParam
LastData
=
new
ASTemperateParam
(
0
,
0
);
...
...
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean.cs
查看文件 @
438cc5b
...
@@ -16,6 +16,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -16,6 +16,8 @@ namespace OnlineStore.DeviceLibrary
/// </summary>
/// </summary>
public
partial
class
AC_SA_BoxBean
:
AC_Store
public
partial
class
AC_SA_BoxBean
:
AC_Store
{
{
public
delegate
void
ResetDelegate
();
public
event
ResetDelegate
ResetEvent
;
private
bool
IsIntSlvBlock
=
false
;
private
bool
IsIntSlvBlock
=
false
;
//public bool UseBatchInout = true;
//public bool UseBatchInout = true;
public
string
CID
=
""
;
public
string
CID
=
""
;
...
@@ -268,6 +270,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -268,6 +270,7 @@ namespace OnlineStore.DeviceLibrary
#
region
原点返回和复位处理
#
region
原点返回和复位处理
private
void
ReturnHome
()
private
void
ReturnHome
()
{
{
ResetEvent
?.
Invoke
();
WarnMsg
=
""
;
WarnMsg
=
""
;
CurrInOutACount
=
0
;
CurrInOutACount
=
0
;
CurrInOutCount
=
0
;
CurrInOutCount
=
0
;
...
@@ -305,6 +308,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -305,6 +308,7 @@ namespace OnlineStore.DeviceLibrary
/// <param name="isNeedClearAuto">是否需要清理自动出入库</param>
/// <param name="isNeedClearAuto">是否需要清理自动出入库</param>
public
void
Reset
(
bool
isNeedClearAuto
)
public
void
Reset
(
bool
isNeedClearAuto
)
{
{
ResetEvent
?.
Invoke
();
CurrInOutCount
=
0
;
CurrInOutCount
=
0
;
CurrInOutACount
=
0
;
CurrInOutACount
=
0
;
...
@@ -345,7 +349,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -345,7 +349,7 @@ namespace OnlineStore.DeviceLibrary
LocationDownAndWait
();
LocationDownAndWait
();
}
}
AutomaticBaiting
.
Reset
(
false
);
AutomaticBaiting
.
Reset
(
false
);
isInPro
=
false
;
isInPro
=
false
;
}
}
private
void
InoutStartReset
()
private
void
InoutStartReset
()
{
{
...
@@ -753,7 +757,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -753,7 +757,7 @@ namespace OnlineStore.DeviceLibrary
StopMove
(
true
);
StopMove
(
true
);
storeRunStatus
=
StoreRunStatus
.
Wait
;
storeRunStatus
=
StoreRunStatus
.
Wait
;
mainTimer
.
Enabled
=
false
;
//
mainTimer.Enabled = false;
AutomaticBaiting
.
StopRun
();
AutomaticBaiting
.
StopRun
();
KNDManager
.
CloseAllDO
();
KNDManager
.
CloseAllDO
();
if
(
IsHasCompress_Axis
)
if
(
IsHasCompress_Axis
)
...
@@ -764,7 +768,14 @@ namespace OnlineStore.DeviceLibrary
...
@@ -764,7 +768,14 @@ namespace OnlineStore.DeviceLibrary
StoreManager
.
CurrInOutType
=
0
;
StoreManager
.
CurrInOutType
=
0
;
LogUtil
.
info
(
LOGGER
,
StoreName
+
",停止运行,总运行时间:"
+
runTimeWatch
.
Elapsed
.
ToString
());
LogUtil
.
info
(
LOGGER
,
StoreName
+
",停止运行,总运行时间:"
+
runTimeWatch
.
Elapsed
.
ToString
());
}
}
public
void
Exit
()
{
if
(!
storeRunStatus
.
Equals
(
StoreRunStatus
.
Wait
))
{
StopRun
();
}
mainTimer
.
Enabled
=
false
;
}
public
override
void
Alarm
(
StoreAlarmType
alarmType
,
string
alarmDetial
,
string
alarmMsg
,
StoreMoveType
storeMoveType
)
public
override
void
Alarm
(
StoreAlarmType
alarmType
,
string
alarmDetial
,
string
alarmMsg
,
StoreMoveType
storeMoveType
)
{
{
SaveAlarmInfo
(
alarmType
,
alarmDetial
,
alarmMsg
,
storeMoveType
);
SaveAlarmInfo
(
alarmType
,
alarmDetial
,
alarmMsg
,
storeMoveType
);
...
@@ -1338,6 +1349,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -1338,6 +1349,7 @@ namespace OnlineStore.DeviceLibrary
temp
=
param
.
Temperate
;
temp
=
param
.
Temperate
;
currTempStr
=
(
"当前湿度:"
+
humidity
.
ToString
()
+
",当前温度:"
+
temp
);
currTempStr
=
(
"当前湿度:"
+
humidity
.
ToString
()
+
",当前温度:"
+
temp
);
}
}
//LogUtil.info(currTempStr);
//double currMaxHumidity = HumitureServer.GetMaxHumidity(Config.GetTempAddrList());
//double currMaxHumidity = HumitureServer.GetMaxHumidity(Config.GetTempAddrList());
double
currMaxHumidity
=
param
.
Humidity
;
double
currMaxHumidity
=
param
.
Humidity
;
float
startBlowHumidity
=
Max_Humidity
-
StartBlowValue
;
float
startBlowHumidity
=
Max_Humidity
-
StartBlowValue
;
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论