Skip to main content

Command

Enum Command 

Source
#[non_exhaustive]
pub enum Command {
Show 52 variants SetFaderMute { fader: Fader, mute: bool, }, SetFaderCue { fader: Fader, enable: bool, }, SetFaderLevel { fader: Fader, level: u8, }, AssignFaderSource { fader: Fader, source: Option<Source>, }, SetMixDisabled { source: Source, mix: MixOutput, disabled: bool, }, SetMixMute { source: Source, mix: MixOutput, mute: bool, }, LinkMix { source: Source, mix: MixOutput, }, UnlinkMix { source: Source, mix: MixOutput, }, SetMixLevel { source: Source, mix: MixOutput, anchor: f32, value: f32, }, ScreenTouched, PowerOff, LinkCallMe { source: Source, mix: MixOutput, }, UnlinkCallMe { source: Source, mix: MixOutput, }, SetChannelParam { fader: Fader, param: ChannelParam, value: Value, }, SetInputSourceParam { source: Source, param: InputSourceParam, value: Value, }, SetMasterParam { param: MasterParam, value: Value, }, SetOutputParam { param: OutputParam, value: Value, }, SetDuckerParam { param: DuckerParam, value: Value, }, SetRecorderParam { param: RecorderParam, value: Value, }, SetPlayerParam { param: PlayerParam, value: Value, }, SetHeadphoneParam { headphone: u8, param: HeadphoneParam, value: Value, }, SetEffectsParam { effects: u8, param: EffectsParam, value: Value, }, SetGuiParam { param: GuiParam, value: Value, }, SetPadParam { pad: u8, param: PadParam, value: Value, }, SetSystemParam { param: SystemParam, value: Value, }, SetSipCallingParam { param: SipCallingParam, value: Value, }, SetSipRegistrationParam { registration: u8, param: SipRegistrationParam, value: Value, }, SetSipCallSlotsParam { slot: u8, param: SipCallSlotsParam, value: Value, }, SetSipAdvancedParam { param: SipAdvancedParam, value: Value, }, SetTestParam { param: TestParam, value: Value, }, SetPadRecorderParam { pad_recorder: u8, param: PadRecorderParam, value: Value, }, SetFxPresetParam { preset: u8, param: FxPresetParam, value: Value, }, SetNetworkParam { param: NetworkParam, value: Value, }, SetAudioParam { param: AudioParam, value: Value, }, SetBuildParam { param: BuildParam, value: Value, }, SetAppParam { param: AppParam, value: Value, }, SetThemeParam { param: ThemeParam, value: Value, }, SetCurrentShowParam { param: CurrentShowParam, value: Value, }, SetShowControlParam { param: ShowControlParam, value: Value, }, SetRecordingsParam { param: RecordingsParam, value: Value, }, SetRadioParam { param: RadioParam, value: Value, }, SetShowParam { show: u8, param: ShowParam, value: Value, }, SetRecordingParam { recording: u8, param: RecordingParam, value: Value, }, SetStorageVolumeParam { volume: u8, param: StorageVolumeParam, value: Value, }, SetRadioTxParam { tx: u8, param: RadioTxParam, value: Value, }, SetRadioRxParam { rx: u8, param: RadioRxParam, value: Value, }, SetWifiScanResultParam { slot: u8, param: WifiScanResultParam, value: Value, }, SetStreamerXMixPresetParam { preset: u8, param: StreamerXMixPresetParam, value: Value, }, SetStreamerXStreamMixParam { stream: u8, param: StreamerXStreamMixParam, value: Value, }, SetRcSyncMixParam { mix: u8, param: RcSyncMixParam, value: Value, }, SetMixMinusesParam { minuses: u8, param: MixMinusesParam, value: Value, }, SetupSkip { language: Option<String>, timezone: Option<String>, },
}
Expand description

An outgoing command sent to a RØDECaster console.

Variants use high-level domain types (Fader, Source, MixOutput) which are dynamically translated into the device’s internal wire addresses when encoded.

Variants (Non-exhaustive)§

This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
§

SetFaderMute

Set the output mute on a fader strip.

Fields

§fader: Fader
§mute: bool
§

SetFaderCue

Set the cue (pre-fader-listen) enable on a fader strip.

Fields

§fader: Fader
§enable: bool
§

SetFaderLevel

Set a virtual fader’s level (0..127 MIDI scale). Physical fader levels come from hardware over MIDI/UART, not this path.

Fields

§fader: Fader
§level: u8
§

AssignFaderSource

Assign (or clear, with None) the input source for a fader strip.

Fields

§fader: Fader
§source: Option<Source>
§

SetMixDisabled

Enable or disable a routing matrix cell.

Fields

§source: Source
§disabled: bool
§

SetMixMute

Mute or unmute a routing matrix cell. This is the per-cell mixMute, distinct from the per-strip Command::SetFaderMute. The device clears it as part of a native link; exposed on its own so callers can compose.

Fields

§source: Source
§mute: bool
§

LinkMix

Link a routing matrix cell with the device-validated minimal sequence: enable (mixDisabled=false), unmute (mixMute=false), then a single Binary trigger write to mixLinkRequest. encode returns three frames in order. The atomic halves are also callable on their own as Command::SetMixDisabled and Command::SetMixMute; a press on mixLinkRequest alone does NOT auto-clear mixDisabled or mixMute.

Fields

§source: Source
§

UnlinkMix

Unlink a routing matrix cell with a single Binary trigger write to mixUnlinkRequest. mixDisabled and mixMute retain their prior values (the unlink does not re-disable or re-mute the cell).

Fields

§source: Source
§

SetMixLevel

Set a routing matrix cell’s sub-mix send level and tracking value.

Encodes mixLevelWithAnchor on the matrix cell’s path as "anchor|value". In broadcast mixing terminology, anchor represents the custom sub-mix send level (active when the cell is unlinked), and value represents the post-fader program level.

Fields

§source: Source
§anchor: f32
§value: f32
§

ScreenTouched

Wake the device display. A fixed, layout-independent message; see SCREEN_TOUCHED_FRAME.

§

PowerOff

Request the device power off.

§

LinkCallMe

Link a CallMe return channel into a mix. source must be a CallMe source (Source::CallMe1..=Source::CallMe3); on firmware where CallMe sits outside the mix matrix it is addressed by a dedicated request path, so this sends a single legacy mixLinkRequest blob (no enable/unmute or press/release pulse, unlike Command::LinkMix).

Fields

§source: Source
§

UnlinkCallMe

Unlink a CallMe return channel from a mix. See Command::LinkCallMe.

Fields

§source: Source
§

SetChannelParam

Set a channel-strip DSP parameter on a fader’s CHANNEL node.

Fields

§fader: Fader
§value: Value
§

SetInputSourceParam

Set an input-source parameter on a source’s INPUTSOURCE node.

Fields

§source: Source
§value: Value
§

SetMasterParam

Set a master-bus parameter on the MASTERCHANNEL node.

Fields

§value: Value
§

SetOutputParam

Set an output-bus parameter on the OUTPUT node.

Fields

§value: Value
§

SetDuckerParam

Set the auto-duck depth on the DUCKER node.

Fields

§value: Value
§

SetRecorderParam

Set a recorder transport property on the RECORDER node.

Fields

§value: Value
§

SetPlayerParam

Set a player property on the PLAYER node.

Fields

§value: Value
§

SetHeadphoneParam

Set a headphone property on a HEADPHONE node.

Fields

§headphone: u8
§value: Value
§

SetEffectsParam

Set an effects parameter on an EFFECTS_PARAMETERS node.

Fields

§effects: u8
§value: Value
§

SetGuiParam

Set a front-panel UI parameter on the GUI node.

Fields

§param: GuiParam
§value: Value
§

SetPadParam

Set a sound-pad parameter on a PAD node.

Fields

§pad: u8
§param: PadParam
§value: Value
§

SetSystemParam

Set a device-wide system parameter on the SYSTEM node.

Fields

§value: Value
§

SetSipCallingParam

Set a SIP calling parameter on the SIPCALLING node.

Fields

§value: Value
§

SetSipRegistrationParam

Set a per-registration SIP parameter on a SIPREGISTRATION node.

Fields

§registration: u8
§value: Value
§

SetSipCallSlotsParam

Set a per-call-slot SIP parameter on a SIPCALLSLOTS node.

Fields

§slot: u8
§value: Value
§

SetSipAdvancedParam

Set a SIP advanced parameter on the SIPADVANCED node.

Fields

§value: Value
§

SetTestParam

Set a diagnostic parameter on the TEST node.

Fields

§value: Value
§

SetPadRecorderParam

Set a pad recorder parameter on a PADRECORDER node.

Fields

§pad_recorder: u8
§value: Value
§

SetFxPresetParam

Set an effects preset parameter on an FXPRESET node.

Fields

§preset: u8
§value: Value
§

SetNetworkParam

Set a networking parameter on the singleton NETWORK node.

Fields

§value: Value
§

SetAudioParam

Set an audio engine parameter on the singleton AUDIO node.

Fields

§value: Value
§

SetBuildParam

Set a build parameter on the singleton BUILD node.

Fields

§value: Value
§

SetAppParam

Set a companion-app parameter on the singleton APP node.

Fields

§param: AppParam
§value: Value
§

SetThemeParam

Set a theme parameter on the singleton THEME node.

Fields

§value: Value
§

SetCurrentShowParam

Set a current-show parameter on the singleton CURRENTSHOW node.

Fields

§value: Value
§

SetShowControlParam

Set a show-control parameter on the singleton SHOWCONTROL node.

Fields

§value: Value
§

SetRecordingsParam

Set a recordings-container parameter on the singleton RECORDINGS node.

Fields

§value: Value
§

SetRadioParam

Set a wireless-radio parameter on the singleton RADIO node.

Fields

§value: Value
§

SetShowParam

Set a per-show parameter on one of the SHOW child nodes under SHOWS.

Fields

§show: u8
§value: Value
§

SetRecordingParam

Set a per-recording parameter on one of the RECORDING child nodes under RECORDINGS.

Fields

§recording: u8
§value: Value
§

SetStorageVolumeParam

Set a storage volume parameter on one of the STORAGEVOLUME nodes.

Fields

§volume: u8
§value: Value
§

SetRadioTxParam

Set a wireless-radio transmitter parameter on one of the RADIOTX nodes.

Fields

§tx: u8
§value: Value
§

SetRadioRxParam

Set a wireless-radio receiver parameter on one of the RADIORX nodes.

Fields

§rx: u8
§value: Value
§

SetWifiScanResultParam

Set a WiFi scan result entry parameter on one of the WIFISCANRESULT nodes.

Fields

§slot: u8
§value: Value
§

SetStreamerXMixPresetParam

Set a StreamerX mix preset parameter on one of the STREAMERXMIXPRESET nodes.

Fields

§preset: u8
§value: Value
§

SetStreamerXStreamMixParam

Set a StreamerX stream mix parameter on one of the STREAMERXSTREAMMIX nodes.

Fields

§stream: u8
§value: Value
§

SetRcSyncMixParam

Set an rcSync mix parameter on one of the RCSYNCMIX nodes.

Fields

§mix: u8
§value: Value
§

SetMixMinusesParam

Set a mix-minus parameter on one of the MIXMINUSES nodes.

Fields

§minuses: u8
§value: Value
§

SetupSkip

Skip initial setup mode and configure language and timezone.

Fields

§language: Option<String>
§timezone: Option<String>

Implementations§

Source§

impl Command

Source

pub fn encode(&self, layout: &Layout) -> Result<Vec<Vec<u8>>, EncodeError>

Encode this command into one or more change-frame payloads to send in order. Err(EncodeError::OutOfRange) if the addressed entity does not exist in the layout (e.g., fader index past Layout::fader_count).

Wrap each payload in a crate::frame::Packet for the transport.

Examples found in repository?
examples/cli.rs (line 527)
517fn one_shot(
518    writer: &Writer,
519    layout: &Shared<Option<Layout>>,
520    cmd: Command,
521) -> Result<Outcome, String> {
522    let guard = layout.lock().unwrap();
523    let layout_ref = guard
524        .as_ref()
525        .ok_or_else(|| "no Layout yet; wait for the fullSync print".to_string())?;
526    let frames = cmd
527        .encode(layout_ref)
528        .map_err(|e| format!("encode: {e:?}"))?;
529    drop(guard);
530    let n = frames.len();
531    for body in frames {
532        writer(body).map_err(|e| format!("write: {e}"))?;
533    }
534    println!("sent {n} frame{}", if n == 1 { "" } else { "s" });
535    Ok(Outcome::Continue)
536}

Trait Implementations§

Source§

impl Clone for Command

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Command

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl PartialEq for Command

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for Command

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.