pub fn encode_with_command( command: u8, input: &[u8], output: &mut [u8], ) -> Result<usize, EncodeError>