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

text
A8 00 11 7A 10 43 53 51 3A 32 37 3B 42 50 3A 30 FC
text
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
FC ----------------------------------------------- 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

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