#pragma once
#ifdef __cplusplus
extern "C"
{
#endif
#include <stdint.h>
#include <stdio.h>
const char *packet_parse(struct packet *pkt, const char *data, uint16_t len);
// bref : 1, output packet bref info
// bref : 0, output packet detail info
int packet_to_str(const struct packet *pkt, char *buff, int size);
static inline void packet_print(const struct packet *pkt)
char buff[4096];
packet_to_str(pkt, buff, sizeof(buff));
printf("%s\n", buff);
}