pub struct Ms5611<SPI, NCS> { /* private fields */ }Expand description
MS5611 driver
Implementations§
Source§impl<SPI, NCS, E> Ms5611<SPI, NCS>
impl<SPI, NCS, E> Ms5611<SPI, NCS>
Sourcepub fn new(
spi: SPI,
ncs: NCS,
delay: &mut impl DelayMs<u8>,
) -> Result<Ms5611<SPI, NCS>, E>
pub fn new( spi: SPI, ncs: NCS, delay: &mut impl DelayMs<u8>, ) -> Result<Ms5611<SPI, NCS>, E>
Creates a new MS5611 driver from a SPI peripheral and a NCS pin
Sourcepub fn get_compensated_sample(
&mut self,
osr: Oversampling,
delay_source: &mut impl DelayMs<u8>,
) -> Result<Sample, E>
pub fn get_compensated_sample( &mut self, osr: Oversampling, delay_source: &mut impl DelayMs<u8>, ) -> Result<Sample, E>
Reads and returns Pressure and Thermometer measurement
Sourcepub fn get_second_order_sample(
&mut self,
osr: Oversampling,
delay_source: &mut impl DelayMs<u8>,
) -> Result<Sample, E>
pub fn get_second_order_sample( &mut self, osr: Oversampling, delay_source: &mut impl DelayMs<u8>, ) -> Result<Sample, E>
Reads and returns a second order compensated Pressure and Thermometer measurement as defined in datasheet.
Auto Trait Implementations§
impl<SPI, NCS> Freeze for Ms5611<SPI, NCS>
impl<SPI, NCS> RefUnwindSafe for Ms5611<SPI, NCS>where
SPI: RefUnwindSafe,
NCS: RefUnwindSafe,
impl<SPI, NCS> Send for Ms5611<SPI, NCS>
impl<SPI, NCS> Sync for Ms5611<SPI, NCS>
impl<SPI, NCS> Unpin for Ms5611<SPI, NCS>
impl<SPI, NCS> UnwindSafe for Ms5611<SPI, NCS>where
SPI: UnwindSafe,
NCS: UnwindSafe,
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