hzd 5 dni temu
rodzic
commit
52408c0814

+ 1 - 1
src/com/mes/ui/MesClient.java

@@ -135,7 +135,7 @@ public class MesClient extends JFrame {
     public static JPanel indexPanelC;
     public static MesWebView jfxPanel2 = null;
 
-    public static S7PLC s7PLC = new S7PLC(EPlcType.S1200, "10.88.10.240"); //100 B工位
+    public static S7PLC s7PLC = new S7PLC(EPlcType.S1200, "192.168.7.100"); //100 B工位
 
     public static List<String> hjparams = new ArrayList<>();
 

+ 4 - 4
src/com/mes/ui/MesRevice.java

@@ -18,19 +18,19 @@ public class MesRevice {
                 String oprno = ProtocolParam.getOprno(mes_msg).trim();
                 String sn = ProtocolParam.getSn(mes_msg).trim();
                 System.out.println(":"+oprno);
-                if(oprno.equals("OP070A")){
+                if(oprno.equals("OP110A")){
                     String barcode36 = MesClient.getBarcode(sn);//处理36为码
                     MesClient.getUser();
                     DataUtil.startWork(MesClient.nettyClient,barcode36,MesClient.user20,"A");
-                }else if(oprno.equals("OP070B")){
+                }else if(oprno.equals("OP110B")){
                     String barcode36 = MesClient.getBarcode(sn);//处理36为码
                     MesClient.getUser();
                     DataUtil.startWork(MesClient.nettyClient,barcode36,MesClient.user20,"B");
-                }else if(oprno.equals("OP070C")){
+                }else if(oprno.equals("OP110C")){
                     String barcode36 = MesClient.getBarcode(sn);//处理36为码
                     MesClient.getUser();
                     DataUtil.startWork(MesClient.nettyClient,barcode36,MesClient.user20,"A");
-                }else if(oprno.equals("OP070D")){
+                }else if(oprno.equals("OP110D")){
                     String barcode36 = MesClient.getBarcode(sn);//处理36为码
                     MesClient.getUser();
                     DataUtil.startWork(MesClient.nettyClient,barcode36,MesClient.user20,"B");

+ 1 - 1
src/com/mes/ui/PlcUtil.java

@@ -273,7 +273,7 @@ public class PlcUtil {
     public static Boolean changeEnable(S7PLC s7PLC,Boolean result){
         try{
             //DB9.21.7 A//DB9.26.4 B
-            s7PLC.writeBoolean("DB0.DBX23.7",result);
+            s7PLC.writeBoolean("DB9.26.4",result);
 //            s7PLC.writeBoolean("DB9.21.7",result);
             return true;
         }catch (Exception e){

+ 1 - 1
src/resources/config/config.properties

@@ -1,4 +1,4 @@
-mes.gw=OP100A
+mes.gw=OP110
 #mes.server_ip=127.0.0.1
 mes.server_ip=192.168.22.99
 mes.tcp_port=3000