wuzeyu
2024-09-02 6418b2978c9cc4049c735b239efb223e20d33858
pipIrr-platform/pipIrr-web/pipIrr-mwTest-web/src/main/java/com/dy/pipIrrMwTestWeb/p206V202404test/CommandP206V202404Ctrl.java
@@ -18,23 +18,61 @@
public class CommandP206V202404Ctrl extends ComSupportP206V202404 {
    @GetMapping(path = "test")
    public BaseResponse<String> test() {
        //return this.connect() ;//连接通信中间件测试
        //return this.cdXY(CodeV202404.cd_9C) ;//发送固定参数XY的命令
        //return this.cd55(1) ;
        //return this.cd15() ;
        //return this.cd16() ;
        //return this.cd21() ;
        //return this.cd22() ;
        //return this.cd23() ;
        //return this.cd24() ;
        //return this.cd26() ;
        //return this.cd31() ;
        //return this.cd86() ;
        //return this.cd87() ;
        return this.cd92() ;
        //return this.cd93() ;
        //return this.cd9C() ;
    public BaseResponse<String> test(String rtuAddr, String com) {
        BaseResponse<String> rt = null ;
        if(rtuAddr == null || rtuAddr.trim().equals("")){
            rt = this.connect() ;//连接通信中间件测试
        }else{
            this.rtuAddr = rtuAddr ;
            if(com == null || com.trim().equals("")){
                rt = this.connect() ;//连接通信中间件测试
            }else{
                try{
                    if(com.equals("10")){
                        rt = this.cd10() ;
                    }else if(com.equals("15")){
                        rt = this.cd15() ;
                    }else if(com.equals("16")){
                        rt = this.cd16() ;
                    }else if(com.equals("21")){
                        rt = this.cd21() ;
                    }else if(com.equals("22")){
                        rt = this.cd22() ;
                    }else if(com.equals("23")){
                        rt = this.cd23() ;
                    }else if(com.equals("24")){
                        rt = this.cd24() ;
                    }else if(com.equals("26")){
                        rt = this.cd26() ;
                    }else if(com.equals("31")){
                        rt = this.cd31() ;
                    }else if(com.equals("55")){
                        rt = this.cd55(1) ;
                    }else if(com.equals("65")){
                        rt = this.cd65(1) ;
                    }else if(com.equals("86")){
                        rt = this.cd86() ;
                    }else if(com.equals("87")){
                        rt = this.cd87() ;
                    }else if(com.equals("92")){
                        rt = this.cd92() ;
                    }else if(com.equals("93")){
                        rt = this.cd93() ;
                    }else if(com.equals("9C")){
                        rt = this.cd9C() ;
                    }else if(com.equals("A2")){
                        rt = this.cdA2() ;
                    }else if(com.equals("A3")){
                        rt = this.cdA3() ;
                    }else{
                        rt = this.cdXY(com) ;//发送固定参数XY的命令, 例命令CodeV202404.cd_9C
                    }
                }catch (Exception e){
                    e.printStackTrace();
                }
            }
        }
        return rt ;
    }
    /**