26 {0x48, 0x00, 0x00, 0x01, 0xAA, 0x87}},
30 {0x69, 0x40, 0x00, 0x00, 0x00, 0x77}},
34 for (
size_t i = 0; i <
sizeof(cases) /
sizeof(cases[0]); ++i) {
49 const uint8_t good[4] = {0x00, 0x00, 0x01, 0xAA};
50 const uint8_t wrong_pattern[4] = {0x00, 0x00, 0x01, 0x55};
51 const uint8_t wrong_voltage[4] = {0x00, 0x00, 0x02, 0xAA};
59 uint8_t cid[16] = {0x03, 0x53, 0x44, 0x53, 0x55, 0x31, 0x36, 0x47,
60 0x80, 0x12, 0x34, 0x56, 0x78, 0x01, 0x4A, 0xB7};
62 for (
int i = 0; i < 16; ++i) {
70 uint8_t ff[16], zero[16];
72 memset(zero, 0x00, 16);
static std::vector< uint8_t > frame(uint8_t hi, uint8_t lo, size_t payload_len, uint8_t fill)
One wire packet: len(4, LE) then len bytes of body, where the first 4 body bytes are ty/packet_id(2)/...