Trait ddc::DdcCommand [] [src]

pub trait DdcCommand: DdcHost {
    fn execute<C: Command>(&mut self, command: C) -> Result<C::Ok, Self::Error>;

    fn checksum<II: IntoIterator<Item = u8>>(iter: II) -> u8 { ... }
fn encode_command<'a>(data: &[u8], packet: &'a mut [u8]) -> &'a [u8] { ... } }

A (slightly) higher level interface to DdcCommandRaw.

Some DDC implementations only provide access to the higher level commands exposed in the Ddc trait.

Required Methods

Execute a DDC/CI command. See the commands module for all available commands. The return type is dependent on the executed command.

Provided Methods

Computes a DDC/CI packet checksum

Important traits for &'a mut [u8]

Encodes a DDC/CI command into a packet.

packet.len() must be 3 bytes larger than data.len()

Implementors