pub enum Command {
Show 14 variants
Ping,
GetInfo,
GetStatus,
ListKeymap {
offset: u16,
},
SetMapping(Mapping),
RemoveMapping {
ir: IrCode,
},
ClearKeymap,
ResetKeymap,
Learn {
key: HidKey,
timeout_ms: u32,
},
CancelLearn,
SendHid {
key: HidKey,
},
SendIr {
code: IrCode,
},
SetMonitor {
enabled: bool,
},
GetBuildInfo,
}Variants§
Ping
GetInfo
GetStatus
ListKeymap
Returns one KeymapPage starting at offset.
SetMapping(Mapping)
Add or replace a mapping; persisted immediately.
RemoveMapping
ClearKeymap
Remove every mapping.
ResetKeymap
Restore the firmware’s compiled-in default keymap.
Learn
Bind the next received IR code to key. Replies immediately; the
outcome arrives later as Event::Learned, Event::LearnTimedOut
or Event::LearnFailed.
CancelLearn
SendHid
Send a key press + release over BLE HID, bypassing IR.
SendIr
Transmit a NEC code through the IR blaster.
SetMonitor
Enable/disable Event::IrReceived notifications.
GetBuildInfo
Returns BuildInfo: git commit, toolchain and component versions.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Command
impl<'de> Deserialize<'de> for Command
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Command
impl StructuralPartialEq for Command
Auto Trait Implementations§
impl Freeze for Command
impl RefUnwindSafe for Command
impl Send for Command
impl Sync for Command
impl Unpin for Command
impl UnsafeUnpin for Command
impl UnwindSafe for Command
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more