From 842237345ac469b02e9add8f9fd8bae5d4f7cdac Mon Sep 17 00:00:00 2001 From: zhubaomin <zhubaomin> Date: 星期二, 25 二月 2025 14:33:15 +0800 Subject: [PATCH] Merge branch 'master' of http://8.140.179.55:20000/r/pipIrr-SV --- pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V202404/ProtocolConstantV206V202404.java | 30 ++++++++++++++++++++++++++++-- 1 files changed, 28 insertions(+), 2 deletions(-) diff --git a/pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V202404/ProtocolConstantV206V202404.java b/pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V202404/ProtocolConstantV206V202404.java index 52f95a6..5e15453 100644 --- a/pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V202404/ProtocolConstantV206V202404.java +++ b/pipIrr-platform/pipIrr-common/src/main/java/com/dy/common/mw/protocol/p206V202404/ProtocolConstantV206V202404.java @@ -8,6 +8,7 @@ * 娉ㄨВ鐩稿叧 */ public static final String protocolName = "p206V202404" ; + public static final short protocolVer = 201 ; public static final int priority = 1 ;//浼樺厛绾� /** * RTU涓婄嚎鏁版嵁锛堜笂绾垮悗绗竴鍖呮暟鎹級鏈�灏忛暱搴︼紝璁剧疆璇ュ睘鎬т互澶囪繘琛屽畬鏁存�ф鏌ワ紝 @@ -23,13 +24,13 @@ public static final int headMinLength = 3 ; //甯ц捣濮� - public static final byte P_Head_Byte = (byte)0x68 ; + public static final byte P_Head_Byte = (byte)0x69 ; public static final byte P_Tail_Byte = (byte)0x16 ; //00H鏃堕仴娴嬬粓绔湪鍏煎宸ヤ綔鐘舵�侊紱01H鏃堕仴娴嬬粓绔湪鑷姤宸ヤ綔鐘舵�侊紱02H鏃堕仴娴嬬粓绔湪鏌ヨ/搴旂瓟宸ヤ綔鐘舵�侊紱03H鏃堕仴娴嬬粓绔湪璋冭瘯/缁翠慨鐘舵�併�� public static final byte P_Default_mode = (byte)0x00 ;//榛樿宸ヤ綔妯″紡 - public static final String P_Head_Hex = "68" ; + public static final String P_Head_Hex = "69" ; public static final String P_Tail_Hex = "16" ; public static final byte lenHead2ctrl = 3 ; //浠庡ご鍒版帶鍒跺煙锛堜笉鍖呮嫭锛夊瓧鑺傛暟缁勯暱搴� @@ -47,4 +48,29 @@ public static final int codeIndex = 12 ;//鍔熻兘鐮佸瓧鑺傛暟缁勪笅鏍� public static final int dataIndex = 13 ;//鍏蜂綋鏁版嵁瀛楄妭鏁扮粍涓嬫爣 + public static final String vsCardAddr = "00000000";//鏈郴缁熷簲鐢ㄧ殑铏氭嫙鍗★紝鍗$墿鐞嗗湴鍧�閲囩敤10涓�0浣滀负妯℃嫙 + + //////////////////////////////////////////////// + // + //杩滅▼鍗囩骇鐩稿叧 + // + //////////////////////////////////////////////// + public static final byte UG_P_Head_Byte = (byte)0xAA ; + public static final byte UG_P_Tail_Byte = (byte)0x16 ; + public static final int UG_codeIndex = 4 ;//鍔熻兘鐮佸瓧鑺傛暟缁勪笅鏍� + public static final int UG_dataIndex = 12 ;//鍏蜂綋鏁版嵁瀛楄妭鏁扮粍涓嬫爣 + + public static final int UG_dataLenIndex_start = 1 ;//甯ч暱搴﹀紑濮嬫墍鍦� 瀛楄妭鏁扮粍璧峰涓嬫爣 + public static final int UG_dataLenIndex_end = 2 ;//甯ч暱搴︾粨鏉熸墍鍦� 瀛楄妭鏁扮粍璧峰涓嬫爣 + + public static final int UG_rtuAddrIndex_start = 6 ;//鎺у埗鍣ㄥ湴鍧� 瀛楄妭鏁扮粍寮�濮嬩笅鏍� + public static final int UG_rtuAddrIndex_end = 11 ;//鎺у埗鍣ㄥ湴鍧� 瀛楄妭鏁扮粍寮�濮嬩笅鏍� + + public static final byte UG_lenCmd = 2 ; //鍔熻兘鐮佸瓧鑺傛暟缁勯暱搴� + public static final byte UG_lenRtuAddr = 6 ; //鍔熻兘鐮佸瓧鑺傛暟缁勯暱搴� + public static final byte UG_lenHead2Cmd = 4 ; //浠庡ご鍒板姛鑳界爜锛堜笉鍖呮嫭锛夊瓧鑺傛暟缁勯暱搴� + public static final byte UG_lenTail = 3 ; //甯у熬閮ㄥ瓧鑺傛暟缁勯暱搴� + public static final byte UG_lenHead2RtuAddr = 12 ; //浠庡ご鍒癛TU鍦板潃锛堝寘鎷級瀛楄妭鏁扮粍闀垮害 + + } \ No newline at end of file -- Gitblit v1.8.0