linft пре 2 година
родитељ
комит
83b649c976
13 измењених фајлова са 11 додато и 145 уклоњено
  1. 1 41
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/service/impl/WordService.java
  2. 0 3
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/constant/JXCTPacket.java
  3. 0 8
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/runner/SocketRunner.java
  4. 1 12
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/runner/TCPServer.java
  5. 1 2
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/service/SocketService.java
  6. 1 3
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/service/impl/CommandResult.java
  7. 1 4
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/service/impl/LinkageResult.java
  8. 0 8
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/service/impl/SensorReportBody.java
  9. 1 1
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/service/impl/TaskResult.java
  10. 5 2
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/util/SocketUtils.java
  11. 0 49
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/vo/TransmissionVo.java
  12. 0 4
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/utils/CRCCHECK.java
  13. 0 8
      zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/utils/FireLaborUtil.java

+ 1 - 41
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/service/impl/WordService.java

@@ -3,7 +3,6 @@ package com.zd.laboratory.service.impl;
 import cn.hutool.core.date.DateUtil;
 import com.deepoove.poi.data.PictureRenderData;
 import com.deepoove.poi.data.PictureType;
-import com.deepoove.poi.policy.PictureRenderPolicy;
 import com.deepoove.poi.util.BufferedImageUtils;
 import com.zd.common.core.exception.ServiceException;
 import com.zd.common.core.utils.DateUtils;
@@ -14,7 +13,6 @@ import com.zd.laboratory.domain.LabCheckRecordDetails;
 import com.zd.laboratory.mapper.LabCheckOptionMapper;
 import com.zd.laboratory.mapper.LabCheckRecordDetailsMapper;
 import com.zd.laboratory.mapper.LabCheckRecordMapper;
-import com.zd.laboratory.service.ILabCheckOptionService;
 import com.zd.laboratory.utils.word.*;
 import org.apache.commons.lang3.StringUtils;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -22,7 +20,6 @@ import org.springframework.stereotype.Service;
 
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
-import java.io.File;
 import java.io.IOException;
 import java.util.ArrayList;
 import java.util.Arrays;
@@ -35,8 +32,6 @@ public class WordService {
     @Autowired
     private LabCheckOptionMapper labCheckOptionMapper;
     @Autowired
-    private ILabCheckOptionService labCheckOptionService;
-    @Autowired
     private LabCheckRecordMapper labCheckRecordMapper;
     @Autowired
     private LabCheckRecordDetailsMapper labCheckRecordDetailsMapper;
@@ -104,7 +99,6 @@ public class WordService {
 
             WordUtils.getWord1(word1, list,response);
         } catch (IOException e) {
-            //e.printStackTrace();
             throw new ServiceException(e.getMessage());
         }
     }
@@ -119,11 +113,6 @@ public class WordService {
                 throw new ServiceException("生成失败,ID无效!");
             }
 
-            /*String baseUrl = request.getServerName();
-            boolean isIntranet = false;
-            if(baseUrl.contains("192.168")){
-                isIntranet = true;
-            }*/
 
             LabCheckRecordDetails labCheckRecordDetails = new LabCheckRecordDetails();
             labCheckRecordDetails.setCheckId(checkRecord.getId());
@@ -147,12 +136,10 @@ public class WordService {
             if(deptSign == null){
                 deptSign = "";
             }else {
-                //deptSign = (isIntranet ? fileConfigUtils.getLocalUrl() :  fileConfigUtils.getRemoteUrl())  + deptSign;
                 //通过配置加载文件域名
                 deptSign = fileConfigUtils.getFileDomainApp() + deptSign;
             }
 
-            //word2.setCheck_dept_sign(new PictureRenderData(100, 100, PictureType.PNG, BufferedImageUtils.getUrlBufferedImage(deptSign)));
             word2.setCheck_dept_sign(new SignPictureRenderData(100, 100, deptSign, "图片加载失败", 310 ,-35));
             word2.setCheck_dept_name(checkRecord.getJcDwName());
             word2.setCheck_result(checkRecord.getZgJg());
@@ -163,8 +150,6 @@ public class WordService {
             word2.setNow_day(DateUtil.dayOfMonth(now) + "");
             word2.setCheck_room(checkRecord.getFjNumber());
             word2.setCheck_date(DateUtil.format(checkRecord.getCreateTime(), DateUtils.YYYY_MM_DD_HH_MM_SS));
-            // 检查人名称 - 2.6 更换为用户签名
-            //word2.setCheck_nick_name(checkRecord.getJcRyxm());
 
             String signature = labCheckRecordMapper.selectSignatureByUserId(checkRecord.getCreateUserId());
             word2.setCheck_nick_name(new PictureRenderData(100, 30, PictureType.PNG, BufferedImageUtils.getUrlBufferedImage(
@@ -183,11 +168,6 @@ public class WordService {
                 // 添加检查项 编码之后补充
                 // 数据形式存在 1,2,3, 1,, 1,  31,,, 等形式,故需要特殊处理
                 if(checkRecordDetails.get(i).getJcxId() != null){
-//                    optionId = checkRecordDetails.get(i).getJcxId().substring(0, checkRecordDetails.get(i).getJcxId().lastIndexOf(","));
-//                    if(optionId.lastIndexOf(",") != -1){
-//                        optionId = optionId.substring(optionId.lastIndexOf(","));
-//                    }
-
                     String[] ids = checkRecordDetails.get(i).getJcxId().split(",");
                     List<String> list1 = Arrays.asList(ids);
                     for (int i1 = 0; i1 < list1.size(); i1++) {
@@ -217,24 +197,19 @@ public class WordService {
                 String yhImgs = checkRecordDetails.get(i).getYhImg();
                 String[] imgs = yhImgs.split(",");
                 if(imgs.length > 0){
-                    //detail.setCheck_img1((isIntranet ? fileConfigUtils.getLocalUrl() :  fileConfigUtils.getRemoteUrl())  + imgs[0]);
                     //通过配置加载文件域名
                     detail.setCheck_img1(fileConfigUtils.getFileDomainApp() + imgs[0]);
                 }
                 if(imgs.length > 1){
-                    //detail.setCheck_img2((isIntranet ? fileConfigUtils.getLocalUrl() :  fileConfigUtils.getRemoteUrl())  + imgs[1]);
                     detail.setCheck_img2(fileConfigUtils.getFileDomainApp() + imgs[1]);
                 }
                 if(imgs.length > 2){
-                    //detail.setCheck_img3((isIntranet ? fileConfigUtils.getLocalUrl() :  fileConfigUtils.getRemoteUrl())  + imgs[2]);
                     detail.setCheck_img3(fileConfigUtils.getFileDomainApp() + imgs[2]);
                 }
                 if(imgs.length > 3){
-                    //detail.setCheck_img4((isIntranet ? fileConfigUtils.getLocalUrl() :  fileConfigUtils.getRemoteUrl())  + imgs[3]);
                     detail.setCheck_img4(fileConfigUtils.getFileDomainApp() + imgs[3]);
                 }
                 if(imgs.length > 4){
-                    //detail.setCheck_img5((isIntranet ? fileConfigUtils.getLocalUrl() :  fileConfigUtils.getRemoteUrl())  + imgs[4]);
                     detail.setCheck_img5(fileConfigUtils.getFileDomainApp() + imgs[4]);
                 }
 
@@ -243,7 +218,6 @@ public class WordService {
 
             WordUtils.getWord2(word2, list,response);
         } catch (IOException e) {
-            //e.printStackTrace();
             throw new ServiceException(e.getMessage());
         }
     }
@@ -251,7 +225,7 @@ public class WordService {
     /**
      * 小程序单个 生成整改报告
      */
-    public void genReport(Long id, HttpServletResponse response, HttpServletRequest request) {
+    public void genReport(Long id, HttpServletResponse response) {
         try {
 
             LabCheckRecord checkRecord = labCheckRecordMapper.selectLabCheckRecordById(id);
@@ -259,12 +233,6 @@ public class WordService {
                 throw new ServiceException("生成失败,ID无效!");
             }
 
-            /*String baseUrl = request.getServerName();
-            boolean isIntranet = false;
-            if(baseUrl.contains("192.168")){
-                isIntranet = true;
-            }*/
-
             LabCheckRecordDetails labCheckRecordDetails = new LabCheckRecordDetails();
             labCheckRecordDetails.setCheckId(checkRecord.getId());
             List<LabCheckRecordDetails> checkRecordDetails = labCheckRecordDetailsMapper.selectLabCheckRecordDetailsList(labCheckRecordDetails);
@@ -333,10 +301,7 @@ public class WordService {
                     detail.setOption_code("");
                 }
 
-
                 detail.setCheck_desc(checkRecordDetails.get(i).getYhMs());
-                // 需注意多个图片的展示情况 - 此处不展示图片
-                //detail.setCheck_img(checkRecordDetails.get(i).getYhImg());
                 list.add(detail);
                 if(checkRecordDetails.get(i).getIsZg() == null || checkRecordDetails.get(i).getIsZg() == 1){
                     unCount ++;
@@ -354,23 +319,18 @@ public class WordService {
                 String yhImgs = checkRecordDetails.get(i).getYhImg();
                 String[] imgs = yhImgs.split(",");
                 if(imgs.length > 0){
-                    //desc.setCheck_img1((isIntranet ? fileConfigUtils.getLocalUrl() :  fileConfigUtils.getRemoteUrl())  + imgs[0]);
                     desc.setCheck_img1(fileConfigUtils.getFileDomainApp() + imgs[0]);
                 }
                 if(imgs.length > 1){
-                    //desc.setCheck_img2((isIntranet ? fileConfigUtils.getLocalUrl() :  fileConfigUtils.getRemoteUrl())  + imgs[1]);
                     desc.setCheck_img2(fileConfigUtils.getFileDomainApp() + imgs[1]);
                 }
                 if(imgs.length > 2){
-                    //desc.setCheck_img3((isIntranet ? fileConfigUtils.getLocalUrl() :  fileConfigUtils.getRemoteUrl())  + imgs[2]);
                     desc.setCheck_img3(fileConfigUtils.getFileDomainApp() + imgs[2]);
                 }
                 if(imgs.length > 3){
-                    //desc.setCheck_img4((isIntranet ? fileConfigUtils.getLocalUrl() :  fileConfigUtils.getRemoteUrl())  + imgs[3]);
                     desc.setCheck_img4(fileConfigUtils.getFileDomainApp() + imgs[3]);
                 }
                 if(imgs.length > 4){
-                    //desc.setCheck_img5((isIntranet ? fileConfigUtils.getLocalUrl() :  fileConfigUtils.getRemoteUrl())  + imgs[4]);
                     desc.setCheck_img5(fileConfigUtils.getFileDomainApp() + imgs[4]);
                 }
                 descs.add(desc);

+ 0 - 3
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/constant/JXCTPacket.java

@@ -59,9 +59,6 @@ public class JXCTPacket {
         crc = data.substring(dataLen - 8, dataLen - 4);
         byte[] crcData = SocketUtils.str2byte(data.substring(0, dataLen - 8));
         String dataCrc = SocketUtils.getHexString(SocketUtils.crc16(crcData, crcData.length), 4);
-        if (!crc.equals(dataCrc)) {
-            //throw new AnalysisException("校验错误 当前:" + crc + " 正确:" + dataCrc);
-        }
         header = data.substring(0, 4);
         length = Integer.parseInt(data.substring(4, 6), 16);
         deviceNumber = data.substring(6, 18);

+ 0 - 8
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/runner/SocketRunner.java

@@ -26,13 +26,6 @@ import java.util.concurrent.*;
 @Slf4j
 public class SocketRunner implements CommandLineRunner {
 
-    //地址
-    //public static ConcurrentMap<String,Socket>  concurrentMap = new ConcurrentHashMap<>();
-    //带端口的地址
-    //public static ConcurrentHashSet<String> concurrentHashSet= new ConcurrentHashSet<>();
-    //黑名单
-    //public static ConcurrentHashSet<String> backList= new ConcurrentHashSet<>();
-
     public static Set<String> whitelist;
 
     @Autowired
@@ -60,7 +53,6 @@ public class SocketRunner implements CommandLineRunner {
             }
 
         } catch (IOException e) {
-            //e.printStackTrace();
             log.error("", e);
         }
     }

+ 1 - 12
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/runner/TCPServer.java

@@ -53,7 +53,7 @@ public class TCPServer implements Runnable {
                     socket.close();
                 }
             } catch (IOException e) {
-                //e.printStackTrace();
+                log.error("异常信息:",e);
             }
         }
     }
@@ -116,7 +116,6 @@ public class TCPServer implements Runnable {
             cacheMap.put(packet.deviceNumber, socket.getOutputStream());
 
         }catch (Exception e){
-            //e.printStackTrace();
             log.error(e.toString());
         }
 
@@ -186,7 +185,6 @@ public class TCPServer implements Runnable {
             sb.append(chars[bit]);
             bit = bs[i] & 0x0f;
             sb.append(chars[bit]);
-            // sb.append(' ');
         }
         return sb.toString().trim();
     }
@@ -209,13 +207,4 @@ public class TCPServer implements Runnable {
         }
         return new String(bytes);
     }
-
-
-    public static void main(String[] args) throws Exception {
-
-        String str = "fe dc 01 78 99 4c 6c 61 88 00 02 64 30 03 00 34 00 00 00 00 00 00 00 00 00 00 01 2d 00 00 01 55 00 01 88 f6 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00";
-
-        TransmissionVo transmissionVo = new TransmissionVo(str);
-
-    }
 }

+ 1 - 2
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/service/SocketService.java

@@ -244,7 +244,6 @@ public class SocketService {
      */
     public void sendWriteHelmCommand(@NotNull String id,@NotNull String position,@NotNull String time,@NotNull String speed) {
         byte[] command=HexUtils.generateCommand(id,position,time,speed);
-        String topic=steerSubscriptPrefix + "/285E3E7AE93D";
         commonSend.send(steerSubscriptPrefix + "/285E3E7AE93D",command);
     }
 
@@ -314,7 +313,7 @@ public class SocketService {
                     relayCode.set(a.getKey());
                 }
             } catch (IOException e) {
-                //e.printStackTrace();
+                log.error("异常信息:",e);
             }
         });
 

+ 1 - 3
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/service/impl/CommandResult.java

@@ -22,15 +22,13 @@ public class CommandResult implements BaseRouter {
     @Override
     public String routePacket(JXCTPacket tracketPacket) throws AnalysisException {
 
-        int count = Integer.parseInt(tracketPacket.deviceNumber.substring(0, 2), 16);
-        //        继电器位号,2字节,0x03ff=0b001111111111,按位表示继电器状态,最低位表示第1号继电器,为0表示当前关闭,为1表示当前开启
+        //继电器位号,2字节,0x03ff=0b001111111111,按位表示继电器状态,最低位表示第1号继电器,为0表示当前关闭,为1表示当前开启
         if (tracketPacket.body.length() < 10) {
             throw new AnalysisException("继电器上报状态错误");
         }
         //  指令操作反馈,1字节,(0-操作成功,1--操作失败)
         String result = tracketPacket.body.substring(0, 2);
         //        冲突逻辑位号,2字节,(0b0000开头,后12位,以最低位表示第1条互斥逻辑,置1表示该条逻辑冲突,操作标志为2时无意义),暂时不用,将会返回两字节0
-        String mutex = tracketPacket.body.substring(2, 6);
         //当前继电器状态,2字节,0x03ff=0b001111111111,按位表示继电器状态,最低位表示第1号继电器,置0表示当前开,置1表示当前关
         String state = tracketPacket.body.substring(6, 10);
 

+ 1 - 4
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/service/impl/LinkageResult.java

@@ -1,6 +1,5 @@
 package com.zd.laboratory.socket.service.impl;
 
-
 import com.zd.laboratory.socket.constant.JXCTPacket;
 import com.zd.laboratory.socket.exception.AnalysisException;
 import com.zd.laboratory.socket.service.BaseRouter;
@@ -26,9 +25,7 @@ public class LinkageResult implements BaseRouter {
 
         //指令1字节
         String command = tracketPacket.body.substring(0, 2);
-        if ("00".equals(command) || "01".equals(command)) {// 联动配置指令返回
-//            联动条序号,1字节,(0-5,6代表保存的所有联动关系)
-            String position = tracketPacket.body.substring(4, 6);
+        if ("00".equals(command) || "01".equals(command)) {
             //配置/清空联动反馈的标志,1字节,(0-操作成功,1-操作失败)
             String result = tracketPacket.body.substring(6, 8);
             log.info(tracketPacket.deviceNumber + " 联动配置指令结果:" + result);

+ 0 - 8
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/service/impl/SensorReportBody.java

@@ -7,9 +7,6 @@ import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.stereotype.Service;
 
-import java.text.DecimalFormat;
-
-
 /**
  * @author liubo
  *     @desc    : 传感器上报数据内容
@@ -27,13 +24,8 @@ public class SensorReportBody implements BaseRouter {
         routerMap.put("08", this);
     }
 
-    DecimalFormat sdf = new DecimalFormat("##############0.0000");
-
     @Override
     public String routePacket(JXCTPacket tracketPacket) {
-
-        long startPacketTime = System.currentTimeMillis();
-
         String commad = tracketPacket.body.substring(0, 2);
         log.info(tracketPacket.deviceNumber + " commad:" + commad);
         if ("00".equals(commad)) {

+ 1 - 1
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/service/impl/TaskResult.java

@@ -111,7 +111,7 @@ public class TaskResult implements BaseRouter {
 //            0-操作失败
 //            1-操作成功
             //结果
-            String result = indexHex;//tracketPacket.body.substring(2, 4);
+            String result = indexHex;
             if ("00".equals(result)) {
                 log.info(tracketPacket.deviceNumber + "  " + command + "  指令使能控制返回 00-操作成功");
             } else if ("01".equals(result)) {

+ 5 - 2
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/util/SocketUtils.java

@@ -1,5 +1,7 @@
 package com.zd.laboratory.socket.util;
 
+import lombok.extern.slf4j.Slf4j;
+
 import javax.swing.*;
 import java.awt.*;
 import java.awt.event.FocusAdapter;
@@ -9,6 +11,7 @@ import java.text.SimpleDateFormat;
 /**
  * @author liubo
  */
+@Slf4j
 public class SocketUtils {
 
     public static final SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
@@ -108,7 +111,7 @@ public class SocketUtils {
         try {
             result = Integer.parseInt(s, 16);
         } catch (Exception e) {
-            //e.printStackTrace();
+            log.error("",e);
         }
         return result;
     }
@@ -148,7 +151,7 @@ public class SocketUtils {
         try {
             bit = Integer.toBinaryString(Integer.parseInt(bitHex, 16));
         } catch (Exception e) {
-            //e.printStackTrace();
+            log.error("",e);
         }
         StringBuilder s = new StringBuilder();
         for (int i = 0; i < count; i++) {

+ 0 - 49
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/socket/vo/TransmissionVo.java

@@ -159,24 +159,7 @@ public class TransmissionVo {
      */
     private String A9;
 
-    public TransmissionVo() {
-    }
-
     public TransmissionVo(String data) {
-        // 传感器接收数据
-        // fe dc
-        // 01
-        // 83 62 40 6e 6b 6b
-        // 00 00 2a 08
-        // 03
-        // 00 20
-        // 00 00 00 00
-        // 00 00 00 f3
-        // 00 00 01 8f
-        // 00 00 00 00
-        // 00 01 78 79
-        // 00 00 00 d1 00 00 00 00 00 00 00 00
-        // 00
 
         data = data.replaceAll(" ", "");
 
@@ -203,43 +186,33 @@ public class TransmissionVo {
         this.A7 = a7;
         int index = 0;
         if(bytes >= index + 8){
-//            this.A7_1 = Integer.parseInt(this.A7.substring(index, index+=8), Character.FORMAT) + " mg/m3";
             this.A7_1 = percentage(this.A7.substring(index, index+=8));
         }
         if(bytes >= index + 8){
-//            this.A7_2 = percentage(this.A7.substring(index, index+=8), 1) + " ℃";
             this.A7_2  = percentage(this.A7.substring(index, index+=8));
         }
         if(bytes >= index + 8){
-//            this.A7_3 = percentage(this.A7.substring(index, index+=8), 1) + " %RH";
             this.A7_3 = percentage(this.A7.substring(index, index+=8));
         }
         if(bytes >= index + 8){
-//            this.A7_4 = percentage(this.A7.substring(index, index+=8), 1) + " ppm";
             this.A7_4  = percentage(this.A7.substring(index, index+=8));
         }
         if(bytes >= index + 8){
-//            this.A7_5 = percentage(this.A7.substring(index, index+=8), 2) + " mbar";
             this.A7_5  = percentage(this.A7.substring(index, index+=8));
         }
         if(bytes >= index + 8){
-//            this.A7_6 = percentage(this.A7.substring(index, index+=8), 1) + " %";
             this.A7_6 = percentage(this.A7.substring(index, index+=8));
         }
         if(bytes >= index + 8){
-//            this.A7_7 = percentage(this.A7.substring(index, index+=8), 1) + "";
             this.A7_7 = percentage(this.A7.substring(index, index+=8));
         }
         if(bytes >= index + 8){
-//            this.A7_8 = percentage(this.A7.substring(index, index+=8), 1) + "";
             this.A7_8 = percentage(this.A7.substring(index, index+=8));
         }
         if(bytes >= index + 8){
-//            this.A7_9 = percentage(this.A7.substring(index, index+=8), 1) + "";
             this.A7_9 = percentage(this.A7.substring(index, index+=8));
         }
         if(bytes >= index + 8){
-//            this.A7_10 = percentage(this.A7.substring(index, index+=8), 1) + "";
             this.A7_10 = percentage(this.A7.substring(index, index+=8));
         }
         if(bytes >= index + 8){
@@ -262,28 +235,6 @@ public class TransmissionVo {
         }
     }
 
-    public static void main(String[] args) {
-        // 00000000 000000f4 0000018f 00000000 000178ac 000000d1 0000000000000000
-        // 0  244  399 0 96428 209 0
-
-        // 00 00 00 00        煤尘   没有小数位    mg/m3
-        // 00 00 00 ef  239   温度   一个小数位    ℃
-        // 00 00 01 8d  394   湿度   一位         %RH
-        // 00 00 00 00        一氧化碳  一位       ppm
-        // 00 01 79 7e  99638 大气压   两位小数位   mbar
-        // 00 00 00 d1  209   氧气浓度  一位       %
-        // 00 00 00 00        烟雾报警    一位        无
-        // 00 00 00 00
-
-        // 01 03 02 00 00 03 7a d1 01
-        String str = "02fffd";
-
-        // 4路 数据  fe dc 01 83 54 40 6e 6b 6b 00 00 21 6a 03 00 10 00 00 00 b2 00 00 02 76 00 01 8c 9a 00 00 00 00 00
-        // 8路 数据  fe dc 01 83 62 40 6e 6b 6b 00 05 84 90 03 00 20 00 00 00 00 00 00 00 d4 00 00 01 a1 00 00 00 00 00 01 7a 15 00 00 00 d1 00 00 00 00 00 00 00 00 00
-        // 13路 数据  fe dc 01 83 72 40 6e 6b 6c 00 00 00 04 03 00 34 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
-        //TransmissionVo a = new TransmissionVo("fe dc 01 83 54 40 6e 6b 6b 00 00 21 6a 03 00 10 00 00 00 b2 00 00 02 76 00 01 8c 9a 00 00 00 00 00");
-    }
-
     /**
      * 根据检测值智能 小数位计算
      * @param str  需要计算的数据

+ 0 - 4
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/utils/CRCCHECK.java

@@ -44,10 +44,6 @@ public class CRCCHECK {
         return hexString;
     }
 
-    public static void main(String args[]){
-        Integer bit=5;
-    }
-
     /**
      * 根据地址位动态生成开锁指令
      * @param bit

+ 0 - 8
zd-modules/zd-modules-laboratory/src/main/java/com/zd/laboratory/utils/FireLaborUtil.java

@@ -91,7 +91,6 @@ public class FireLaborUtil {
         boolean fireStatus=false;
         String msg="";
         int fireNumber=0;
-        //String returnCodes="02 03 48 00 00 00 00 02 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0A 00 00 00 40 3D ";
         returnCodes=returnCodes.replace(" ","");
         String registerCode=returnCodes.substring(6,returnCodes.length()-20);
         String mainCode=returnCodes.substring(134,returnCodes.length()-4);
@@ -161,11 +160,4 @@ public class FireLaborUtil {
         }
         return strings;
     }
-
-    public static void main(String[] args) {
-        boolean fireStatus=false;
-        String msg="";
-        String str = "02 03 48 00 00 00 00 02 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0A 00 00 00 40 3D ";
-        JSONObject jsonObject=getFireStatus(str);
-    }
 }