绿能3.4 gunCode用int接收

This commit is contained in:
三丙
2025-08-20 19:25:18 +08:00
parent babd1696f6
commit ca2610ba93
4 changed files with 5 additions and 5 deletions

View File

@@ -263,7 +263,7 @@ public class DefaultPileProtocolService implements PileProtocolService {
String tradeNo = transactionRecordRequest.getTradeNo();
String pileCode = transactionRecordRequest.getPileCode();
// 构造下行计费
// 构造下行应答
DownlinkRequestMessage.Builder downlinkMessageBuilder = createDownlinkMessageBuilder(uplinkQueueMessage, pileCode);
downlinkMessageBuilder.setDownlinkCmd(DownlinkCmdEnum.TRANSACTION_RECORD_ACK.name());

View File

@@ -96,7 +96,7 @@ public class LvnengV340LoginAckDLCmd extends LvnengDownlinkCmdExe {
private void registerSyncTimeTask(TcpSession tcpSession, byte[] pileCodeBytes, LvnengUplinkMessage requestData) {
tcpSession.addSchedule(SCHEDULE_KEY_AUTO_SYNC_TIME, k -> {
log.info("{} 云快充3.4开始注册定时对时任务", tcpSession);
log.info("{} 绿能3.4开始注册定时对时任务", tcpSession);
return PROTOCOL_SESSION_SCHEDULED.scheduleAtFixedRate(() ->
syncTime(tcpSession, pileCodeBytes, requestData),
0, RandomUtil.randomInt(420, 480), TimeUnit.MINUTES);

View File

@@ -67,7 +67,7 @@ public class LvnengV340RealTimeDataULCmd extends LvnengUplinkCmdExe {
additionalInfo.put("充电枪数量", gunsNum);
//5 充电枪口
byte gunCode = byteBuf.readByte();
int gunCode = byteBuf.readByte();
additionalInfo.put("充电枪口", gunCode);
//6 充电枪类型
@@ -272,7 +272,7 @@ public class LvnengV340RealTimeDataULCmd extends LvnengUplinkCmdExe {
realTimeDataAck(tcpSession, gunCode);
}
private void realTimeDataAck(TcpSession tcpSession, byte gunCode) {
private void realTimeDataAck(TcpSession tcpSession, int gunCode) {
ByteBuf pingAckMsgBody = Unpooled.buffer(5);
pingAckMsgBody.writeShortLE(0);
pingAckMsgBody.writeShortLE(0);

View File

@@ -69,7 +69,7 @@ public class LvnengV340TransactionRecordULCmd extends LvnengUplinkCmdExe {
additionalInfo.put("充电枪位置类型", gunType);
//5 充电枪口
byte gunCode = byteBuf.readByte();
int gunCode = byteBuf.readByte();
additionalInfo.put("充电枪口", gunCode);
//6 卡号