ZengTao
2024-04-01 eccfd8d0504c48f07c7e11ed1fc94451ce5e7cb1
springboot-vue3/src/main/java/com/example/springboot/component/PLCAutoMes.java
@@ -13,7 +13,7 @@
public class PLCAutoMes extends Thread {
    // 用于存储应用程序的配置信息
    private Configuration config;
    private static InitUtil initUtil;
    // public static PlcParameterObject PlcMesObject;
    // public static PlcParameterObject PlcReadObject;
@@ -50,7 +50,7 @@
  
    // 私有构造函数
    public PLCAutoMes() throws IOException {
        config = new Configuration("config.properties");
        //config = new Configuration("config.properties");
        initUtil = new InitUtil();
    }
@@ -75,10 +75,11 @@
            // System.out.println(jsonFilePath);
            //readAndUpdateWordValues(PlcReadObject);
            List<Short> ss=S7control.getinstance().ReadWord("DB14.0", 1);
            readAndUpdateWordValues(PlcMesObject);
            //readAndUpdateWordValues(PlcframeObject);
            // readAndUpdateWordValues(PlcframeObject);
            // readAndUpdateWordValues(plcStateObject);
            // int index = PlcMesObject.getPlcParameter("AddStart").getAddressIndex();
            // // System.out.println(index);