pub trait RemoteControlModel: Default {
    type Cmd: AddressCommand;

    const PROTOCOL: ProtocolId;
    const ADDRESS: u32;
    const MODEL: &'static str = "<NONAME>";
    const DEVTYPE: DeviceType = DeviceType::Generic;
    const BUTTONS: &'static [(u32, Action)] = _;

    fn decode(cmd: &Self::Cmd) -> Option<Action> { ... }
    fn encode(button: &Action) -> Option<Self::Cmd> { ... }
}
Expand description

A trait describing a Remote Control

Required Associated Types§

The type of command

Required Associated Constants§

Protocol

Device address

Provided Associated Constants§

Remote control model

Type of device that this remote controls

command byte to action mapping

Provided Methods§

Try to map a command into a Action for this remote

Encode a button into a command

Implementors§