Enum stm32wlxx_hal::subghz::SmpsDrv
source · #[repr(u8)]pub enum SmpsDrv {
Milli20 = 0,
Milli40 = 1,
Milli60 = 2,
Milli100 = 3,
}
Expand description
SMPS maximum drive capability.
Argument of set_smps_drv
.
Variants§
Implementations§
source§impl SmpsDrv
impl SmpsDrv
sourcepub const fn as_milliamps(&self) -> u8
pub const fn as_milliamps(&self) -> u8
Get the SMPS drive value as milliamps.
Example
use stm32wlxx_hal::subghz::SmpsDrv;
assert_eq!(SmpsDrv::Milli20.as_milliamps(), 20);
assert_eq!(SmpsDrv::Milli40.as_milliamps(), 40);
assert_eq!(SmpsDrv::Milli60.as_milliamps(), 60);
assert_eq!(SmpsDrv::Milli100.as_milliamps(), 100);
Trait Implementations§
source§impl Ord for SmpsDrv
impl Ord for SmpsDrv
source§impl PartialEq for SmpsDrv
impl PartialEq for SmpsDrv
source§impl PartialOrd for SmpsDrv
impl PartialOrd for SmpsDrv
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for SmpsDrv
impl Eq for SmpsDrv
impl StructuralEq for SmpsDrv
impl StructuralPartialEq for SmpsDrv
Auto Trait Implementations§
impl RefUnwindSafe for SmpsDrv
impl Send for SmpsDrv
impl Sync for SmpsDrv
impl Unpin for SmpsDrv
impl UnwindSafe for SmpsDrv
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