固化室增加7002.0,VW7000.1=1且V7002.0=0开始固化

This commit is contained in:
psh
2024-07-01 09:27:05 +08:00
parent ef163770e9
commit 4a7bf4d5f1
2 changed files with 25 additions and 7 deletions

View File

@@ -53,6 +53,9 @@ public class GuhuashiSiteDeviceDriver extends AbstractOpcDeviceDriver implements
String devicecode;
private Date instruction_require_time = new Date();
private int instruction_require_time_out = 60000;
@Override
public Device getDevice() {
@@ -88,6 +91,7 @@ public class GuhuashiSiteDeviceDriver extends AbstractOpcDeviceDriver implements
int VW70005 = 0;
int VW70006 = 0;
int VW70007 = 0;
int VW70020 = 0;
int last_VW7010 = 0;
int last_VW7012 = 0;
@@ -118,6 +122,7 @@ public class GuhuashiSiteDeviceDriver extends AbstractOpcDeviceDriver implements
int last_VW70005 = 0;
int last_VW70006 = 0;
int last_VW70007 = 0;
int last_VW70020 = 0;
@Override
@@ -154,14 +159,21 @@ public class GuhuashiSiteDeviceDriver extends AbstractOpcDeviceDriver implements
VW70005 = this.itemProtocol.getVW70005();
VW70006 = this.itemProtocol.getVW70006();
VW70007 = this.itemProtocol.getVW70007();
VW70020 = this.itemProtocol.getVW70020();
if (VW70001 != last_VW70001 && VW70001 == 1) {
log.info("固化室{}反馈工艺运行中开始通知lms", devicecode);
FeedBackTaskStatusRequest request = new FeedBackTaskStatusRequest();
request.setDevice_code(this.devicecode);
request.setType("1");
request.setState("4");
acsToWmsService.notify(request);
if (VW70001 == 1 &&VW70020 == 0) {
Date date = new Date();
if (date.getTime() - this.instruction_require_time.getTime() < (long) this.instruction_require_time_out) {
log.trace("触发时间因为小于{}毫秒,而被无视", this.instruction_require_time_out);
}else {
this.instruction_require_time = date;
log.info("固化室{}反馈工艺运行中开始通知lms", devicecode);
FeedBackTaskStatusRequest request = new FeedBackTaskStatusRequest();
request.setDevice_code(this.devicecode);
request.setType("1");
request.setState("4");
acsToWmsService.notify(request);
}
}
if (VW70002 != last_VW70002 && VW70002 == 1) {

View File

@@ -41,6 +41,7 @@ public class ItemProtocol {
public static String item_VW70005 = "VW70005";
public static String item_VW70006 = "VW70006";
public static String item_VW70007 = "VW70007";
public static String item_VW70020 = "VW70020";
//写入信号
public static String item_VW70040 = "VW70040";
@@ -168,6 +169,10 @@ public class ItemProtocol {
return this.getOpcIntegerValue(item_VW70007);
}
public int getVW70020() {
return this.getOpcIntegerValue(item_VW70020);
}
Boolean isonline;
@@ -235,6 +240,7 @@ public class ItemProtocol {
list.add(new ItemDto(item_VW70005, "固化室前门已关信号", "VW7000.5"));
list.add(new ItemDto(item_VW70006, "固化室后门已开信号", "VW7000.6"));
list.add(new ItemDto(item_VW70007, "固化室后门已关信号", "VW7000.7"));
list.add(new ItemDto(item_VW70020, "固化室工艺信号0-正常1-保湿", "VW7002.0"));
return list;
}