#[non_exhaustive]pub struct TdmUnitConfig { /* private fields */ }Expand description
I2S receiver/transmitter unit configuration (TDM mode).
Implementations§
Source§impl TdmUnitConfig
impl TdmUnitConfig
Sourcepub fn with_sample_rate(self, sample_rate: Rate) -> Self
pub fn with_sample_rate(self, sample_rate: Rate) -> Self
Assign the given value to the sample_rate field.
Sourcepub fn sample_rate(&self) -> Rate
pub fn sample_rate(&self) -> Rate
The target sample rate
Sourcepub fn with_channels(self, channels: Channels) -> Self
pub fn with_channels(self, channels: Channels) -> Self
Assign the given value to the channels field.
Sourcepub fn with_data_format(self, data_format: DataFormat) -> Self
pub fn with_data_format(self, data_format: DataFormat) -> Self
Assign the given value to the data_format field.
Sourcepub fn data_format(&self) -> DataFormat
pub fn data_format(&self) -> DataFormat
Format of the data
Sourcepub fn with_ws_width(self, ws_width: WsWidth) -> Self
pub fn with_ws_width(self, ws_width: WsWidth) -> Self
Assign the given value to the ws_width field.
Sourcepub fn with_ws_polarity(self, ws_polarity: Polarity) -> Self
pub fn with_ws_polarity(self, ws_polarity: Polarity) -> Self
Assign the given value to the ws_polarity field.
Sourcepub fn ws_polarity(&self) -> Polarity
pub fn ws_polarity(&self) -> Polarity
Polarity of WS signal
Sourcepub fn with_msb_shift(self, msb_shift: bool) -> Self
pub fn with_msb_shift(self, msb_shift: bool) -> Self
Assign the given value to the msb_shift field.
Sourcepub fn with_endianness(self, endianness: Endianness) -> Self
pub fn with_endianness(self, endianness: Endianness) -> Self
Assign the given value to the endianness field.
Sourcepub fn endianness(&self) -> Endianness
pub fn endianness(&self) -> Endianness
Byte order of the data
Sourcepub fn with_bit_order(self, bit_order: BitOrder) -> Self
pub fn with_bit_order(self, bit_order: BitOrder) -> Self
Assign the given value to the bit_order field.
Source§impl TdmUnitConfig
impl TdmUnitConfig
Sourcepub fn new_tdm_philips() -> Self
pub fn new_tdm_philips() -> Self
TDM Philips standard configuration with two 16-bit active channels
Sourcepub fn new_tdm_msb() -> Self
pub fn new_tdm_msb() -> Self
TDM MSB standard configuration with two 16-bit active channels
Sourcepub fn new_tdm_pcm_short() -> Self
pub fn new_tdm_pcm_short() -> Self
TDM PCM short frame standard configuration with two 16-bit active channels
Sourcepub fn new_tdm_pcm_long() -> Self
pub fn new_tdm_pcm_long() -> Self
TDM PCM long frame standard configuration with two 16-bit active channels
Trait Implementations§
Source§impl Clone for TdmUnitConfig
Available on crate feature unstable only.
impl Clone for TdmUnitConfig
unstable only.Source§fn clone(&self) -> TdmUnitConfig
fn clone(&self) -> TdmUnitConfig
1.0.0 (const: unstable)§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for TdmUnitConfig
unstable only.Source§impl Debug for TdmUnitConfig
Available on crate feature unstable only.
impl Debug for TdmUnitConfig
unstable only.Source§impl Default for TdmUnitConfig
Available on crate feature unstable only.
impl Default for TdmUnitConfig
unstable only.impl Eq for TdmUnitConfig
unstable only.Source§impl Hash for TdmUnitConfig
Available on crate feature unstable only.
impl Hash for TdmUnitConfig
unstable only.Source§impl PartialEq for TdmUnitConfig
Available on crate feature unstable only.
impl PartialEq for TdmUnitConfig
unstable only.impl StructuralPartialEq for TdmUnitConfig
unstable only.Auto Trait Implementations§
impl Freeze for TdmUnitConfig
impl RefUnwindSafe for TdmUnitConfig
impl Send for TdmUnitConfig
impl Sync for TdmUnitConfig
impl Unpin for TdmUnitConfig
impl UnsafeUnpin for TdmUnitConfig
impl UnwindSafe for TdmUnitConfig
Blanket Implementations§
§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
clone_to_uninit)