pub struct DecodeSection {
pub kind: String,
pub name: Option<String>,
pub rx: Option<String>,
pub sda: Option<String>,
pub scl: Option<String>,
pub sck: Option<String>,
pub mosi: Option<String>,
pub miso: Option<String>,
pub cs: Option<String>,
pub baud: Option<u32>,
pub mode: Option<u8>,
}Expand description
One [[decode]]: a protocol read off channels the project already probes.
The fields a kind does not use are left out; uart names rx, i2c names
sda and scl, spi names sck, mosi and cs (and optionally miso).
The command line spells the same thing as --decode uart:rx=tx,baud=9600.
Fields§
§kind: Stringuart, i2c or spi.
name: Option<String>The label a report uses. Defaults to the kind and its first channel.
rx: Option<String>§sda: Option<String>§scl: Option<String>§sck: Option<String>§mosi: Option<String>§miso: Option<String>§cs: Option<String>§baud: Option<u32>UART bit rate. Absent means the shortest run on the channel is one bit.
mode: Option<u8>SPI mode, 0 through 3: CPOL and CPHA. Defaults to 0.
Implementations§
Trait Implementations§
Source§impl Clone for DecodeSection
impl Clone for DecodeSection
Source§fn clone(&self) -> DecodeSection
fn clone(&self) -> DecodeSection
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 DecodeSection
impl Debug for DecodeSection
Source§impl Default for DecodeSection
impl Default for DecodeSection
Source§fn default() -> DecodeSection
fn default() -> DecodeSection
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for DecodeSection
impl<'de> Deserialize<'de> for DecodeSection
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<DecodeSection, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<DecodeSection, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Forget for DecodeSection
impl Freeze for DecodeSection
impl Move for DecodeSection
impl RefUnwindSafe for DecodeSection
impl Send for DecodeSection
impl Sync for DecodeSection
impl Unpin for DecodeSection
impl UnsafeUnpin for DecodeSection
impl UnwindSafe for DecodeSection
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more