pub struct Switches1(pub u8);
Tuple Fields§
§0: u8
Implementations§
source§impl Switches1
impl Switches1
sourcepub fn powerrole(&self) -> PowerRole
pub fn powerrole(&self) -> PowerRole
Bit used for constructing the GoodCRC acknowledge packet. This bit corresponds to the Port Power Role bit in the message header if an SOP packet is received.
sourcepub fn with_powerrole(self, value: PowerRole) -> Self
pub fn with_powerrole(self, value: PowerRole) -> Self
Bit used for constructing the GoodCRC acknowledge packet. This bit corresponds to the Port Power Role bit in the message header if an SOP packet is received.
sourcepub fn set_powerrole(&mut self, value: PowerRole)
pub fn set_powerrole(&mut self, value: PowerRole)
Bit used for constructing the GoodCRC acknowledge packet. This bit corresponds to the Port Power Role bit in the message header if an SOP packet is received.
sourcepub fn specrev(&self) -> Revision
pub fn specrev(&self) -> Revision
Bit used for constructing the GoodCRC acknowledge packet. These bits correspond to the Specification Revision bits in the message header.
sourcepub fn with_specrev(self, value: Revision) -> Self
pub fn with_specrev(self, value: Revision) -> Self
Bit used for constructing the GoodCRC acknowledge packet. These bits correspond to the Specification Revision bits in the message header.
sourcepub fn set_specrev(&mut self, value: Revision)
pub fn set_specrev(&mut self, value: Revision)
Bit used for constructing the GoodCRC acknowledge packet. These bits correspond to the Specification Revision bits in the message header.
sourcepub fn datarole(&self) -> DataRole
pub fn datarole(&self) -> DataRole
Bit used for constructing the GoodCRC acknowledge packet. This bit corresponds to the Port Data Role bit in the message header.
sourcepub fn with_datarole(self, value: DataRole) -> Self
pub fn with_datarole(self, value: DataRole) -> Self
Bit used for constructing the GoodCRC acknowledge packet. This bit corresponds to the Port Data Role bit in the message header.
sourcepub fn set_datarole(&mut self, value: DataRole)
pub fn set_datarole(&mut self, value: DataRole)
Bit used for constructing the GoodCRC acknowledge packet. This bit corresponds to the Port Data Role bit in the message header.
sourcepub fn auto_src(&self) -> bool
pub fn auto_src(&self) -> bool
Starts the transmitter automatically when a message with a good CRC is received and automatically sends a GoodCRC acknowledge packet back to the relevant SOP*
sourcepub fn with_auto_src(self, value: bool) -> Self
pub fn with_auto_src(self, value: bool) -> Self
Starts the transmitter automatically when a message with a good CRC is received and automatically sends a GoodCRC acknowledge packet back to the relevant SOP*
sourcepub fn set_auto_src(&mut self, value: bool)
pub fn set_auto_src(&mut self, value: bool)
Starts the transmitter automatically when a message with a good CRC is received and automatically sends a GoodCRC acknowledge packet back to the relevant SOP*
sourcepub fn with_txcc2(self, value: bool) -> Self
pub fn with_txcc2(self, value: bool) -> Self
Enable BMC transmit driver on CC2 pin
sourcepub fn with_txcc1(self, value: bool) -> Self
pub fn with_txcc1(self, value: bool) -> Self
Enable BMC transmit driver on CC1 pin
Trait Implementations§
impl Copy for Switches1
impl Eq for Switches1
impl StructuralPartialEq for Switches1
Auto Trait Implementations§
impl Freeze for Switches1
impl RefUnwindSafe for Switches1
impl Send for Switches1
impl Sync for Switches1
impl Unpin for Switches1
impl UnwindSafe for Switches1
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)source§impl<T, U> UnsafeFrom<U> for Twhere
U: Into<T>,
impl<T, U> UnsafeFrom<U> for Twhere
U: Into<T>,
source§unsafe fn unsafe_from(other: U) -> T
unsafe fn unsafe_from(other: U) -> T
Calls U::into(other)
.
That is, this conversion is whatever the implementation of Into
<T> for U
chooses to
do.
source§impl<T, U> UnsafeInto<U> for Twhere
U: UnsafeFrom<T>,
impl<T, U> UnsafeInto<U> for Twhere
U: UnsafeFrom<T>,
source§unsafe fn unsafe_into(self) -> U
unsafe fn unsafe_into(self) -> U
Calls U::unsafe_from(self)
.
That is, this conversion is whatever the implementation of UnsafeFrom
<T> for U
chooses to do.