zhubaomin
2025-03-03 75432e263f73a89baed5dc4c4cccbe2ca7d6d446
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
package com.dy.simRtu202404.tcpClient.downData;
 
import com.dy.common.mw.protocol.p206V202404.ProtocolConstantV206V202404;
 
/**
 * @Author: liurunyu
 * @Date: 2025/02/26 11:10
 * @Description
 */
public class DownData {
 
    private static int count9602 = 0;
 
    public void parseData(byte[] bs){
        if(bs != null && bs.length > 0){
            if(bs.length >= (ProtocolConstantV206V202404.ctrlIndex)
                    && bs[0] == ProtocolConstantV206V202404.P_Head_Byte
                    && bs[2] == ProtocolConstantV206V202404.P_Head_Byte){
                this.dealP206V1(bs);
            }else if(bs.length >= (ProtocolConstantV206V202404.UG_codeIndex)
                    && bs[0] == ProtocolConstantV206V202404.UG_P_Head_Byte
                    && bs[3] == ProtocolConstantV206V202404.UG_P_Head_Byte){
                this.dealUpgrade(bs);
            }
 
        }
    }
    private void dealP206V1(byte[] bs){
        //应该是链路检测数据
    }
    private void dealUpgrade(byte[] bs){
    }
}