pub fn encode_cmd(cmd: &GenCpCmd) -> Bytes
Encode a GenCP command into the on-the-wire representation.
The returned buffer is ready to be transmitted by the transport layer.