#[repr(u8)]pub enum CardDetect {
Disable = 0,
Enable = 1,
}
Expand description
Represents the set_cd
field of the Argument.
Variants§
Disable = 0
Disconnect the 50KOhm pull-up resistor on pin 1 (CD/DAT3) of the card.
Enable = 1
Connect the 50KOhm pull-up resistor on pin 1 (CD/DAT3) of the card.
Implementations§
Source§impl CardDetect
impl CardDetect
Sourcepub const fn new() -> Self
pub const fn new() -> Self
Creates a new CardDetect.
Sourcepub const fn from_raw_unchecked(val: u8) -> Self
pub const fn from_raw_unchecked(val: u8) -> Self
Sourcepub const fn from_raw(val: u8) -> Result<Self, Error>
pub const fn from_raw(val: u8) -> Result<Self, Error>
Attempts to convert a u8
into a CardDetect.
Sourcepub const fn into_raw(self) -> u8
pub const fn into_raw(self) -> u8
Converts a CardDetect into a u8
.
Source§impl CardDetect
impl CardDetect
Sourcepub const fn from_bool(val: bool) -> Self
pub const fn from_bool(val: bool) -> Self
Converts a bool
into a CardDetect.
Sourcepub const fn into_bool(self) -> bool
pub const fn into_bool(self) -> bool
Converts a CardDetect into a bool
.
Trait Implementations§
Source§impl Clone for CardDetect
impl Clone for CardDetect
Source§fn clone(&self) -> CardDetect
fn clone(&self) -> CardDetect
Returns a duplicate of the value. Read more
1.0.0 · 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 CardDetect
impl Debug for CardDetect
Source§impl Default for CardDetect
impl Default for CardDetect
Source§impl From<CardDetect> for bool
impl From<CardDetect> for bool
Source§fn from(val: CardDetect) -> Self
fn from(val: CardDetect) -> Self
Converts to this type from the input type.
Source§impl From<CardDetect> for u8
impl From<CardDetect> for u8
Source§fn from(val: CardDetect) -> Self
fn from(val: CardDetect) -> Self
Converts to this type from the input type.
Source§impl From<bool> for CardDetect
impl From<bool> for CardDetect
Source§impl PartialEq for CardDetect
impl PartialEq for CardDetect
Source§impl TryFrom<u8> for CardDetect
impl TryFrom<u8> for CardDetect
impl Copy for CardDetect
impl Eq for CardDetect
impl StructuralPartialEq for CardDetect
Auto Trait Implementations§
impl Freeze for CardDetect
impl RefUnwindSafe for CardDetect
impl Send for CardDetect
impl Sync for CardDetect
impl Unpin for CardDetect
impl UnwindSafe for CardDetect
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