pub struct GlobalConfig {
pub din_enabled: bool,
pub din_to_usb_thru: bool,
pub usb_to_din_thru: bool,
pub usb_to_usb_thru: bool,
pub midi_clock: bool,
pub bpm: u16,
pub exp1_min: u16,
pub exp1_max: u16,
pub exp2_min: u16,
pub exp2_max: u16,
}Expand description
System-wide configuration, independent of presets. Replaces OpenDeck global settings.
Fields§
§din_enabled: boolEnable DIN MIDI output for locally-generated messages.
din_to_usb_thru: boolRoute incoming DIN MIDI → USB MIDI out.
usb_to_din_thru: boolRoute incoming USB MIDI → DIN MIDI out.
usb_to_usb_thru: boolRoute incoming USB MIDI → USB MIDI out (echo).
midi_clock: boolEnable MIDI Clock (0xF8) output.
bpm: u16MIDI Clock tempo in BPM (30–300).
exp1_min: u16Expression pedal 1 ADC value at heel (rest) position.
exp1_max: u16Expression pedal 1 ADC value at toe (full) position.
exp2_min: u16Expression pedal 2 ADC value at heel (rest) position.
exp2_max: u16Expression pedal 2 ADC value at toe (full) position.
Implementations§
Source§impl GlobalConfig
impl GlobalConfig
Sourcepub fn tick_interval_us(&self) -> u32
pub fn tick_interval_us(&self) -> u32
MIDI Clock tick interval in microseconds (24 PPQ).
Trait Implementations§
Source§impl Clone for GlobalConfig
impl Clone for GlobalConfig
Source§fn clone(&self) -> GlobalConfig
fn clone(&self) -> GlobalConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for GlobalConfig
impl Debug for GlobalConfig
Source§impl Default for GlobalConfig
impl Default for GlobalConfig
Source§impl<'de> Deserialize<'de> for GlobalConfig
impl<'de> Deserialize<'de> for GlobalConfig
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 GlobalConfig
Source§impl PartialEq for GlobalConfig
impl PartialEq for GlobalConfig
Source§fn eq(&self, other: &GlobalConfig) -> bool
fn eq(&self, other: &GlobalConfig) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for GlobalConfig
impl Serialize for GlobalConfig
impl StructuralPartialEq for GlobalConfig
Auto Trait Implementations§
impl Freeze for GlobalConfig
impl RefUnwindSafe for GlobalConfig
impl Send for GlobalConfig
impl Sync for GlobalConfig
impl Unpin for GlobalConfig
impl UnsafeUnpin for GlobalConfig
impl UnwindSafe for GlobalConfig
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