Struct esp_idf_hal::rmt::config::CarrierConfig
source · pub struct CarrierConfig {
pub frequency: Hertz,
pub carrier_level: PinState,
pub duty_percent: DutyPercent,
}
Expand description
Configuration for when enabling a carrier frequency.
Fields§
§frequency: Hertz
Frequency of the carrier in Hz.
carrier_level: PinState
Level of the RMT output, when the carrier is applied.
duty_percent: DutyPercent
Duty cycle of the carrier signal in percent (%).
Implementations§
source§impl CarrierConfig
impl CarrierConfig
pub fn new() -> Self
pub fn frequency(self, hz: Hertz) -> Self
pub fn carrier_level(self, state: PinState) -> Self
pub fn duty_percent(self, duty: DutyPercent) -> Self
Trait Implementations§
source§impl Clone for CarrierConfig
impl Clone for CarrierConfig
source§fn clone(&self) -> CarrierConfig
fn clone(&self) -> CarrierConfig
Returns a copy of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for CarrierConfig
impl Debug for CarrierConfig
source§impl Default for CarrierConfig
impl Default for CarrierConfig
source§impl PartialEq for CarrierConfig
impl PartialEq for CarrierConfig
source§fn eq(&self, other: &CarrierConfig) -> bool
fn eq(&self, other: &CarrierConfig) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Copy for CarrierConfig
impl Eq for CarrierConfig
impl StructuralPartialEq for CarrierConfig
Auto Trait Implementations§
impl Freeze for CarrierConfig
impl RefUnwindSafe for CarrierConfig
impl Send for CarrierConfig
impl Sync for CarrierConfig
impl Unpin for CarrierConfig
impl UnwindSafe for CarrierConfig
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
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)§impl<T> CloneToUninit for Twhere
T: Copy,
impl<T> CloneToUninit for Twhere
T: Copy,
§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)