pub fn write_frame_header(buf: &mut Vec<u8>, msg_type: u8, payload_len: u32)
Write a frame header: [total_len: u32 LE][msg_type: u8]