encode_frame

Function encode_frame 

Source
pub fn encode_frame(data: &[u8]) -> Vec<u8> 
Expand description

Encode arbitrary bytes as a SLIP frame and return the encoded data as a newly allocated Vec.

The returned frame always ends with the END delimiter. See examples/basic.rs for an end-to-end demonstration.