Description

The Battery command is used to retrieve Neblina's battery state of charge (SoC). The Battery SoC is represented as a fixed-point percentage value with one decimal fractional digit precision, i.e, a SoC of 98.4% will be represented as 984.

Protocol

This command uses the Command-Ack-Response protocol.

Command

Byte Name C Type Value
0 Control Byte ( Packet Type (7:5) / SubSystem (4:0) ) uint8_t 0x42 ( 0b010 / 0b00010 )
1 Payload Length uint8_t 0
2 CRC uint8_t Calculated
3 Command uint8_t 0x00

Payload

This command contains no payload

Response

Header

Byte Name C Type Value
0 Control Byte ( Packet Type (7:5) / SubSystem (4:0) ) uint8_t 0x02 ( 0b000 / 0b00010 )
1 Payload Length uint8_t 2
2 CRC uint8_t Calculated
3 Command uint8_t 0x00

Payload

Byte Name C Type Value
4 - 5 State Of Chage uint16_t Varies