From 2225b1f0727fb74e10ac5692e68e4cd48f4f62d7 Mon Sep 17 00:00:00 2001 From: wjc <1243177876@qq.com> Date: 星期一, 03 三月 2025 15:02:14 +0800 Subject: [PATCH] 2025年03月03日15:02:11 --- app/src/main/java/com/hdl/photovoltaic/other/HdlESLocalJsonLogic.java | 227 ++++++++++++++++++++++++++++++++++++-------------------- 1 files changed, 145 insertions(+), 82 deletions(-) diff --git a/app/src/main/java/com/hdl/photovoltaic/other/HdlESLocalJsonLogic.java b/app/src/main/java/com/hdl/photovoltaic/other/HdlESLocalJsonLogic.java index 71c3788..ebb0dd4 100644 --- a/app/src/main/java/com/hdl/photovoltaic/other/HdlESLocalJsonLogic.java +++ b/app/src/main/java/com/hdl/photovoltaic/other/HdlESLocalJsonLogic.java @@ -1,5 +1,6 @@ package com.hdl.photovoltaic.other; +import android.os.Build; import android.text.TextUtils; import com.hdl.linkpm.sdk.core.exception.HDLException; @@ -7,8 +8,11 @@ import com.hdl.photovoltaic.internet.HttpClient; import com.hdl.photovoltaic.listener.CloudCallBeak; +import java.util.ArrayList; import java.util.HashMap; +import java.util.List; import java.util.Map; +import java.util.Set; /** * 鏈湴json缂撳瓨閫昏緫 @@ -48,42 +52,92 @@ * @return 鏂板湴鍧� */ private String getStrJointNewUrl(String fileName, String deviceType, String deviceModel) { - return address + "/" + UserConfigManage.getInstance().getCurrentAppLanguage() + "/" + deviceType + "/" + deviceModel + "/" + fileName; + return address + "/" + UserConfigManage.getInstance().getCurrentAppLanguage() + "/" + deviceType + "/" + deviceModel + "/" + fileName + this.getVersion(fileName) + ".json"; } + /** - * 鍒濆鍖栬剼鏈瑄rl + * 鑾峰彇鍔炵増鏈彿 * * @return map */ - private Map<String, String> getUrlMap() { + private String getVersion(String fileName) { + + Map<String, String> map = this.getFeliAndVersion(); + for (Map.Entry<String, String> entry : map.entrySet()) { + if (entry.getKey().equals(fileName)) { + return entry.getValue(); + } + } + return ""; + } + + + /** + * 鑾峰彇json鏂囦欢鍚�,璁惧绫诲瀷锛岃澶囧瀷鍙� + * + * @return map + */ + private List<String> getFileNameAndDeviceTypeAndDeviceModeList() { //娉ㄦ剰锛堥�嗗彉鍣�:ME-GSE-S5K锛岃礋杞戒腑蹇�:ME-GSE-SPG63A锛宐ms:ME-GSE-BMS15K锛岀數姹犲寘:ME-GSE-B5K锛夎澶囧瀷鍙蜂笉涓�鏍� - Map<String, String> map = new HashMap<>(); - map.put(this.getStrJointNewUrl(FileName.hdl_lc_ecu_info_item, DeviceType.LC, DeviceModel.LC), DeviceModel.LC);//鑾峰彇璐熻浇鎺у埗涓績 - map.put(this.getStrJointNewUrl(FileName.hdl_lc_ecu_quick, DeviceType.LC, DeviceModel.LC), DeviceModel.LC); //鍒涘缓鐢电珯-璐熻浇鎺у埗涓績鍙傛暟閰嶇疆 - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu_quick, DeviceType.INV, DeviceModel.INV), DeviceModel.INV);//鍒涘缓鐢电珯-閫嗗彉鍣ㄥ弬鏁伴厤缃� - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu, DeviceType.INV, DeviceModel.INV), DeviceModel.INV);//閫嗗彉鍣ㄥ弬鏁伴厤缃� - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu_info_pv, DeviceType.INV, DeviceModel.INV), DeviceModel.INV);// 閫嗗彉鍣ㄨ鎯�-pv - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu_info_output, DeviceType.INV, DeviceModel.INV), DeviceModel.INV);//閫嗗彉鍣ㄨ鎯�-杈撳嚭 - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu_info_item, DeviceType.INV, DeviceModel.INV), DeviceModel.INV);//閫嗗彉鍣ㄨ鎯�-item椤� - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu_info_signal, DeviceType.INV, DeviceModel.INV), DeviceModel.INV);//閫嗗彉鍣ㄨ鎯�-淇″彿鐐� - map.put(this.getStrJointNewUrl(FileName.hdl_bms_ecu, DeviceType.BMS, DeviceModel.INV_BMS), DeviceModel.INV_BMS);//鑾峰彇BMS淇℃伅 - map.put(this.getStrJointNewUrl(FileName.hdl_battery_ecu, DeviceType.BATTERY, DeviceModel.INV_BATTERY), DeviceModel.INV_BATTERY);//鐢垫睜鍖呬俊鎭� - map.put(this.getStrJointNewUrl(FileName.hdl_battery_ecu_cell, DeviceType.BATTERY, DeviceModel.INV_BATTERY), DeviceModel.INV_BATTERY);//鐢垫睜鍖�-鐢佃姱淇℃伅 + //鎷兼帴瑙勫垯锛氭枃浠跺悕_璁惧绫诲瀷_璁惧淇″彿 + List<String> stringList = new ArrayList<>(); + stringList.add(FileName.hdl_lc_ecu_info_item + "%" + DeviceType.LC + "%" + DeviceModel.LC);//鑾峰彇璐熻浇鎺у埗涓績 + stringList.add(FileName.hdl_lc_ecu_quick + "%" + DeviceType.LC + "%" + DeviceModel.LC);//鍒涘缓鐢电珯-璐熻浇鎺у埗涓績鍙傛暟閰嶇疆 + stringList.add(FileName.hdl_inv_ecu_quick + "%" + DeviceType.INV + "%" + DeviceModel.INV);//鍒涘缓鐢电珯-閫嗗彉鍣ㄥ弬鏁伴厤缃� + stringList.add(FileName.hdl_inv_ecu + "%" + DeviceType.INV + "%" + DeviceModel.INV);//閫嗗彉鍣ㄥ弬鏁伴厤缃� + stringList.add(FileName.hdl_inv_ecu_info_pv + "%" + DeviceType.INV + "%" + DeviceModel.INV);// 閫嗗彉鍣ㄨ鎯�-pv + stringList.add(FileName.hdl_inv_ecu_info_output + "%" + DeviceType.INV + "%" + DeviceModel.INV);//閫嗗彉鍣ㄨ鎯�-杈撳嚭 + stringList.add(FileName.hdl_inv_ecu_info_item + "%" + DeviceType.INV + "%" + DeviceModel.INV);//閫嗗彉鍣ㄨ鎯�-item椤� + stringList.add(FileName.hdl_inv_ecu_info_signal + "%" + DeviceType.INV + "%" + DeviceModel.INV);//閫嗗彉鍣ㄨ鎯�-淇″彿鐐� + stringList.add(FileName.hdl_bms_ecu + "%" + DeviceType.BMS + "%" + DeviceModel.INV_BMS);//鑾峰彇BMS淇℃伅 + stringList.add(FileName.hdl_battery_ecu + "%" + DeviceType.BATTERY + "%" + DeviceModel.INV_BATTERY);//鐢垫睜鍖呬俊鎭� + stringList.add(FileName.hdl_battery_ecu_cell + "%" + DeviceType.BATTERY + "%" + DeviceModel.INV_BATTERY);//鐢垫睜鍖�-鐢佃姱淇℃伅 //绂荤綉閫嗗彉鍣� - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu_quick_off, DeviceType.INV, DeviceModel.OFF_INV), DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� - map.put(this.getStrJointNewUrl(FileName.hdl_inv_master_ecu_off, DeviceType.INV, DeviceModel.OFF_INV), DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄤ富鏈洪厤缃� - map.put(this.getStrJointNewUrl(FileName.hdl_inv_slave_ecu_off, DeviceType.INV, DeviceModel.OFF_INV), DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄤ粠鏈洪厤缃� - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu_info_pv_off, DeviceType.INV, DeviceModel.OFF_INV), DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄨ鎯呭厜浼忚緭鍏� - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu_info_input_off, DeviceType.INV, DeviceModel.OFF_INV), DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄨ鎯呬氦娴佽緭鍏� - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu_info_output_off, DeviceType.INV, DeviceModel.OFF_INV), DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄨ鎯呬氦娴佽緭鍑� - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu_info_item_off, DeviceType.INV, DeviceModel.OFF_INV), DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄨ鎯呭熀纭�鍙傛暟 - map.put(this.getStrJointNewUrl(FileName.hdl_inv_ecu_info_signal_off, DeviceType.INV, DeviceModel.OFF_INV), DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄨ鎯呯粺璁� - map.put(this.getStrJointNewUrl(FileName.hdl_bms_ecu_off, DeviceType.BMS, DeviceModel.OFF_INV_BMS), DeviceModel.OFF_INV_BMS);//绂荤綉閫嗗彉鍣˙MS璇︽儏 - map.put(this.getStrJointNewUrl(FileName.hdl_battery_ecu_off, DeviceType.BATTERY, DeviceModel.OFF_INV_BATTERY), DeviceModel.OFF_INV_BATTERY);//绂荤綉閫嗗彉鍣ㄧ數姹犺鎯� - map.put(this.getStrJointNewUrl(FileName.hdl_battery_ecu_cell_off, DeviceType.BATTERY, DeviceModel.OFF_INV_BATTERY), DeviceModel.OFF_INV_BATTERY);//绂荤綉閫嗗彉鍣ㄧ數姹犵數鑺� + stringList.add(FileName.hdl_inv_ecu_quick_off + "%" + DeviceType.INV + "%" + DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� + stringList.add(FileName.hdl_inv_master_ecu_off + "%" + DeviceType.INV + "%" + DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� + stringList.add(FileName.hdl_inv_slave_ecu_off + "%" + DeviceType.INV + "%" + DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� + stringList.add(FileName.hdl_inv_ecu_info_pv_off + "%" + DeviceType.INV + "%" + DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� + stringList.add(FileName.hdl_inv_ecu_info_input_off + "%" + DeviceType.INV + "%" + DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� + stringList.add(FileName.hdl_inv_ecu_info_output_off + "%" + DeviceType.INV + "%" + DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� + stringList.add(FileName.hdl_inv_ecu_info_item_off + "%" + DeviceType.INV + "%" + DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� + stringList.add(FileName.hdl_inv_ecu_info_signal_off + "%" + DeviceType.INV + "%" + DeviceModel.OFF_INV);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� + stringList.add(FileName.hdl_bms_ecu_off + "%" + DeviceType.BMS + "%" + DeviceModel.OFF_INV_BMS);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� + stringList.add(FileName.hdl_bms_ecu_off + "%" + DeviceType.BATTERY + "%" + DeviceModel.OFF_INV_BATTERY);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� + stringList.add(FileName.hdl_battery_ecu_cell_off + "%" + DeviceType.BATTERY + "%" + DeviceModel.OFF_INV_BATTERY);//绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� + return stringList; + } - + /** + * 鏂囦欢瀵瑰簲鐗堟湰鍙� + * + * @return map + */ + private Map<String, String> getFeliAndVersion() { + Map<String, String> map = new HashMap<>(); + map.put(FileName.hdl_lc_ecu_info_item, Version.v_1_5_0); + map.put(FileName.hdl_lc_ecu_quick, Version.v_1_5_0); + map.put(FileName.hdl_inv_ecu_quick, Version.v_1_5_1); + map.put(FileName.hdl_inv_ecu, Version.v_1_5_2); + map.put(FileName.hdl_inv_ecu_info_pv, Version.v_1_4_2); + map.put(FileName.hdl_inv_ecu_info_output, Version.v_1_4_2); + map.put(FileName.hdl_inv_ecu_info_item, Version.v_1_5_2); + map.put(FileName.hdl_inv_ecu_info_signal, Version.v_1_4_1); + map.put(FileName.hdl_bms_ecu, Version.v_1_4_2); + map.put(FileName.hdl_battery_ecu, Version.v_1_4_2); + map.put(FileName.hdl_battery_ecu_cell, Version.v_1_4_2); + //绂荤綉閫嗗彉鍣� + map.put(FileName.hdl_inv_ecu_quick_off, Version.v_1_5_2); + map.put(FileName.hdl_inv_master_ecu_off, Version.v_1_5_2); + map.put(FileName.hdl_inv_slave_ecu_off, Version.v_1_5_2); + map.put(FileName.hdl_inv_ecu_info_pv_off, Version.v_1_5_2); + map.put(FileName.hdl_inv_ecu_info_input_off, Version.v_1_5_2); + map.put(FileName.hdl_inv_ecu_info_output_off, Version.v_1_5_2); + map.put(FileName.hdl_inv_ecu_info_item_off, Version.v_1_5_2); + map.put(FileName.hdl_inv_ecu_info_signal_off, Version.v_1_5_2); + map.put(FileName.hdl_bms_ecu_off, Version.v_1_5_2); + map.put(FileName.hdl_battery_ecu_off, Version.v_1_5_2); + map.put(FileName.hdl_battery_ecu_cell_off, Version.v_1_5_2); return map; } @@ -91,26 +145,34 @@ * 鍚戜簯绔幏鍙朖son銆愭墍鏈夈�戣剼鏈� */ public void getAllHdlESLocalJson() { - for (Map.Entry<String, String> entry : getUrlMap().entrySet()) { - this.getHdlESLocalJson(entry.getKey(), entry.getValue(), null); + for (String str : this.getFileNameAndDeviceTypeAndDeviceModeList()) { + String[] ary = str.split("%"); + String fileName = ary[0]; + String deviceType = ary[1]; + String deviceMode = ary[2]; + this.getHdlESLocalJson(fileName, deviceType, deviceMode, null); } + } /** * 鍚戜簯绔幏鍙朖son銆愬崟涓�戣剼鏈� * - * @param url 鍦板潃 + * @param fileName 鏂囦欢鍚� + * @param deviceType 璁惧绫诲瀷 * @param deviceModel 璁惧鍨嬪彿 */ - public void getHdlESLocalJson(String url, String deviceModel, CloudCallBeak<String> callBeak) { + public void getHdlESLocalJson(String fileName, String deviceType, String deviceModel, CloudCallBeak<String> callBeak) { + //鎷兼帴鍦板潃 + String url = getStrJointNewUrl(fileName, deviceType, deviceModel); HttpClient.getInstance().requestJsonHttpGet(url, new CloudCallBeak<String>() { @Override - public void onSuccess(String str) { - saveJson(url, deviceModel, str); - HdlLogLogic.print("鑾峰彇浜戠鑴氭湰---" + url + "\r\n" + str, false); + public void onSuccess(String json) { + saveJson(fileName, deviceModel, json); + HdlLogLogic.print("鑾峰彇浜戠鑴氭湰---" + url + "\r\n" + json, false); if (callBeak != null) { - callBeak.onSuccess(str); + callBeak.onSuccess(json); } } @@ -127,31 +189,23 @@ /** * 璇诲彇鏈湴json鏁版嵁 * - * @param url 鍦板潃 + * @param fileName 鏂囦欢鍚� * @param deviceModel 璁惧鍨嬪彿 */ - public String readHdlESLocalJson(String url, String deviceModel) { - return this.readJson(url, deviceModel); + public String readHdlESLocalJson(String fileName, String deviceModel) { + return this.readJson(fileName, deviceModel); } /** * 淇濆瓨json鏁版嵁 * - * @param fileUrlOrFileName 鍦板潃鎴栬�呮枃浠跺悕 - * @param deviceModel 璁惧鍨嬪彿锛堥�嗗彉鍣紝璐熻浇涓績锛宐ms锛岀數姹犲寘锛� - * @param json 鍐呭 + * @param fileName 鏂囦欢鍚� + * @param deviceModel 璁惧鍨嬪彿锛堥�嗗彉鍣紝璐熻浇涓績锛宐ms锛岀數姹犲寘锛� + * @param json 鍐呭 */ - private void saveJson(String fileUrlOrFileName, String deviceModel, String json) { + private void saveJson(String fileName, String deviceModel, String json) { try { if (TextUtils.isEmpty(json)) { - return; - } - String fileName = fileUrlOrFileName; - if (fileUrlOrFileName.contains("/")) { - //琛ㄧず閾炬帴,鎴彇鏈�鍚庝竴涓储寮曡〃绀烘枃浠跺悕 - fileName = fileUrlOrFileName.split("/")[fileUrlOrFileName.split("/").length - 1]; - } - if (TextUtils.isEmpty(fileName)) { return; } //鑻辨枃鏂囦欢璺緞 @@ -169,16 +223,11 @@ /** * 璇诲彇json鏁版嵁 * - * @param fileUrlOrFileName 鍦板潃鎴栬�呮枃浠跺悕 - * @param deviceModel 璁惧鍨嬪彿锛堥�嗗彉鍣紝璐熻浇涓績锛宐ms锛岀數姹犲寘锛� + * @param fileName 鏂囦欢鍚� + * @param deviceModel 璁惧鍨嬪彿锛堥�嗗彉鍣紝璐熻浇涓績锛宐ms锛岀數姹犲寘锛� */ - private String readJson(String fileUrlOrFileName, String deviceModel) { + private String readJson(String fileName, String deviceModel) { try { - String fileName = fileUrlOrFileName; - if (fileUrlOrFileName.contains("/")) { - //琛ㄧず閾炬帴,鎴彇鏈�鍚庝竴涓储寮曡〃绀烘枃浠跺悕 - fileName = fileUrlOrFileName.split("/")[fileUrlOrFileName.split("/").length - 1]; - } if (TextUtils.isEmpty(fileName)) { return ""; } @@ -198,118 +247,132 @@ * Json鏁版嵁閰嶇疆鏂囦欢鍚� */ public @interface FileName { + /** * 鍒涘缓鐢电珯-閫嗗彉鍣ㄥ弬鏁伴厤缃� */ - String hdl_inv_ecu_quick = "modbus_hdl_inv_ecu_quick_v1.5.1.json"; + String hdl_inv_ecu_quick = "modbus_hdl_inv_ecu_quick_v"; /** * 鍒涘缓鐢电珯-璐熻浇鎺у埗涓績鍙傛暟閰嶇疆 */ - String hdl_lc_ecu_quick = "modbus_hdl_lc_ecu_quick_v1.5.0.json"; + String hdl_lc_ecu_quick = "modbus_hdl_lc_ecu_quick_v"; /** * 閫嗗彉鍣ㄥ弬鏁伴厤缃紙config锛� */ - String hdl_inv_ecu = "modbus_hdl_inv_ecu_v1.5.2.json"; + String hdl_inv_ecu = "modbus_hdl_inv_ecu_v"; /** * 閫嗗彉鍣ㄨ鎯�-pv */ - String hdl_inv_ecu_info_pv = "info/modbus_hdl_inv_ecu_info_pv_v1.4.2.json"; + String hdl_inv_ecu_info_pv = "info/modbus_hdl_inv_ecu_info_pv_v"; /** * 閫嗗彉鍣ㄨ鎯�-杈撳嚭 */ - String hdl_inv_ecu_info_output = "info/modbus_hdl_inv_ecu_info_output_v1.4.2.json"; + String hdl_inv_ecu_info_output = "info/modbus_hdl_inv_ecu_info_output_v"; /** * 閫嗗彉鍣ㄨ鎯�-item椤� */ - String hdl_inv_ecu_info_item = "info/modbus_hdl_inv_ecu_info_item_v1.5.2.json"; + String hdl_inv_ecu_info_item = "info/modbus_hdl_inv_ecu_info_item_v"; /** * 鑾峰彇璐熻浇鎺у埗涓績 */ - String hdl_lc_ecu_info_item = "modbus_hdl_lc_ecu_info_item_v1.5.0.json"; + String hdl_lc_ecu_info_item = "modbus_hdl_lc_ecu_info_item_v"; /** * 鑾峰彇BMS淇℃伅 */ - String hdl_bms_ecu = "modbus_hdl_bms_ecu_v1.4.2.json"; + String hdl_bms_ecu = "modbus_hdl_bms_ecu_v"; /** * 鐢垫睜鍖呬俊鎭� */ - String hdl_battery_ecu = "modbus_hdl_battery_ecu_v1.4.2.json"; + String hdl_battery_ecu = "modbus_hdl_battery_ecu_v"; /** * 鐢垫睜鍖�-鐢佃姱淇℃伅 */ - String hdl_battery_ecu_cell = "modbus_hdl_battery_ecu_cell_v1.4.2.json"; + String hdl_battery_ecu_cell = "modbus_hdl_battery_ecu_cell_v"; /** * 閫嗗彉鍣ㄨ鎯�-淇″彿鐐� */ - String hdl_inv_ecu_info_signal = "info/modbus_hdl_inv_ecu_info_signal_v1.4.1.json"; + String hdl_inv_ecu_info_signal = "info/modbus_hdl_inv_ecu_info_signal_v"; /** * 绂荤綉閫嗗彉鍣ㄥ揩閫熼厤缃� */ - String hdl_inv_ecu_quick_off = "modbus_hdl_inv_ecu_quick_v1.5.2.json"; + String hdl_inv_ecu_quick_off = "modbus_hdl_inv_ecu_quick_v"; /** * 绂荤綉閫嗗彉鍣ㄤ富鏈洪厤缃� */ - String hdl_inv_master_ecu_off = "modbus_hdl_inv_master_ecu_v1.5.2.json"; + String hdl_inv_master_ecu_off = "modbus_hdl_inv_master_ecu_v"; /** * 绂荤綉閫嗗彉鍣ㄤ粠鏈洪厤缃� */ - String hdl_inv_slave_ecu_off = "modbus_hdl_inv_slave_ecu_v1.5.2.json"; + String hdl_inv_slave_ecu_off = "modbus_hdl_inv_slave_ecu_v"; /** * 绂荤綉閫嗗彉鍣ㄨ鎯呭厜浼忚緭鍏� */ - String hdl_inv_ecu_info_pv_off = "modbus_hdl_inv_ecu_info_pv_v1.5.2.json"; + String hdl_inv_ecu_info_pv_off = "modbus_hdl_inv_ecu_info_pv_v"; /** * 绂荤綉閫嗗彉鍣ㄨ鎯呬氦娴佽緭鍏� */ - String hdl_inv_ecu_info_input_off = "modbus_hdl_inv_ecu_info_input_v1.5.2.json"; + String hdl_inv_ecu_info_input_off = "modbus_hdl_inv_ecu_info_input_v"; /** * 绂荤綉閫嗗彉鍣ㄨ鎯呬氦娴佽緭鍑� */ - String hdl_inv_ecu_info_output_off = "modbus_hdl_inv_ecu_info_output_v1.5.2.json"; + String hdl_inv_ecu_info_output_off = "modbus_hdl_inv_ecu_info_output_v"; /** * 绂荤綉閫嗗彉鍣ㄨ鎯呭熀纭�鍙傛暟 */ - String hdl_inv_ecu_info_item_off = "modbus_hdl_inv_ecu_info_item_v1.5.2.json"; + String hdl_inv_ecu_info_item_off = "modbus_hdl_inv_ecu_info_item_v"; /** * 绂荤綉閫嗗彉鍣ㄨ鎯呯粺璁� */ - String hdl_inv_ecu_info_signal_off = "modbus_hdl_inv_ecu_info_signal_v1.5.2.json"; + String hdl_inv_ecu_info_signal_off = "modbus_hdl_inv_ecu_info_signal_v"; /** * 绂荤綉閫嗗彉鍣˙MS璇︽儏 */ - String hdl_bms_ecu_off = "modbus_hdl_bms_ecu_v1.5.2.json"; + String hdl_bms_ecu_off = "modbus_hdl_bms_ecu_v"; /** * 绂荤綉閫嗗彉鍣ㄧ數姹犺鎯� */ - String hdl_battery_ecu_off = "modbus_hdl_battery_ecu_v1.5.2.json"; + String hdl_battery_ecu_off = "modbus_hdl_battery_ecu_v"; /** * 绂荤綉閫嗗彉鍣ㄧ數姹犵數鑺� */ - String hdl_battery_ecu_cell_off = "modbus_hdl_battery_ecu_cell_v1.5.2.json"; + String hdl_battery_ecu_cell_off = "modbus_hdl_battery_ecu_cell_v"; /** * 鑾峰彇閫嗗彉鍣ㄦ墍鏈塲son涓枃 */ - String hdl_inv_ecu_all_zh = "/zh/all_v1.5.1.json"; + String hdl_inv_ecu_all_zh = "/zh/all_v"; /** * 鑾峰彇閫嗗彉鍣ㄦ墍鏈塲son鑻辨枃 */ - String hdl_inv_ecu_all_en = "/en/all_v1.5.1.json"; + String hdl_inv_ecu_all_en = "/en/all_v"; + + } + + + /** + * 鐗堟湰鍙� + */ + public @interface Version { + String v_1_4_1 = "1.4.1"; + String v_1_4_2 = "1.4.2"; + String v_1_5_0 = "1.5.0"; + String v_1_5_1 = "1.5.1"; + String v_1_5_2 = "1.5.2"; } -- Gitblit v1.8.0