int32_t msp_send_com(struct msp_parser *parser, struct pios_com_dev *com, enum msp_message_id msg_id, void *payload, uint8_t len)
Construct and send an MSP message via PIOS_COM.
Main PiOS header to include all the compiled in PiOS options.
int32_t msp_register_handler(struct msp_parser *parser, msp_handler_t handler, void *context)
Register a handler for valid received messages.
uint8_t payload[CRSF_MAX_PAYLOAD+CRSF_CRC_LEN]
uint8_t data[XFER_BYTES_PER_PACKET]
int32_t msp_process_buffer(struct msp_parser *parser, void *buf, uint8_t len)
Process MSP stream from buffer.
bool(* msp_handler_t)(enum msp_message_id msg_id, void *data, uint8_t len, void *context)
Handler to be called when valid MSP messages are recieved.
int32_t msp_process_com(struct msp_parser *parser, struct pios_com_dev *com)
Process MSP stream from PIOS_COM.
struct msp_parser * msp_parser_init(enum msp_parser_type type)
Initialize a new parser instance.