39 #ifndef DRV_CCS811_H__ 40 #define DRV_CCS811_H__ 42 #include "nrf_drv_twi.h" 286 #endif // DRV_CCS811_H__ uint32_t drv_ccs811_meas_mode_modify(uint8_t set_mask, uint8_t clr_mask)
Function for modifying the measurement mode register of the CCS811 device.
uint32_t drv_ccs811_meas_mode_get(uint8_t *p_meas_mode)
Function for getting the measurement mode of the CCS811 device.
uint32_t drv_ccs811_hw_version_get(uint8_t *p_hw_version)
Function for getting the hardware version of the CCS811 device.
uint16_t tvoc_ppb
The Total Volatile Organic Compound (TVOC) value in parts per billion (ppb).
Definition: drv_ccs811.h:90
void drv_ccs811_init(void)
Function for initializing the CCS811 driver.
uint32_t drv_ccs811_ntc_get(uint16_t *p_r_ref_mv, uint16_t *p_r_ntc_mv)
Function for getting the NTC data of the CCS811 device.
The algorithm result data of the CCS811 device.
Definition: drv_ccs811.h:87
uint32_t drv_ccs811_thresholds_get(uint16_t *p_low_to_medium, uint16_t *p_medium_to_high, uint8_t *p_hysteresis)
Function for the thresholds of the CCS811 device.
uint16_t ec02_ppm
The equivalent CO2 (eCO2) value in parts per million (ppm).
Definition: drv_ccs811.h:89
Both eCO2 and TVOC values, but no additional information.
Definition: drv_ccs811.h:80
uint32_t drv_ccs811_hw_id_get(uint8_t *p_hw_id)
Function for getting the hardware identity of the CCS811 device.
nrf_drv_twi_config_t const * p_twi_cfg
The TWI configuration to use while the driver is enabled.
Definition: drv_ccs811.h:71
uint8_t twi_addr
TWI address of the CCS811.
Definition: drv_ccs811.h:69
uint32_t drv_ccs811_app_start(void)
Function for starting the application of the CCS811 device.
uint32_t drv_ccs811_open(drv_ccs811_cfg_t const *const p_drv_ccs811_cfg)
Function for opening the CCS811 driver according to the specified configuration.
uint32_t drv_ccs811_baseline_set(uint16_t baseline)
Function for writing the baseline value to the CCS811 device.
Only the equivalent CO2 (eCO2) value.
Definition: drv_ccs811.h:78
Not supported.
Definition: drv_ccs811.h:62
uint32_t drv_ccs811_sw_reset(void)
Function for starting the application of the CCS811 device.
uint32_t drv_ccs811_baseline_get(uint16_t *p_baseline)
Function for getting the baseline value from the CCS811 device.
uint8_t status
The status according to the CCS811 status format (drv_ccs811_status_get).
Definition: drv_ccs811.h:91
drv_ccs811_alg_result_descr_t
Descriptor of the CCS811 result data format.
Definition: drv_ccs811.h:76
uint32_t drv_ccs811_fw_boot_version_get(uint16_t *p_fw_boot_version)
Function for getting the version of the firmware bootloader of the CCS811 device. ...
CCS811 configuration.
Definition: drv_ccs811.h:67
Both eCO2 and TVOC values + status.
Definition: drv_ccs811.h:81
uint32_t drv_ccs811_raw_data_get(uint16_t *p_raw_data)
Function for getting the raw data of the CCS811 device.
uint32_t drv_ccs811_fw_app_version_get(uint16_t *p_fw_app_version)
Function for getting the version of the firmware application of the CCS811 device.
Invalid parameters.
Definition: drv_ccs811.h:61
uint32_t drv_ccs811_err_id_get(uint8_t *p_err_id)
Function for getting the error identifier of the CCS811 device.
Disallowed.
Definition: drv_ccs811.h:60
uint32_t drv_ccs811_env_data_set(uint16_t rh_ppth, int32_t temp_mdeg)
Function for setting the environmental data of the CCS811 device.
uint8_t err_id
The err_id according to the CCS811 err_id format (drv_ccs811_err_id_get).
Definition: drv_ccs811.h:92
uint32_t drv_ccs811_thresholds_set(uint16_t low_to_medium, uint16_t medium_to_highm, uint8_t hysteresis)
Function for setting the thresholds of the CCS811 device.
All available result data (eCO2 and TVOC, status, error ID, and raw data).
Definition: drv_ccs811.h:82
Only the Total Volatile Organic Compound (TVOC) value.
Definition: drv_ccs811.h:79
uint16_t raw_data
The raw_data according to the CCS811 raw_data format (drv_ccs811_raw_data_get)
Definition: drv_ccs811.h:93
nrf_drv_twi_t const * p_twi_instance
The instance of TWI master to be used for transactions.
Definition: drv_ccs811.h:70
uint32_t drv_ccs811_close(void)
Function for closing the CCS811 driver.
uint32_t drv_ccs811_status_get(uint8_t *p_status)
Function for getting the status of the CCS811 device.
uint32_t drv_ccs811_alg_result_data_get(drv_ccs811_alg_result_descr_t alg_result_descr, drv_ccs811_alg_result_t *p_alg_result_data)
Function for getting the calculation result data of the CCS811 device.
Successful.
Definition: drv_ccs811.h:59