liurunyu
2024-09-07 9ad6b0179be4d351105f1507779d4f41a3a41953
pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V202404/parse/global/GlCreate.java
@@ -114,25 +114,8 @@
        ByteUtil.string2BCD_BE(bs, DateTime.mm(), index + 1) ;
        ByteUtil.string2BCD_BE(bs, DateTime.HH(), index + 2) ;
        ByteUtil.string2BCD_BE(bs, DateTime.dd(), index + 3) ;
        byte month = Byte.parseByte(DateTime.MM()) ;
        byte week = (byte)(DateTime.week_Int().byteValue() << 1)  ;
        String month1 = "0" ;
        String month2 = "0" ;
        if(month < 10){
            month1 = "" + month ;
        }else{
            if(month == 10){
                month1 = "0" ;
            }else if(month == 11){
                month1 = "1" ;
            }else if(month == 12){
                month1 = "2" ;
            }
            week = (byte)(week | 0x01) ;
        }
        month2 = "" + week ;
        ByteUtil.string2BCD_BE(bs, month2 + month1, index + 4) ;
        //以下写法自然也是BCD
        bs[index + 4] = (byte)((DateTime.week_Int().byteValue() << 5 | Byte.parseByte(DateTime.MM()))) ;
        ByteUtil.string2BCD_BE(bs, DateTime.yy(), index + 5) ;
        /*