@@ -82,6 +82,18 @@ public class DataUtil {
}
+ // 开始工作报文(工位)
+ public static Boolean startWorkByGw(NettyClient nettyClient,String sn,String user,String gw){
+ try{
+ String msgType = "MKSW";
+ String gy = "";
+ Boolean aqdw_str = sendMessageByGW(nettyClient,msgType,gy,"",sn,"",user,"00","",gw);
+ return aqdw_str;
+ }catch (Exception e){
+ return false;
+ }
+
// 绑定用户报文
public static Boolean bindUser(NettyClient nettyClient,String sn,String user){
try{
@@ -40,7 +40,7 @@ public class MesRevice {
// 发送允许启动信号
MesClient.s7PLC.writeBoolean(oprno1.getMes_in(), true);
// 开始加工报文
-
+ DataUtil.startWorkByGw(MesClient.nettyClient,ProtocolParam.getSn(mes_msg).trim(),MesClient.user20,oprno1.getOprno());
}else {
// MesClient.check_quality_result = false;
String lmsg = ErrorMsg.getErrorMsg(processMsgRet, ProtocolParam.getLx(mes_msg));