mirror of
https://gitee.com/san-bing/JChargePointProtocol
synced 2026-05-04 01:49:58 +08:00
修正命名并补全示例
This commit is contained in:
@@ -33,8 +33,8 @@ public class TestController {
|
||||
return ResponseEntity.ok("success");
|
||||
}
|
||||
|
||||
@GetMapping("/api/reStartCharge")
|
||||
public ResponseEntity<String> reStartCharge() {
|
||||
@GetMapping("/api/restartPile")
|
||||
public ResponseEntity<String> restartPile() {
|
||||
|
||||
pileProtocolService.restartPile("20231212000010", 1);
|
||||
|
||||
|
||||
@@ -310,7 +310,7 @@ public class DefaultPileProtocolService implements PileProtocolService {
|
||||
.setPileCode(pileCode)
|
||||
.setRequestIdMSB(requestId.getMostSignificantBits())
|
||||
.setRequestIdLSB(requestId.getLeastSignificantBits())
|
||||
.setDownlinkCmd(DownlinkCmdEnum.REMOTE_RE_START_CHARGING.name())
|
||||
.setDownlinkCmd(DownlinkCmdEnum.REMOTE_RESTART_PILE.name())
|
||||
.setRestartPileRequest(RestartPileRequest.newBuilder()
|
||||
.setPileCode(pileCode)
|
||||
.setType(type)
|
||||
|
||||
@@ -248,7 +248,7 @@ message RemoteStartChargingRequest {
|
||||
message RestartPileRequest {
|
||||
string pileCode = 4;
|
||||
int32 type = 7;
|
||||
|
||||
optional string additionalInfo = 20;
|
||||
}
|
||||
|
||||
message RemoteStartChargingResponse {
|
||||
|
||||
@@ -27,5 +27,5 @@ public enum DownlinkCmdEnum {
|
||||
|
||||
REMOTE_PARALLEL_START_CHARGING,
|
||||
|
||||
REMOTE_RE_START_CHARGING,
|
||||
REMOTE_RESTART_PILE,
|
||||
}
|
||||
@@ -76,9 +76,13 @@
|
||||
#### 0x1D 充电阶段BMS中止
|
||||
`68 20 00 18 00 1D 20 23 12 12 00 00 01 01 11 51 11 61 55 53 50 26 20 23 12 12 00 00 10 01 00 00 00 00 5a 23`
|
||||
|
||||
---
|
||||
|
||||
#### 0x92 远程重启
|
||||
`68 0f 03 00 00 92 20 23 12 12 00 00 10 00 00 00 01 37 2b`
|
||||
|
||||
#### 0x91 远程重启应答
|
||||
`68 0C 00 11 00 91 20 23 12 12 00 00 10 01 03 F2`
|
||||
`68 0C 00 11 00 91 20 23 12 12 00 00 10 01 F2 03`
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ public enum YunKuaiChongDownlinkCmdEnum {
|
||||
|
||||
REMOTE_PARALLEL_START_CHARGING(0xA4),
|
||||
|
||||
REMOTE_RE_START_CHARGING(0x92);
|
||||
REMOTE_RESTART_PILE(0x92);
|
||||
|
||||
private final Integer cmd;
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ import sanbing.jcpp.protocol.yunkuaichong.annotation.YunKuaiChongCmd;
|
||||
*/
|
||||
@Slf4j
|
||||
@YunKuaiChongCmd(0x91)
|
||||
public class YunKuaiChongV150RestartPileResultULCmd extends YunKuaiChongUplinkCmdExe {
|
||||
public class YunKuaiChongV150RestartPileAckULCmd extends YunKuaiChongUplinkCmdExe {
|
||||
|
||||
@Override
|
||||
public void execute(TcpSession tcpSession, YunKuaiChongUplinkMessage yunKuaiChongUplinkMessage, ProtocolContext ctx) {
|
||||
@@ -16,7 +16,7 @@ import sanbing.jcpp.protocol.yunkuaichong.YunKuaiChongDownlinkCmdExe;
|
||||
import sanbing.jcpp.protocol.yunkuaichong.YunKuaiChongDwonlinkMessage;
|
||||
import sanbing.jcpp.protocol.yunkuaichong.annotation.YunKuaiChongCmd;
|
||||
|
||||
import static sanbing.jcpp.protocol.yunkuaichong.enums.YunKuaiChongDownlinkCmdEnum.REMOTE_RE_START_CHARGING;
|
||||
import static sanbing.jcpp.protocol.yunkuaichong.enums.YunKuaiChongDownlinkCmdEnum.REMOTE_RESTART_PILE;
|
||||
|
||||
/**
|
||||
* 云快充1.5.0 运营平台远程重启充电桩
|
||||
@@ -41,7 +41,7 @@ public class YunKuaiChongV150RestartPileDLCmd extends YunKuaiChongDownlinkCmdExe
|
||||
msgBody.writeBytes(encodePileCode(pileCode));
|
||||
// 0x01:立即执行 0x02:空闲执行
|
||||
msgBody.writeInt(type);
|
||||
encodeAndWriteFlush(REMOTE_RE_START_CHARGING,
|
||||
encodeAndWriteFlush(REMOTE_RESTART_PILE,
|
||||
msgBody,
|
||||
tcpSession);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user