#[unsafe(no_mangle)]pub unsafe extern "C" fn pamoja_mavlink_frame_parse_known(
bytes: *const u8,
bytes_len: usize,
dialect: *const PamojaMavlinkDialect,
out_frame: *mut *mut PamojaMavlinkFrame,
) -> PamojaStatusExpand description
Parses one frame, looking its CRC_EXTRA up as it goes.
This is what a receiver holding many message types uses: the id comes out of the frame, and the seed comes from the dialect table or the common registry.
§Arguments
bytes- the frame as received.bytes_len- how many bytesbytesholds.dialect- the dialect to prefer, or null for the common one alone.out_frame- set to the frame handle on success, and to null otherwise.
§Returns
PamojaStatus::Ok on success.
§Errors
Returns PamojaStatus::InvalidArgument if out_frame is null, and
PamojaStatus::Codec if the bytes are not a whole frame, the checksum does
not match, or no dialect here knows the message id.
§Safety
bytes must point to bytes_len readable bytes when the length is non-zero,
dialect must be a live dialect handle or null, and out_frame must point at
writable storage for one pointer.