[−][src]Struct lsm9ds1::accel::AccelSettings
Accelerometer settings. Use this struct to configure the sensor.
Fields
enable_x: bool
X-axis output enabled
enable_y: bool
Y-axis output enabled
enable_z: bool
Z-axis output enabled
sample_rate: ODR
Output data rate & power mode selection
scale: Scale
Full-scale selection
bandwidth_selection: BandwidthSelection
Bandwidth selection
bandwidth: Bandwidth
Anti-aliasing filter bandwidth selection
high_res_bandwidth: HighRes
High resolution mode
Methods
impl AccelSettings
[src]
pub fn ctrl_reg5_xl(&self) -> u8
[src]
Returns u8
to write to CTRL_REG5_XL (0x1F)
CTRL_REG5_XL: [DEC_1][DEC_0][Zen_XL][Yen_XL][Xen_XL][0][0][0]
- DEC[0:1] - Decimation of accel data on OUT REG and FIFO.
- 00: None
- 01: 2 samples
- 10: 4 samples
- 11: 8 samples
- Zen_XL - Z-axis output enabled
- Yen_XL - Y-axis output enabled
- Xen_XL - X-axis output enabled
pub fn ctrl_reg6_xl(&self) -> u8
[src]
Returns u8
to write to CTRL_REG6_XL (0x20)
CTRL_REG6_XL: [ODR_XL2][ODR_XL1][ODR_XL0][FS1_XL][FS0_XL][BW_SCAL_ODR][BW_XL1][BW_XL0]
- ODR_XL[2:0] - Output data rate & power mode selection
- FS_XL[1:0] - Full-scale selection
- BW_SCAL_ODR - Bandwidth selection
- BW_XL[1:0] - Anti-aliasing filter bandwidth selection
pub fn ctrl_reg7_xl(&self) -> u8
[src]
Returns u8
to write to CTRL_REG7_XL (0x21)
CTRL_REG7_XL: [HR][DCF1][DCF0][0][0][FDS][0][HPIS1]
- HR - High resolution mode (0: disable, 1: enable)
- DCF[1:0] - Digital filter cutoff frequency
- FDS - Filtered data selection
- HPIS1 - HPF enabled for interrupt function
Trait Implementations
impl Debug for AccelSettings
[src]
impl Default for AccelSettings
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,