|
BMP581 Driver 0.1.0
API reference
|
Everything EnsureInitialized() and ApplyConfig() write to the chip.
More...
#include <bmp581_types.hpp>
Public Attributes | |
| PowerMode | mode {PowerMode::Standby} |
| Standby, Normal or Continuous. | |
| Oversampling | pressure_oversampling {Oversampling::X1} |
| OSR_CONFIG.osr_p. | |
| Oversampling | temperature_oversampling {Oversampling::X1} |
| OSR_CONFIG.osr_t. | |
| OutputDataRate | odr {OutputDataRate::Hz1} |
| ODR_CONFIG.odr (normal mode). | |
| bool | deep_standby {true} |
| ODR_CONFIG.deep_dis = 0: deep standby where its conditions hold. | |
| IirFilter | pressure_iir {IirFilter::Bypass} |
| DSP_IIR.set_iir_p. | |
| IirFilter | temperature_iir {IirFilter::Bypass} |
| DSP_IIR.set_iir_t. | |
| bool | iir_to_data_registers {false} |
| DSP_CONFIG.shdw_sel_iir_t and _p: filtered data. | |
| bool | iir_to_fifo {false} |
| DSP_CONFIG.fifo_sel_iir_t and _p: filtered FIFO frames. | |
| bool | iir_to_out_of_range {false} |
| DSP_CONFIG.oor_sel_iir_p: filtered OOR check. | |
| bool | iir_flush_in_forced {false} |
| DSP_CONFIG.iir_flush_forced_en. | |
| FifoFrame | fifo_frame {FifoFrame::Disabled} |
| FIFO_SEL.fifo_frame_sel. | |
| FifoMode | fifo_mode {FifoMode::Streaming} |
| FIFO_CONFIG.fifo_mode. | |
| uint8_t | fifo_threshold {0} |
| FIFO_CONFIG.fifo_threshold: 0 off, 1 to 31 (15 for PT frames). | |
| uint8_t | fifo_decimation {0} |
| FIFO_SEL.fifo_dec_sel: keep every 2^n-th frame, 0 to 7. | |
| bool | int_pin_enable {false} |
| INT_CONFIG.int_en. | |
| IntMode | int_mode {IntMode::Latched} |
| INT_CONFIG.int_mode. | |
| IntPolarity | int_polarity {IntPolarity::ActiveLow} |
| INT_CONFIG.int_pol. | |
| IntDrive | int_drive {IntDrive::OpenDrain} |
| INT_CONFIG.int_od. | |
| uint8_t | int_pad_drive {3} |
| INT_CONFIG.pad_int_drv, 0 to 15; set bit 3 only with open drain. | |
| bool | source_data_ready {false} |
INT_SOURCE.drdy_data_reg_en; WaitDataReady() needs it. | |
| bool | source_fifo_full {false} |
| INT_SOURCE.fifo_full_en. | |
| bool | source_fifo_threshold {false} |
| INT_SOURCE.fifo_ths_en. | |
| bool | source_out_of_range {false} |
| INT_SOURCE.oor_p_en. | |
| uint32_t | oor_reference_pa {0} |
OOR_THR_P and OOR_CONFIG bit 0: 0 to kOorReferenceMaxPa. | |
| uint8_t | oor_window_pa {0} |
| OOR_RANGE: +/- this many pascals around the reference. | |
| OorCount | oor_count {OorCount::Samples1} |
| OOR_CONFIG.cnt_lim. | |
| uint32_t | startup_timeout_ms {10} |
| uint32_t | data_ready_timeout_ms {2000} |
Friends | |
| constexpr bool | operator== (const Config &lhs, const Config &rhs) noexcept=default |
| Exact comparison: every member is integral or an enumeration (KB-CPP20-033). | |
Everything EnsureInitialized() and ApplyConfig() write to the chip.
The defaults are the reset values of the datasheet (section 7), so Config{} changes nothing on a freshly reset chip except that pressure is measured. Fields with a unit carry it as a suffix. Integral and enumeration members only: two configurations compare with ==.
| uint32_t bmp581::Config::data_ready_timeout_ms {2000} |
Driver side: longest WaitDataReady(), 1 to kTimeoutMaxMs; cover one data rate period.
| uint32_t bmp581::Config::startup_timeout_ms {10} |
Driver side: longest wait for STATUS.status_nvm_rdy at start-up, 1 to kTimeoutMaxMs.