Skip to content

Heart

1、The cabinet publishes data every 9 minutes and sends and receives the same data.
2、Publishing and subscribing are the same topic.
3、If the cabinet does not receive return data for 2 consecutive times, that is, for 18 minutes, the cabinet will determine that it is offline and restart.

Command Send ▼

Subscribe to topic:/powerbank/{uuid}/user/heart

Data format: bytecode data, Hex, hexadecimal analysis

BytecodeNameIdentification codeRemarks
Byte[0]Head codeheadDefault: 0xA8
Byte[1~2]Packet lengthlengthFor example: 0x01 0x25, converted to decimal, the packet length is 293
Byte[3]Command namecmdDefault: 0x7A, heartbeat detection
Byte[4]Control board addresscontrolIndexDefault: 0x10
Byte[5~n]Signal value;Backup PowersignalASCII display, for example: CSQ:26;BP:0
Byte[n+1]Check codeverifyPacket complement check

Signal value (signal) The signal strength value range is 0 ~ 31, and the larger the value, the better the signal strength. Learn more

Parameter range990~1515~31
Signal strength descriptionNo networkWeakBetter

Backup power status (backupPower)

-Bit[3]
Reserved
Bit[2]
Reserved
Bit[1]
Operation status
Bit[0]
Support backup power
-
0x000000No backup power support; stop operation
0x010010Invalid value
0x020001Support backup power; stop operation
0x030011Support backup power; Running

Example

A8 00 11 7A 10 43 53 51 3A 32 37 3B 42 50 3A 30 FC

json
A8 ----------------------------------------------- Byte[0] header code
00 10 ---------------------------------------------Byte[1~2] package Length: 16
7A ----------------------------------------------- Byte[3] Heartbeat Detection instructions
10 ----------------------------------------------- Byte[4] Control Board address
43 53 51 3A 32 37 3B 42 50 3A 30 ------------------Byte[5~n] Signal value, ASCII display: CSQ:26;BP:0
1A ----------------------------------------------- Byte[n+1 ] Code verification

Command Reply △

Publish to topic:/powerbank/{uuid}/user/heart

Data format: bytecode data, Hex, hexadecimal analysis(Same content as the command issuance)

Example

A8 00 10 7A 10 43 53 51 3A 20 33 31 2C 39 39 7B