diff --git a/xhpc-modules/xhpc-power-pile/src/main/java/com/xhpc/pp/controller/PileController.java b/xhpc-modules/xhpc-power-pile/src/main/java/com/xhpc/pp/controller/PileController.java index 5b9c67e4..4dfe0340 100644 --- a/xhpc-modules/xhpc-power-pile/src/main/java/com/xhpc/pp/controller/PileController.java +++ b/xhpc-modules/xhpc-power-pile/src/main/java/com/xhpc/pp/controller/PileController.java @@ -305,7 +305,7 @@ public class PileController { } int runFlag = charging ? 2: 1; try { - String rsmsg = RemoteUpgradeDataLogic.translate(pileNo, "0094", + String rsmsg = RemoteUpgradeDataLogic.translate(pileNo, "0", 0L, "0", "0", "0", runFlag); diff --git a/xhpc-modules/xhpc-power-pile/src/main/java/com/xhpc/pp/logic/RemoteUpgradeDataLogic.java b/xhpc-modules/xhpc-power-pile/src/main/java/com/xhpc/pp/logic/RemoteUpgradeDataLogic.java index db44b07a..605a1c96 100644 --- a/xhpc-modules/xhpc-power-pile/src/main/java/com/xhpc/pp/logic/RemoteUpgradeDataLogic.java +++ b/xhpc-modules/xhpc-power-pile/src/main/java/com/xhpc/pp/logic/RemoteUpgradeDataLogic.java @@ -44,7 +44,7 @@ public class RemoteUpgradeDataLogic implements ServiceLogic { return new ServiceResult(null, ServiceResult.FAIL, json); } - String resultStr = translate(pileNo, "0094", "0", 0L, "0", "0", "0", 2); + String resultStr = translate(pileNo, "0", 0L, "0", "0", "0", 2); String remark = "充电桩主动下发远程更新"; XhpcDeviceMessage deviceMessage = new XhpcDeviceMessage(); @@ -57,14 +57,14 @@ public class RemoteUpgradeDataLogic implements ServiceLogic { return new ServiceResult(HexUtils.toBytes(resultStr), ServiceResult.OK); } - public static String translate(String pileNo, String svc, String remoteHost, Long port, String ftpUserName, String ftpPassword, String upgradeUrl, int runFlag) { + public static String translate(String pileNo, String remoteHost, Long port, String ftpUserName, String ftpPassword, String upgradeUrl, int runFlag) { String skey = "pile:".concat(pileNo).concat(".seqhex"); Map cachePile = REDIS.getCacheMap("pile:".concat(pileNo)); Long pileType = Long.parseLong(cachePile.get("equipmentType") + ""); // 桩型号(01-直流, 02-交流) Long pilePower = new Double((double)cachePile.get("power")).longValue(); // 桩功率 - String resultStr = "6862".concat(seqHex(skey)).concat(svc) + String resultStr = "6862".concat(seqHex(skey)).concat("0094") .concat(pileNo).concat(String.format("%02X", pileType)).concat(String.format("%04X", pilePower)) .concat(stringToAscii(remoteHost, 16)).concat(String.format("%02X", port)) .concat(stringToAscii(ftpUserName, 16)).concat(stringToAscii(ftpPassword, 16))