diff --git a/lib/vendor/Bosch/BSEC/API/LICENSE b/lib/vendor/Bosch/BSEC/API/LICENSE deleted file mode 100644 index ab7a8c8b24296b6528a060a50c4d13ad659a2bb3..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/API/LICENSE +++ /dev/null @@ -1,39 +0,0 @@ -Copyright (C) 2017 - 2018 Bosch Sensortec GmbH - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - -Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. - -Redistributions in binary form must reproduce the above copyright -notice, this list of conditions and the following disclaimer in the -documentation and/or other materials provided with the distribution. - -Neither the name of the copyright holder nor the names of the -contributors may be used to endorse or promote products derived from -this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -CONTRIBUTORS "AS IS" AND ANY EXPRESS OR -IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL COPYRIGHT HOLDER -OR CONTRIBUTORS BE LIABLE FOR ANY -DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, -OR CONSEQUENTIAL DAMAGES(INCLUDING, BUT NOT LIMITED TO, -PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN -ANY WAY OUT OF THE USE OF THIS -SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE - -The information provided is believed to be accurate and reliable. -The copyright holder assumes no responsibility -for the consequences of use -of such information nor for any infringement of patents or -other rights of third parties which may result from its use. -No license is granted by implication or otherwise under any patent or -patent rights of the copyright holder. \ No newline at end of file diff --git a/lib/vendor/Bosch/BSEC/API/README.md b/lib/vendor/Bosch/BSEC/API/README.md deleted file mode 100644 index 7f3f2506268b14716085921788eac54f2c9ca5d5..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/API/README.md +++ /dev/null @@ -1,282 +0,0 @@ -# BME680 sensor API - -## Introduction - -This package contains the Bosch Sensortec's BME680 gas sensor API - -The sensor driver package includes bme680.h, bme680.c and bme680_defs.h files - -## Version - -File | Version | Date ---------------|---------|------------- -bme680.c | 3.5.9 | 19 Jun 2018 -bme680.h | 3.5.9 | 19 Jun 2018 -bme680_defs.h | 3.5.9 | 19 Jun 2018 - -## Integration details - -* Integrate bme680.h, bme680_defs.h and bme680.c file in to your project. -* Include the bme680.h file in your code like below. - -``` c -#include "bme680.h" -``` - -## File information - -* bme680_defs.h : This header file has the constants, macros and datatype declarations. -* bme680.h : This header file contains the declarations of the sensor driver APIs. -* bme680.c : This source file contains the definitions of the sensor driver APIs. - -## Supported sensor interfaces - -* SPI 4-wire -* I2C - -## Usage guide - -### Initializing the sensor - -To initialize the sensor, you will first need to create a device structure. You -can do this by creating an instance of the structure bme680_dev. Then go on to -fill in the various parameters as shown below - -#### Example for SPI 4-Wire - -``` c - struct bme680_dev gas_sensor; - - /* You may assign a chip select identifier to be handled later */ - gas_sensor.dev_id = 0; - gas_sensor.intf = BME680_SPI_INTF; - gas_sensor.read = user_spi_read; - gas_sensor.write = user_spi_write; - gas_sensor.delay_ms = user_delay_ms; - /* amb_temp can be set to 25 prior to configuring the gas sensor - * or by performing a few temperature readings without operating the gas sensor. - */ - gas_sensor.amb_temp = 25; - - int8_t rslt = BME680_OK; - rslt = bme680_init(&gas_sensor); -``` - -#### Example for I2C - -``` c - struct bme680_dev gas_sensor; - - gas_sensor.dev_id = BME680_I2C_ADDR_PRIMARY; - gas_sensor.intf = BME680_I2C_INTF; - gas_sensor.read = user_i2c_read; - gas_sensor.write = user_i2c_write; - gas_sensor.delay_ms = user_delay_ms; - /* amb_temp can be set to 25 prior to configuring the gas sensor - * or by performing a few temperature readings without operating the gas sensor. - */ - gas_sensor.amb_temp = 25; - - - int8_t rslt = BME680_OK; - rslt = bme680_init(&gas_sensor); -``` - -Regarding compensation functions for temperature, pressure, humidity and gas we have two implementations. - - - Integer version - - floating point version - -By default, Integer version is used in the API - -If the user needs the floating point version, the user has to un-comment BME680_FLOAT_POINT_COMPENSATION macro -in bme680_defs.h file or to add it in the compiler flags. - -### Configuring the sensor - -#### Example for configuring the sensor in forced mode - -``` c - uint8_t set_required_settings; - - /* Set the temperature, pressure and humidity settings */ - gas_sensor.tph_sett.os_hum = BME680_OS_2X; - gas_sensor.tph_sett.os_pres = BME680_OS_4X; - gas_sensor.tph_sett.os_temp = BME680_OS_8X; - gas_sensor.tph_sett.filter = BME680_FILTER_SIZE_3; - - /* Set the remaining gas sensor settings and link the heating profile */ - gas_sensor.gas_sett.run_gas = BME680_ENABLE_GAS_MEAS; - /* Create a ramp heat waveform in 3 steps */ - gas_sensor.gas_sett.heatr_temp = 320; /* degree Celsius */ - gas_sensor.gas_sett.heatr_dur = 150; /* milliseconds */ - - /* Select the power mode */ - /* Must be set before writing the sensor configuration */ - gas_sensor.power_mode = BME680_FORCED_MODE; - - /* Set the required sensor settings needed */ - set_required_settings = BME680_OST_SEL | BME680_OSP_SEL | BME680_OSH_SEL | BME680_FILTER_SEL - | BME680_GAS_SENSOR_SEL; - - /* Set the desired sensor configuration */ - rslt = bme680_set_sensor_settings(set_required_settings,&gas_sensor); - - /* Set the power mode */ - rslt = bme680_set_sensor_mode(&gas_sensor); - - -``` - -### Reading sensor data - -#### Example for reading all sensor data - -``` c - /* Get the total measurement duration so as to sleep or wait till the - * measurement is complete */ - uint16_t meas_period; - bme680_get_profile_dur(&meas_period, &gas_sensor); - - struct bme680_field_data data; - - while(1) - { - user_delay_ms(meas_period); /* Delay till the measurement is ready */ - - rslt = bme680_get_sensor_data(&data, &gas_sensor); - - printf("T: %.2f degC, P: %.2f hPa, H %.2f %%rH ", data.temperature / 100.0f, - data.pressure / 100.0f, data.humidity / 1000.0f ); - /* Avoid using measurements from an unstable heating setup */ - if(data.status & BME680_GASM_VALID_MSK) - printf(", G: %d ohms", data.gas_resistance); - - printf("\r\n"); - - /* Trigger the next measurement if you would like to read data out continuously */ - if (gas_sensor.power_mode == BME680_FORCED_MODE) { - rslt = bme680_set_sensor_mode(&gas_sensor); - } - } -``` - -### Templates for function pointers - -``` c - -void user_delay_ms(uint32_t period) -{ - /* - * Return control or wait, - * for a period amount of milliseconds - */ -} - -int8_t user_spi_read(uint8_t dev_id, uint8_t reg_addr, uint8_t *reg_data, uint16_t len) -{ - int8_t rslt = 0; /* Return 0 for Success, non-zero for failure */ - - /* - * The parameter dev_id can be used as a variable to select which Chip Select pin has - * to be set low to activate the relevant device on the SPI bus - */ - - /* - * Data on the bus should be like - * |----------------+---------------------+-------------| - * | MOSI | MISO | Chip Select | - * |----------------+---------------------|-------------| - * | (don't care) | (don't care) | HIGH | - * | (reg_addr) | (don't care) | LOW | - * | (don't care) | (reg_data[0]) | LOW | - * | (....) | (....) | LOW | - * | (don't care) | (reg_data[len - 1]) | LOW | - * | (don't care) | (don't care) | HIGH | - * |----------------+---------------------|-------------| - */ - - return rslt; -} - -int8_t user_spi_write(uint8_t dev_id, uint8_t reg_addr, uint8_t *reg_data, uint16_t len) -{ - int8_t rslt = 0; /* Return 0 for Success, non-zero for failure */ - - /* - * The parameter dev_id can be used as a variable to select which Chip Select pin has - * to be set low to activate the relevant device on the SPI bus - */ - - /* - * Data on the bus should be like - * |---------------------+--------------+-------------| - * | MOSI | MISO | Chip Select | - * |---------------------+--------------|-------------| - * | (don't care) | (don't care) | HIGH | - * | (reg_addr) | (don't care) | LOW | - * | (reg_data[0]) | (don't care) | LOW | - * | (....) | (....) | LOW | - * | (reg_data[len - 1]) | (don't care) | LOW | - * | (don't care) | (don't care) | HIGH | - * |---------------------+--------------|-------------| - */ - - return rslt; -} - -int8_t user_i2c_read(uint8_t dev_id, uint8_t reg_addr, uint8_t *reg_data, uint16_t len) -{ - int8_t rslt = 0; /* Return 0 for Success, non-zero for failure */ - - /* - * The parameter dev_id can be used as a variable to store the I2C address of the device - */ - - /* - * Data on the bus should be like - * |------------+---------------------| - * | I2C action | Data | - * |------------+---------------------| - * | Start | - | - * | Write | (reg_addr) | - * | Stop | - | - * | Start | - | - * | Read | (reg_data[0]) | - * | Read | (....) | - * | Read | (reg_data[len - 1]) | - * | Stop | - | - * |------------+---------------------| - */ - - return rslt; -} - -int8_t user_i2c_write(uint8_t dev_id, uint8_t reg_addr, uint8_t *reg_data, uint16_t len) -{ - int8_t rslt = 0; /* Return 0 for Success, non-zero for failure */ - - /* - * The parameter dev_id can be used as a variable to store the I2C address of the device - */ - - /* - * Data on the bus should be like - * |------------+---------------------| - * | I2C action | Data | - * |------------+---------------------| - * | Start | - | - * | Write | (reg_addr) | - * | Write | (reg_data[0]) | - * | Write | (....) | - * | Write | (reg_data[len - 1]) | - * | Stop | - | - * |------------+---------------------| - */ - - return rslt; -} - -``` - -## Copyright (C) 2017 - 2018 Bosch Sensortec GmbH \ No newline at end of file diff --git a/lib/vendor/Bosch/BSEC/API/changelog.md b/lib/vendor/Bosch/BSEC/API/changelog.md deleted file mode 100644 index af3cce9a32310bcdd60b8c3edc2a6be5ba28d7cf..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/API/changelog.md +++ /dev/null @@ -1,51 +0,0 @@ -# Change Log -All notable changes to the BME680 Sensor API will be documented in this file. -## v3.5.3, 30 Oct 2017 -### Changed - - Changed the compensation equation formulae to use shifting operation - - Updated the "bme680_get_profile_dur" API - - Fixed Checkpatch and made linux compatible - -## v3.5.2, 18 Oct 2017 -### Changed - - Fixed bug of temperature compensation in pressure - -## v3.5.1, 5 Jul 2017 -### Changed - - Fixed bug with overwriting of the result with communication results - - Added member in the dev structure to store communication results - - Updated set profile duration API to not return a result. - - Added new API to get the duration for the existing profile - - Fixed bug with setting gas configuration. Reduced to writing only relevant bytes - - Updated readme - - Updated documentation for the type definitions - - Removed mode check for get sensor data and setting and getting profile dur - - -## v3.5.0, 28 Jun 2017 -### Changed -- Fixed bug with getting and setting mem pages -- Changed initialization sequence to be more robust -- Added additional tries while reading data in case of inadequate delay - - -## v3.4.0, 8 Jun 2017 -### Changed -- Modified the bme680_get_sensor_data API. User has to now pass the struct that stores the data rather than retrieving from the bme680_dev structure. -- Fixed possible bugs - -## v3.3.0, 24 May 2017 -### Changed -- Name changes in the BME680 device structure. -- Removed sequential and parallel modes. -- Removed ODR related sensor settings -- Modified get sensor settings API with user selection. -- Removed sort sensor data and swap fields API which are not required. - -### Added -- BME680 set profile duration API. - -## v3.2.1, 17 May 2017 -### Added -- Took the reference as base version 3.2.1 of BME680 sensor and added. - diff --git a/lib/vendor/Bosch/BSEC/Arduino/BSEC.zip b/lib/vendor/Bosch/BSEC/Arduino/BSEC.zip deleted file mode 100644 index 95c33a20240612e31eb86543666afa81788c47a7..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/Arduino/BSEC.zip and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/Arduino/Bme680_Data.zip b/lib/vendor/Bosch/BSEC/Arduino/Bme680_Data.zip deleted file mode 100644 index 719ad57960167a8240a7ff1edaa68a77b1412997..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/Arduino/Bme680_Data.zip and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/Arduino/Integration Guidelines for Arduino platforms.pdf b/lib/vendor/Bosch/BSEC/Arduino/Integration Guidelines for Arduino platforms.pdf deleted file mode 100644 index 011a12db07cb9d5fadf2a73e90af5f8ca7483765..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/Arduino/Integration Guidelines for Arduino platforms.pdf and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/BSEC Binary Size Information.pdf b/lib/vendor/Bosch/BSEC/BSEC Binary Size Information.pdf index 0361ff5036b430527cd533b2d16c3cd6e6ce8496..60b394af496c3c5c2a67edd3b3dc358c8316a29d 100644 Binary files a/lib/vendor/Bosch/BSEC/BSEC Binary Size Information.pdf and b/lib/vendor/Bosch/BSEC/BSEC Binary Size Information.pdf differ diff --git a/lib/vendor/Bosch/BSEC/BSEC_release_note.pdf b/lib/vendor/Bosch/BSEC/BSEC_release_note.pdf deleted file mode 100644 index e7242e68ba15f37da7be3b3b230cf45aa642cf0d..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/BSEC_release_note.pdf and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/Release Note_BSEC1480_07_08_2020.pdf b/lib/vendor/Bosch/BSEC/Release Note_BSEC1480_07_08_2020.pdf new file mode 100644 index 0000000000000000000000000000000000000000..6a36515812d026b09bf4ed828d7bd1cd62bb429f Binary files /dev/null and b/lib/vendor/Bosch/BSEC/Release Note_BSEC1480_07_08_2020.pdf differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M3/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0+/bsec_datatypes.h similarity index 92% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M3/bsec_datatypes.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0+/bsec_datatypes.h index f28550692865e144897c49ef5eed4c36daa07269..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M3/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0+/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -389,9 +390,9 @@ typedef struct * * | Name | Value | Accuracy description | * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | * | HIGH_ACCURACY | 3 | High accuracy | * * For example: @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0+/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0+/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0+/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0+/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..d7003632e9f4e18bde84b510aa821d799b580f93 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a.Size.log similarity index 50% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a.Size.log rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a.Size.log index 9560c9a9b7f9213a68969fc31fe9f8a6967344d6..703e4401947ba596964bae049b40da22174cfa40 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 34260 0 1088 35348 8a14 (TOTALS) + 12944 0 1216 14160 3750 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0+/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0/bsec_datatypes.h similarity index 92% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0+/bsec_datatypes.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0/bsec_datatypes.h index f28550692865e144897c49ef5eed4c36daa07269..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0+/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -389,9 +390,9 @@ typedef struct * * | Name | Value | Accuracy description | * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | * | HIGH_ACCURACY | 3 | High accuracy | * * For example: @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..a9b39c72dec6a11af62f009730701ee0b235c3ec Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a.Size.log similarity index 50% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a.Size.log rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a.Size.log index eb794d03ff1d59ea65e17072382c5ed204ca4708..703e4401947ba596964bae049b40da22174cfa40 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 63036 0 1120 64156 fa9c (TOTALS) + 12944 0 1216 14160 3750 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M3/bsec_datatypes.h similarity index 92% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0/bsec_datatypes.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M3/bsec_datatypes.h index f28550692865e144897c49ef5eed4c36daa07269..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M3/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -389,9 +390,9 @@ typedef struct * * | Name | Value | Accuracy description | * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | * | HIGH_ACCURACY | 3 | High accuracy | * * For example: @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M3/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M3/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M3/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M3/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..15924658a84905f5b523b505e931286a9c82a18f Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp32/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a.Size.log similarity index 50% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp32/libalgobsec.a.Size.log rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a.Size.log index 8176349a021a03483b6631b827ebe0be668a3184..bfc795320b5aa8353b85d8900c9a1c8b22aa857f 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp32/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 14046 0 1088 15134 3b1e (TOTALS) + 12536 0 1216 13752 35b8 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4/bsec_datatypes.h similarity index 92% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4/bsec_datatypes.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4/bsec_datatypes.h index f28550692865e144897c49ef5eed4c36daa07269..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -389,9 +390,9 @@ typedef struct * * | Name | Value | Accuracy description | * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | * | HIGH_ACCURACY | 3 | High accuracy | * * For example: @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..d68245982b94feae54c2ae3a32554f01cd75658d Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp8266/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a.Size.log similarity index 50% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp8266/libalgobsec.a.Size.log rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a.Size.log index fda797707930a9dbbe206c4f31aff0ae181d4cf7..c716fe572f2f61ee00e61a869d7f677ba6ef32ef 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp8266/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 17111 0 1088 18199 4717 (TOTALS) + 12552 0 1216 13768 35c8 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4F/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4F/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4F/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4F/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4F/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4F/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..51d77437542bec8465881f95ea8aed5233550cab Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..73b21d3cb5517ccc7f78d44bf864f59ecf9398e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 13062 0 1216 14278 37c6 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M7/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M7/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M7/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M7/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M7/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M7/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..403ea112258e8268a5cecf22eab728f06163e6f4 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..c716fe572f2f61ee00e61a869d7f677ba6ef32ef --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 12552 0 1216 13768 35c8 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0+/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0+/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0+/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0+/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0+/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..315f3dda4b126201c2bdf981fa22710076e39e19 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..edbaf398a95e785003ff5384cbccbb3dbe305fa4 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 12952 0 1216 14168 3758 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiZero_ArmV6-32bits/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiZero_ArmV6-32bits/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..985951cdbaa4676735f1710aaf49c5bbbe62bd52 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..edbaf398a95e785003ff5384cbccbb3dbe305fa4 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 12952 0 1216 14168 3758 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..368ba86e05c54f27478121f8924a9667643ba1e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/bsec_interface.h @@ -0,0 +1,402 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initalization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned phyisical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behaviour. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterature through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..a0882e3cbb3eade3bf563791273d8fdedbe6fb69 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..b1620613fd43d13bb243af37fae677a829790956 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 12426 0 1216 13642 354a (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..368ba86e05c54f27478121f8924a9667643ba1e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/bsec_interface.h @@ -0,0 +1,402 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initalization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned phyisical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behaviour. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterature through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..c12f05e521916fa28ff483a30fcb1946b986cb5a Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..4f06519d1f3ead9fef2de82d77b6a74539a69e73 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 12420 0 1216 13636 3544 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..368ba86e05c54f27478121f8924a9667643ba1e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/bsec_interface.h @@ -0,0 +1,402 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initalization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned phyisical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behaviour. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterature through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..2bf0a7f9235bf303ac8c78659dcaf18ab9215e11 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..2baae05c708d17e251713968fd853bae3036b549 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 12858 0 1216 14074 36fa (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..368ba86e05c54f27478121f8924a9667643ba1e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/bsec_interface.h @@ -0,0 +1,402 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initalization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned phyisical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behaviour. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterature through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..5a3b8e5e6c337623d9f94528160b368582b6143e Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..4f06519d1f3ead9fef2de82d77b6a74539a69e73 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 12420 0 1216 13636 3544 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0+/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0+/libalgobsec.a deleted file mode 100644 index 50bef35ed69f9ec6ef9f6cd6e0079ecefc813f12..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0+/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0+/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0+/libalgobsec.lib.Size.log deleted file mode 100644 index d1113c7abf9e8a01d0e8c3a974ec89343e0a8c4e..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0+/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 15814 0 1120 16934 4226 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0/libalgobsec.a deleted file mode 100644 index fcf8f82c7a00e5eb06959383ad7e342d4110626e..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0/libalgobsec.lib.Size.log deleted file mode 100644 index d1113c7abf9e8a01d0e8c3a974ec89343e0a8c4e..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M0/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 15814 0 1120 16934 4226 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M3/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M3/libalgobsec.a deleted file mode 100644 index 282e43052aa13883295e8142d6b8594aa97735bf..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M3/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M3/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M3/libalgobsec.lib.Size.log deleted file mode 100644 index d6706501ca2b1c7fd02d71b1fd20ba2c2dec67c3..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M3/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 14600 0 1120 15720 3d68 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4/libalgobsec.a deleted file mode 100644 index baf4de978b00de551a282c37a6c9675d4ceed53c..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4/libalgobsec.lib.Size.log deleted file mode 100644 index f6ae4dc61924ff6c403fd2c387fa077dd3abad43..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 14604 0 1120 15724 3d6c (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4F/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4F/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4F/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4F/libalgobsec.a deleted file mode 100644 index 9a5c21850f6249e12e804a82655906d45e3f303e..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4F/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4F/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4F/libalgobsec.lib.Size.log deleted file mode 100644 index ae2ec585a8f67e8188a9696e2b0769f646caf1b7..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M4F/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 15168 0 1120 16288 3fa0 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M7/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M7/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M7/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M7/libalgobsec.a deleted file mode 100644 index 7edafe396e89247875f3f0eeea32dbaacb69eb55..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M7/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M7/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M7/libalgobsec.lib.Size.log deleted file mode 100644 index f6ae4dc61924ff6c403fd2c387fa077dd3abad43..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/IAR7/Cortex_M7/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 14604 0 1120 15724 3d6c (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/MAC/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/MAC/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/MAC/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/MAC/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/MAC/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..368ba86e05c54f27478121f8924a9667643ba1e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/MAC/bsec_interface.h @@ -0,0 +1,402 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initalization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned phyisical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behaviour. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterature through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/MAC/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/MAC/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..cb1c7fd8af0a7fe752eb6d1714050c278df430c9 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/MAC/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiZero_ArmV6-32bits/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiZero_ArmV6-32bits/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiZero_ArmV6-32bits/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV6/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV6/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV6/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp32/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV6/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp32/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV6/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a similarity index 70% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.a rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a index 4c57fb66b496cbccc58e4bb9f5ff04093c9cffe9..ab2e351dab6955147f341960563e6b5dea568909 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..5341fd3766243214c9847be3202225c13d6f56a0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 35568 0 1216 36784 8fb0 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV8/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV8/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV8/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp8266/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV8/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp8266/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV8/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a similarity index 69% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a index 5308f5c2fffd845bafcc2e8eca3c3279c55c2e03..675f21a43e693ae78e1bcac3fb11deffc11ec023 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..8d9c3f68fb9e4f180f9584fecada044248d56198 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 35740 0 1216 36956 905c (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/libalgobsec.lib index 9c5addc77aac93d1821fd406c8d8b1e8c706f7b2..24e9b06b2eda1f34cf2e2f7f34b347a42456918c 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/libalgobsec.lib.Size.log index abbbdb50417c3aec9ceb2e782f912950804c6ba4..fb3fd5f86df4cd179049f5a4b06fb13556ce9a77 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0+/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 11607 0 1088 12695 3197 (TOTALS) + 12163 0 1216 13379 3443 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/libalgobsec.lib index ac966695532e8208c177a771818acb64b96fb423..b3c647f00e0998571af8b28e4c4568a5501260d9 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/libalgobsec.lib.Size.log index abbbdb50417c3aec9ceb2e782f912950804c6ba4..fb3fd5f86df4cd179049f5a4b06fb13556ce9a77 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M0/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 11607 0 1088 12695 3197 (TOTALS) + 12163 0 1216 13379 3443 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/libalgobsec.lib index 12c6eca96b8f4ecf92c65ad8b2ee482873ea1854..5ba1ca37fa2cc4cf0bd5c04d4d16173c5ec16ea9 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/libalgobsec.lib.Size.log index d9c0a25dd62263efc2fa6d53373542121721c1b2..2d780dc28bdcb7e6b500b1f30f1f26b99a319dae 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M3/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 11119 0 1088 12207 2faf (TOTALS) + 11719 0 1216 12935 3287 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/libalgobsec.lib index f434dd7953c0535954cc361bda3d28823731ce08..aa532ef72c8c6bcfdf3df23e178010789045e3d7 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/libalgobsec.lib.Size.log index d9c0a25dd62263efc2fa6d53373542121721c1b2..2d780dc28bdcb7e6b500b1f30f1f26b99a319dae 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 11119 0 1088 12207 2faf (TOTALS) + 11719 0 1216 12935 3287 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/libalgobsec.lib index 91423b1ead569f5c6601fdbdf833bf063b92d9b3..f8e7a6150bb539d7eae0025c39fccda5e80c283d 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/libalgobsec.lib.Size.log index b0dcf55abf3b365cd77400e2da7884c63c00ea37..f1b1dcab669c49153bf72fd232e90af2a3fa6f8b 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M4F/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 11979 0 1088 13067 330b (TOTALS) + 12655 0 1216 13871 362f (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/libalgobsec.lib index 4ac166ac84d4974b2271ba78aea423a4e7a6bcc7..87d0da91f71b5596dda5b2c63d40077ed678f9d8 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/libalgobsec.lib.Size.log index d2d7dc9371e8a6b32efa1cc7d2b03f6388b4595c..cba5555572b5c8b8227014de532ba6223cee1224 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/armcc/Cortex_M7/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 11135 0 1088 12223 2fbf (TOTALS) + 11735 0 1216 12951 3297 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/libalgobsec.a index 8244c6ac8caeef45864a602aacd702f62b69ec0c..bee790c6b0d5790cd8095ae5f67dc536d74e6606 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/libalgobsec.a.Size.log index 5d0d0b6c971e9ed329429696a269ed79ba0fac22..b210419b5f21313f13250291d3d8dee941dd36e4 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR32/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 13130 0 1428 14558 38de (TOTALS) + 13786 0 1556 15342 3bee (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/libalgobsec.a index 79b9e6ef34f7198b2f9d05259c6bec27fe6a12a6..f4b91073444550bfbc378903ed797f5e7d312179 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/libalgobsec.a.Size.log index ccdeb65221389eaa4669ea1279bbc92b444f3f0a..8cf6b9021021aca7d52db1131a67d886f60a2485 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_XMEGA/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 25883 0 1048 26931 6933 (TOTALS) + 27572 0 1176 28748 704c (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/libalgobsec.a index c369f7610e3a55b0630ee2a0321141ba3b8c6b13..dc3dcf36cf08903339ad0d08b72363edda654733 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/libalgobsec.a.Size.log index 9be6461002a285cf2db7e46fe50ec6f786a22e37..b0227575f46060bf35ef192ccb35b6b44205d212 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/avr/AVR8_megaAVR/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 26085 0 1048 27133 69fd (TOTALS) + 27776 0 1176 28952 7118 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..368ba86e05c54f27478121f8924a9667643ba1e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/bsec_interface.h @@ -0,0 +1,402 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initalization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned phyisical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behaviour. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterature through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp32/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/libalgobsec.a similarity index 68% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp32/libalgobsec.a rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/libalgobsec.a index 02c33ca27b143a204424dca80820880b72930f29..7386308393b05c0c19219f4619f37e4c472e8173 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp32/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..dfeeaab2ca081afae836e08e32ac7aa576f14248 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp32/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 14710 0 1216 15926 3e36 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..368ba86e05c54f27478121f8924a9667643ba1e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/bsec_interface.h @@ -0,0 +1,402 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initalization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned phyisical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behaviour. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterature through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..53c749c3ec7e93f96828264690eb7925b9972bee Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..c32e6c52144358aaf4d607d7805a3f2605ea3fca --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp/esp8266/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 17003 0 1216 18219 472b (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp32/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp32/bsec_datatypes.h deleted file mode 100644 index 7b45f7f2359c881f1c39d2a795615eda4c438554..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp32/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp8266/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp8266/bsec_datatypes.h deleted file mode 100644 index 7b45f7f2359c881f1c39d2a795615eda4c438554..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp8266/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp8266/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp8266/libalgobsec.a deleted file mode 100644 index 3d6c7705bd6080ff8a28c0253226cfacf82a6d65..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/esp8266/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/libalgobsec.a index be7e39602a69bdcd5f005e6eab2e53e175318861..3004fc52d665cf46b886c6a78344d2bae5deed55 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/libalgobsec.a.Size.log index 8312302cfded15529c0ffc4e3c55215b635da311..c48482e0ee250a645937d48f9542c488336bf19b 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/ARMv8/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 13412 0 1088 14500 38a4 (TOTALS) + 13924 0 1216 15140 3b24 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/libalgobsec.a index 8e7329f37a5b2836014f4de475e466406cade494..0965581ac8b1e480761c31d4e3acf0310484fda5 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/libalgobsec.a.Size.log index 1ab892f490261b2f5ce57a5a13eecc735f70da26..3c6521c3724fc8d6e803a06235c2a1e38917b115 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_A7/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 12652 0 1088 13740 35ac (TOTALS) + 12912 0 1216 14128 3730 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/libalgobsec.a index 6ce886554266f9d2ff3dfb36ca1d36425ae447a7..4dc45b48533e018ae840b83f8e01f29d990628ec 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/libalgobsec.a.Size.log index 5a7e473f796e07feba252f577cf9ce31ebcd317c..02432d270bfebd8cad8678cc5cdc9048e4ea61be 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0+/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 13240 0 1088 14328 37f8 (TOTALS) + 13764 0 1216 14980 3a84 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/libalgobsec.a index f55100ed32cf9af52ba27b2e2409e6c2c4b9677a..cc0469d822cd2099397e963e566a1f937527a90c 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/libalgobsec.a.Size.log index 5a7e473f796e07feba252f577cf9ce31ebcd317c..02432d270bfebd8cad8678cc5cdc9048e4ea61be 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M0/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 13240 0 1088 14328 37f8 (TOTALS) + 13764 0 1216 14980 3a84 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/libalgobsec.a index 6c703cf440b0735c5c08eb425438a09f7d21804d..60b7f22b90a667b55a89f384fdada8b0d1c92f87 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/libalgobsec.a.Size.log index 806639b03a428f378160f08eb21941daff6ae3f9..3b55f38a409061b6600715d52d4a2933209a8cc5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M3/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 11972 0 1088 13060 3304 (TOTALS) + 12288 0 1216 13504 34c0 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..368ba86e05c54f27478121f8924a9667643ba1e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/bsec_interface.h @@ -0,0 +1,402 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initalization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned phyisical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behaviour. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterature through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..0d4d436805f53f9df9bd2969e7ab76de8044d082 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..3b55f38a409061b6600715d52d4a2933209a8cc5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 12288 0 1216 13504 34c0 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..368ba86e05c54f27478121f8924a9667643ba1e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/bsec_interface.h @@ -0,0 +1,402 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initalization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned phyisical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behaviour. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterature through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..6380a538dd3bad4691819790a3da87beb4570005 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..b6b3d6a1063871e4d331e5f17fdb2cfa93fe65a6 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M33F/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 23988 0 1216 25204 6274 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/libalgobsec.a index d3e223053a85829ed9c79e8c69044f539afc6d01..ff14cdf4eea731e54b9ca0b3b9206eca3d93f249 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/libalgobsec.a.Size.log index 566650d27d80ad11804dfb26adef5bffa0ec485b..9bd0e12042cb5e9261199e406a907692e1de60ae 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 12020 0 1088 13108 3334 (TOTALS) + 12328 0 1216 13544 34e8 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/libalgobsec.a index fd83ae6253828b63adc93a69a64885a5781d9db0..f3be43986e7f8575bf7ed3c53fc6fab8eea18e3e 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/libalgobsec.a.Size.log index 235f10a3c6ac161ea131ac3049960972c0771869..b4bc60c1446c96bcce6b038babf7586de15ea371 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M4F/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 12112 0 1088 13200 3390 (TOTALS) + 12444 0 1216 13660 355c (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/libalgobsec.a index 7c4d77afdaea3e69b80a2d8ec850c2ee7872a069..d643b7b3dd7b2c2c334f4102233546e76e7f22ce 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/libalgobsec.a.Size.log index 503084227cd19e777647cff52dfdf34fca939212..709fca0b87908cb77c7ffea805292672f07b9701 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Cortex_M7/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 12268 0 1088 13356 342c (TOTALS) + 12400 0 1216 13616 3530 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x64/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x64/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x64/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0+/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x64/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0+/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x64/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x64/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x64/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..e3458d15cb3b695aeefda3e362dd3af0f82ee6ce Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x64/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x64/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x64/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..6190f703f1608fb7f57022c63422e755a80e6080 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x64/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 20609 0 1216 21825 5541 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x86/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x86/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x86/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x86/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x86/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x86/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x86/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..cf3b22126850dd3aa54d203e7bf3e0e3c68c6c93 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x86/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x86/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x86/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..3f0775fcee9dd82241f19c24711b6f68f4161e7d --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Linux/x86/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 24871 0 1200 26071 65d7 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..368ba86e05c54f27478121f8924a9667643ba1e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/bsec_interface.h @@ -0,0 +1,402 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initalization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned phyisical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behaviour. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterature through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/libalgobsec.lib new file mode 100644 index 0000000000000000000000000000000000000000..053003d110458166481332767aa3327cb8484a1f Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/libalgobsec.lib.Size.log similarity index 50% rename from lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.lib.Size.log rename to lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/libalgobsec.lib.Size.log index b11d94774ce33bf7eb8b5e4b76ce0086d755df68..561879ec362b32a2aa6f4001dae4e0efb91caa02 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x64/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 34096 0 1088 35184 8970 (TOTALS) + 21428 0 1216 22644 5874 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..368ba86e05c54f27478121f8924a9667643ba1e5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/bsec_interface.h @@ -0,0 +1,402 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initalization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned phyisical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behaviour. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterature through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/libalgobsec.lib new file mode 100644 index 0000000000000000000000000000000000000000..8372bfa15d6befd95cf000a4d95b051f8881ebcb Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/libalgobsec.lib.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..2983c4d24bc696e260a7f9720cf1e21bf9096b96 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/gcc/Windows/x86/libalgobsec.lib.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 18920 0 1216 20136 4ea8 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/libalgobsec.a index aab72d26b915410f0f7e8bf92d520c53eabc5df7..023fc6442982d2bae57b0627b4c32752fffa3b7a 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/libalgobsec.a.Size.log index ade957eb207e7f355e9a8ad21bd4450116ae63d5..0f8169ddf34be9459acc0792aaec18c94c75d339 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/bin/msp430-elf-gcc/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 20802 0 1054 21856 5560 (TOTALS) + 21590 0 1182 22772 58f4 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/inc/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/lite_version/inc/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/inc/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/inc/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/lite_version/inc/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/lite_version/inc/bsec_interface.h index d6c09a392958a326a5553bf2c5bbb4afa2d0cedc..368ba86e05c54f27478121f8924a9667643ba1e5 100644 --- a/lib/vendor/Bosch/BSEC/algo/lite_version/inc/bsec_interface.h +++ b/lib/vendor/Bosch/BSEC/algo/lite_version/inc/bsec_interface.h @@ -111,7 +111,7 @@ * * * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during - * re-initialization to continue processing. + * re-initalization to continue processing. * * | Steps | Function | * |----------------------------------------|-------------------| @@ -129,7 +129,7 @@ * performance of the gas sensor outputs. * * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over - * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * the time. These will be lost if library is initialised due to system reset. In order to avoid this situation * library state shall be stored in non volatile memory so that it can be loaded after system reset. * * @@ -243,7 +243,7 @@ bsec_library_return_t bsec_init(void); requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; - // Allocate a struct for the returned physical sensor settings + // Allocate a struct for the returned phyisical sensor settings bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; @@ -265,7 +265,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * - The samples of all library inputs must be passed with unique identifiers representing the input signals from * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided * within the same time period as they are read. A sequential provision to the library might result in undefined - * behavior. + * behaviour. * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of * virtual sensors where the order of the returned outputs may be arbitrary. * - The samples of all input as well as output signals of physical as well as virtual sensors use the same @@ -319,7 +319,7 @@ bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t // Invoke main processing BSEC function status = bsec_do_steps( input, n_input, output, &n_output ); - // Iterate through the BSEC output data, if the call succeeded + // Iterature through the BSEC output data, if the call succeeded if(status == BSEC_OK) { for(int i = 0; i < n_output; i++) @@ -366,168 +366,6 @@ bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uin bsec_library_return_t bsec_reset_output(uint8_t sensor_id); -/*! - * @brief Update algorithm configuration parameters - * - * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized - * by bsec_set_configuration(). This is an optional step. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose - * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting - * the required size. - * - * @param[in] serialized_settings Settings serialized to a binary blob - * @param[in] n_serialized_settings Size of the settings blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a provided config string into serialized_settings - - // Apply the configuration - bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); - - \endcode - */ - -bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, - const uint32_t n_serialized_settings, uint8_t * work_buffer, - const uint32_t n_work_buffer_size); - - -/*! - * @brief Restore the internal state of the library - * - * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, - * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() - * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() - * before resuming further operation of the library. - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * @param[in] serialized_state States serialized to a binary blob - * @param[in] n_serialized_state Size of the state blob - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; - - // Here we will load a state string from a previous use of BSEC - - // Apply the previous state to the current BSEC session - bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); - - \endcode -*/ - -bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, - uint8_t * work_buffer, const uint32_t n_work_buffer_size); - - -/*! - * @brief Retrieve the current library configuration - * - * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding - * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). - * - * @note The function bsec_get_configuration() is required to be used for debugging purposes only. - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] config_id Identifier for a specific set of configuration settings to be returned; - * shall be zero to retrieve all configuration settings. - * @param[out] serialized_settings Buffer to hold the serialized config blob - * @param[in] n_serialized_settings_max Maximum available size for the serialized settings - * @param[in,out] work_buffer Work buffer used to parse the binary blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; - uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; - uint32_t n_serialized_settings = 0; - - // Configuration of BSEC algorithm is stored in 'serialized_settings' - bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); - - \endcode - */ - -bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, - uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); - - -/*! - *@brief Retrieve the current internal library state - * - * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using - * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). - * - * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the - * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the - * required size. - * - * - * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be - * zero to retrieve all states. - * @param[out] serialized_state Buffer to hold the serialized config blob - * @param[in] n_serialized_state_max Maximum available size for the serialized states - * @param[in,out] work_buffer Work buffer used to parse the blob - * @param[in] n_work_buffer Length of the work buffer available for parsing the blob - * @param[out] n_serialized_state Actual size of the returned serialized blob - * - * @return Zero when successful, otherwise an error code - * - \code{.c} - // Example // - - // Allocate variables - uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; - uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; - uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; - - // Algorithm state is stored in 'serialized_state' - bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); - - \endcode - */ - -bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, - const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, - uint32_t * n_serialized_state); - /*! * @brief Retrieve BMExxx sensor instructions * diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0+/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0+/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0+/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M3/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0+/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M3/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0+/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..cd068f1313ad99128acbba84ddd51f902fea41c1 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..a1fb2c471432339f5c61eb8780682253fe1bd9f2 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0+/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 21276 0 1248 22524 57fc (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..5ee8baf9aad751c012e0e1541add3fa164564bbd Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..a1fb2c471432339f5c61eb8780682253fe1bd9f2 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M0/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 21276 0 1248 22524 57fc (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M3/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M3/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M3/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4F/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M3/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4F/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M3/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..c3d6d07d443021c08028d56191f350ffa79126bb Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..a6ed8de8e2cb7f9df14f32ba1fc0bb6d7c90ac40 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M3/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 20902 0 1248 22150 5686 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M7/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M7/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..998b9836b62a68458ab33447b558fabe7150c118 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..9d2aa043127a89b2d633d8c5996e64f3a0b9eb9c --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 20918 0 1248 22166 5696 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4F/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4F/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4F/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4F/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..470cc2bee62f1a2a3333a60d49db1d92292c0346 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..fab0fa557e781c9e33d405c0e39974f7dd3cba55 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M4F/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 21458 0 1248 22706 58b2 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M7/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M7/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiZero_ArmV6-32bits/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M7/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiZero_ArmV6-32bits/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M7/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..5d64fa42027721eef0e2792fbc9143322f5a01b0 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..9d2aa043127a89b2d633d8c5996e64f3a0b9eb9c --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR7/Cortex_M7/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 20918 0 1248 22166 5696 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0+/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0+/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0+/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp32/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0+/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp32/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0+/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..f54099106816001ac5e05841a726cbda81702992 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..537178f68fbf4ba9a829594fbbc122e1f95f24a2 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0+/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 21414 0 1248 22662 5886 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp8266/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0/bsec_interface.h similarity index 100% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp8266/bsec_interface.h rename to lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0/bsec_interface.h diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..d4343569c0432059cb00e832bbfb6aab70bab47d Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..537178f68fbf4ba9a829594fbbc122e1f95f24a2 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M0/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 21414 0 1248 22662 5886 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..1c8554abfeb0779bdf3c243052b8507cdaf78a57 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..21e2d92ea840e4ae25086e434f4076b4c0b4bb79 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M3/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 20780 0 1248 22028 560c (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..0a010b792c1cdc1a95f859a529f212fd3e3e0f66 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..839e9b05e1402d12703c7a7317b241afd008016e --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 20776 0 1248 22024 5608 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..cabdfb34c4d292ab02d317077190f53abcc59f52 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..19e862d19072c444e4dd3c552c49e590cf813cfd --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M4F/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 21224 0 1248 22472 57c8 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..0d33a28e20c6bdeb1cba54c76ad01759b1bbf0ae Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..839e9b05e1402d12703c7a7317b241afd008016e --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR/IAR8/Cortex_M7/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 20776 0 1248 22024 5608 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0+/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0+/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0+/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0+/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0+/libalgobsec.a deleted file mode 100644 index 7534eea1706fffaeed70937488b132bcf6c64355..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0+/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0+/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0+/libalgobsec.lib.Size.log deleted file mode 100644 index cd4dfecef11c917d81887aaf08a0dd39f3606b75..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0+/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 24628 0 1120 25748 6494 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0/libalgobsec.a deleted file mode 100644 index 717568ebecb9d227490b8f469b20952dd0d17945..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0/libalgobsec.lib.Size.log deleted file mode 100644 index cd4dfecef11c917d81887aaf08a0dd39f3606b75..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M0/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 24628 0 1120 25748 6494 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M3/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M3/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M3/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M3/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M3/libalgobsec.a deleted file mode 100644 index 9d96647245f2352614b8e48cbb1826fe889a63c8..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M3/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M3/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M3/libalgobsec.lib.Size.log deleted file mode 100644 index 00b479cface9558f9be5bf6cd6f5a11f5c5af5b3..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M3/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 23436 0 1120 24556 5fec (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4/libalgobsec.a deleted file mode 100644 index 579615e07eb35c5c2d408a3e3492f978f2648560..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4/libalgobsec.lib.Size.log deleted file mode 100644 index 8d978df0a1bb8de98c8b1d19194c670e94217ad8..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 23440 0 1120 24560 5ff0 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4F/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4F/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4F/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4F/libalgobsec.a deleted file mode 100644 index ef081d891dd463853e14887b61c509a1024f9864..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4F/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4F/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4F/libalgobsec.lib.Size.log deleted file mode 100644 index 8a82458277e5bfdb5123778eaf8b282bc488c897..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M4F/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 24036 0 1120 25156 6244 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M7/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M7/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M7/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M7/libalgobsec.a deleted file mode 100644 index b3bfabc15cc4c5eedf44ab6479a5269da4b99aa0..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M7/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M7/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M7/libalgobsec.lib.Size.log deleted file mode 100644 index 8d978df0a1bb8de98c8b1d19194c670e94217ad8..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/IAR7/Cortex_M7/libalgobsec.lib.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 23440 0 1120 24560 5ff0 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/MAC/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/MAC/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/MAC/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/MAC/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/MAC/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/MAC/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/MAC/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/MAC/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..cb719f71dd247332ac999b91217df7e821baf616 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/MAC/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiZero_ArmV6-32bits/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiZero_ArmV6-32bits/bsec_datatypes.h deleted file mode 100644 index f28550692865e144897c49ef5eed4c36daa07269..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiZero_ArmV6-32bits/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| - * | UNRELIABLE | 0 | Stabilization / run-in ongoing | - * | LOW_ACCURACY | 1 | Low accuracy, to reach high accuracy(3), please expose sensor once to good air and bad air for autotrimming | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, autotrimming ongoing | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.a.Size.log deleted file mode 100644 index 736b654121c9f9de8f66594812c7b1ae42145aa1..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.a.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 56180 0 1120 57300 dfd4 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a similarity index 76% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.a rename to lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a index 128bdc014e880d557b16349cc4812680e4f1e74a..e5f3663cc6c590aab3c120f394df41c04a2b0792 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiZero_ArmV6-32bits/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..6b7acc152d6435e60a80cfa51ad28fc798611fc5 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV6/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 57648 0 1248 58896 e610 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a similarity index 68% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a rename to lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a index 1e38d5993929619e28af60ca6d55247e6c256abf..f2d32f4f0fac89248aeb1fa51161b564266ba8c4 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPI/PiThree_ArmV8-a-64bits/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..0d7c6f0f5844f1c966f32ba7b502d47f6294ab00 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 57816 0 1248 59064 e6b8 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/libalgobsec.lib index b14fb39dd8e1aad98638ffcd4b817d587a29d7d0..5641082500c35269f4198c83f5e7f41e8e52aab3 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/libalgobsec.lib.Size.log index 8d963d10e88e53d754814454a39d44dba46acf98..a7ce7addfdc0fbc420e802edbacf5f2b8ea1a244 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0+/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 18909 0 1120 20029 4e3d (TOTALS) + 19469 0 1248 20717 50ed (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/libalgobsec.lib index 548f694bf8ac8ff1948d846fcd82632fcb5772d6..6e655c0fe01f3cc93eb11385f60aff90a6179d16 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/libalgobsec.lib.Size.log index 8d963d10e88e53d754814454a39d44dba46acf98..a7ce7addfdc0fbc420e802edbacf5f2b8ea1a244 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M0/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 18909 0 1120 20029 4e3d (TOTALS) + 19469 0 1248 20717 50ed (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/libalgobsec.lib index b1ffbb6360739205a1080fd200d4f153eb4beef3..8a2fcf6908afc7f3ac9ab654ba09e61352724720 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/libalgobsec.lib.Size.log index 971857bd3533422e548139f68a387fc023055aec..ed26607a5ad39f090714091c7e8caa6cbe4c1d47 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M3/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 18129 0 1120 19249 4b31 (TOTALS) + 18721 0 1248 19969 4e01 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/libalgobsec.lib index 04610600bcbc37a8e45ab9aed3d97c161d5228d8..c1c5ceed62bf12924795dbbc4acfa90919e658ed 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/libalgobsec.lib.Size.log index 971857bd3533422e548139f68a387fc023055aec..ed26607a5ad39f090714091c7e8caa6cbe4c1d47 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 18129 0 1120 19249 4b31 (TOTALS) + 18721 0 1248 19969 4e01 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/libalgobsec.lib index 58214e37e2a7ae44b764f10dc36f982f79976cf4..bdca6bd708c1b0c26bf5f8c7cfc49b374e8493bb 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/libalgobsec.lib.Size.log index 0338df5b55e85ec00f6529f641b62a03cbecab1e..db0987604d37da949df085b536a3d36a1feaaecb 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M4F/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 19091 0 1120 20211 4ef3 (TOTALS) + 19767 0 1248 21015 5217 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/libalgobsec.lib index fa684f6a26c880ce571133a29c74221f1518e474..bac3254d42b5bcbe67ac9394350f59af7efb7119 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/libalgobsec.lib and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/libalgobsec.lib.Size.log index cc67a05dd026f7a4d332ecb17f992c0543fb1e43..33f638e1f279375c8f58e7cd445272a6d0789b06 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/libalgobsec.lib.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/armcc/Cortex_M7/libalgobsec.lib.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 18145 0 1120 19265 4b41 (TOTALS) + 18749 0 1248 19997 4e1d (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/libalgobsec.a index f7fe01a9da7604b6df760168e16872a3005d38f0..ac905216313eafab37d9a81346e4fc750ac49a9b 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/libalgobsec.a.Size.log index 0f274f942b8ca842dfcc6cd11c8c9a3ea1093013..217f2ce04173c09476c608dcc8b117a7a4eb1446 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR32/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 23760 0 1460 25220 6284 (TOTALS) + 24410 0 1588 25998 658e (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/libalgobsec.a index 9660aef848c66f5ce8bb04aff20a5e93ef3ae878..7427dc0fff421bc2bfc33152bd42023b6a30a996 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/libalgobsec.a.Size.log index c5ca8ebc40a5a2b78d049157d962506ac7b2a590..323dd622e72d1b14b956edd1d8235fa2e4d3e8b2 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_XMEGA/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 42505 0 1064 43569 aa31 (TOTALS) + 44212 0 1192 45404 b15c (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/libalgobsec.a index 73f7059903047fe93b1818d5864dd7efbd2e938f..b46f2275f2044ced8cc4261429a9f5beb7ac59be 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/libalgobsec.a.Size.log index 06543f4f00ca4ce3d7940be1944e5f9cd72ad69d..a8e22f5613c97ceb756a0d8681add6d30a019202 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/avr/AVR8_megaAVR/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 43291 0 1064 44355 ad43 (TOTALS) + 45000 0 1192 46192 b470 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.dll b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.dll index 16033769b3b4e1797d32a5e3076959e69d1fd81b..c3274f2f669ae3d3a60e2a1b1335bc43d7ff48cb 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.dll and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.dll differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.exp b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.exp deleted file mode 100644 index c26120c3adae267881a70e7f774bc08878543750..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.exp and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.lib b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.lib deleted file mode 100644 index f82cd3430ceff2f8a0b06530ebc71b281c6c9340..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.lib and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.pdb b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.pdb deleted file mode 100644 index a298db1c392bb67a64c359e3ea89bce988cd07e6..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x64/BSECLibrary64.pdb and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.dll b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.dll index 043c9d46d26326168e05fbd0780f0a47c97d1dd4..b734b56a515baba52c4cf0ac2efbcd98dd687a4d 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.dll and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.dll differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.exp b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.exp deleted file mode 100644 index 1538b904a91361a3e5baeedeeb077d4554672d5d..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.exp and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.lib b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.lib deleted file mode 100644 index 1e7e4642b27623b9ca82b52a8c0827c4f8ea6ecf..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.lib and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.pdb b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.pdb deleted file mode 100644 index efc380dd81d30b7c14fad9a845085d6b1f678b4f..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/dll/x86/BSECLibrary32.pdb and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp32/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/libalgobsec.a similarity index 79% rename from lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp32/libalgobsec.a rename to lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/libalgobsec.a index e9e4ae2331153f5a59560498f416e64519b189b1..0815f73a897a02efc165660590a0361c1b44c038 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp32/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..45ff3a34c360bcef8d2898d97489b105e8260f69 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp32/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 24446 0 1248 25694 645e (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..9e11de7a3bbe1b0165072b180c678cedbffc7259 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..fb49c5a669393807804e2f937fe63ca30a6a3f37 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp/esp8266/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 27954 0 1248 29202 7212 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp32/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp32/bsec_datatypes.h deleted file mode 100644 index 7b45f7f2359c881f1c39d2a795615eda4c438554..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp32/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp32/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp32/libalgobsec.a.Size.log deleted file mode 100644 index 067104f7566f39968bf3196839e0576780c93f5c..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp32/libalgobsec.a.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 23809 0 1120 24929 6161 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp8266/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp8266/bsec_datatypes.h deleted file mode 100644 index 7b45f7f2359c881f1c39d2a795615eda4c438554..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp8266/bsec_datatypes.h +++ /dev/null @@ -1,488 +0,0 @@ -/* - * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - - /** - * @file bsec_datatypes.h - * - * @brief - * Contains the data types used by BSEC - * - */ - -#ifndef __BSEC_DATATYPES_H__ -#define __BSEC_DATATYPES_H__ - -#ifdef __cplusplus -extern "C" -{ -#endif - -/*! - * @addtogroup bsec_interface BSEC C Interface - * @{*/ - -#ifdef __KERNEL__ -#include <linux/types.h> -#endif -#include <stdint.h> -#include <stddef.h> - -#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ -#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ -#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ -#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ -#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ -#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ -#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ -#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ - -#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ -#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ -#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ -#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ - -/*! - * @brief Enumeration for input (physical) sensors. - * - * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * returned in the parameter required_sensor_settings of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_input_t - */ -typedef enum -{ - /** - * @brief Pressure sensor output of BMExxx [Pa] - */ - BSEC_INPUT_PRESSURE = 1, - - /** - * @brief Humidity sensor output of BMExxx [%] - * - * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to - * the temperature outside of the device. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HUMIDITY = 2, - - /** - * @brief Temperature sensor output of BMExxx [degrees Celsius] - * - * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. - * The temperature value is a very local measurement value and can be influenced by external heat sources. - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_TEMPERATURE = 3, - - /** - * @brief Gas sensor resistance output of BMExxx [Ohm] - * - * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, - * the lower the resistance and vice versa). - */ - BSEC_INPUT_GASRESISTOR = 4, /*!< */ - - /** - * @brief Additional input for device heat compensation - * - * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * ALL solution: Generic heat source 1 - * - * @sa bsec_virtual_sensor_t - */ - BSEC_INPUT_HEATSOURCE = 14, - - /** - * @brief Additional input for device heat compensation 8 - * - * Generic heat source 8 - */ - - - /** - * @brief Additional input that disables baseline tracker - * - * 0 - Normal - * 1 - Event 1 - * 2 - Event 2 - */ - BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, - -} bsec_physical_sensor_t; - -/*! - * @brief Enumeration for output (virtual) sensors - * - * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs - * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). - * - * @sa bsec_sensor_configuration_t @sa bsec_output_t - */ -typedef enum -{ - /** - * @brief Indoor-air-quality estimate [0-500] - * - * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. - * - * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms - * automatically calibrate and adapt themselves to the typical environments where the sensor is operated - * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience - * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four - * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. - */ - BSEC_OUTPUT_IAQ = 1, - BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ - BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ - BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ - - /** - * @brief Temperature sensor signal [degrees Celsius] - * - * Temperature directly measured by BME680 in degree Celsius. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_TEMPERATURE = 6, - - /** - * @brief Pressure sensor signal [Pa] - * - * Pressure directly measured by the BME680 in Pa. - */ - BSEC_OUTPUT_RAW_PRESSURE = 7, - - /** - * @brief Relative humidity sensor signal [%] - * - * Relative humidity directly measured by the BME680 in %. - * - * @note This value is cross-influenced by the sensor heating and device specific heating. - */ - BSEC_OUTPUT_RAW_HUMIDITY = 8, - - /** - * @brief Gas sensor signal [Ohm] - * - * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC - * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). - */ - BSEC_OUTPUT_RAW_GAS = 9, - - /** - * @brief Gas sensor stabilization status [boolean] - * - * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_STABILIZATION_STATUS = 12, - - /** - * @brief Gas sensor run-in status [boolean] - * - * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization - * is finished (1). - */ - BSEC_OUTPUT_RUN_IN_STATUS = 13, - - /** - * @brief Sensor heat compensated temperature [degrees Celsius] - * - * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. - * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. - * - * - * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value - * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. - * - * Thus, the value is calculated as follows: - * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` - * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` - * - * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. - * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, - - /** - * @brief Sensor heat compensated humidity [%] - * - * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. - * - * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature - * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. - * - * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be - * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. - */ - BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, - - BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ - BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ -} bsec_virtual_sensor_t; - -/*! - * @brief Enumeration for function return codes - */ -typedef enum -{ - BSEC_OK = 0, /*!< Function execution successful */ - BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ - BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ - BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ - BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ - BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ - BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ - BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ - BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ - BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ - BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ - BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ - BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ - BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ - BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ - BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ - BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ - BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ - BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ - BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ - BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ - BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ - BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ - BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ - BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ - BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ - BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ - BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ - BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ - BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ - BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ - BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ -} bsec_library_return_t; - -/*! - * @brief Structure containing the version information - * - * Please note that configuration and state strings are coded to a specific version and will not be accepted by other - * versions of BSEC. - * - */ -typedef struct -{ - uint8_t major; /**< @brief Major version */ - uint8_t minor; /**< @brief Minor version */ - uint8_t major_bugfix; /**< @brief Major bug fix version */ - uint8_t minor_bugfix; /**< @brief Minor bug fix version */ -} bsec_version_t; - -/*! - * @brief Structure describing an input sample to the library - * - * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided - * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in - * an error code being returned from bsec_do_steps(). - * - * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible - * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. - * - * @sa bsec_physical_sensor_t - * - */ -typedef struct -{ - /** - * @brief Time stamp in nanosecond resolution [ns] - * - * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or - * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) - */ - int64_t time_stamp; - float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ -} bsec_input_t; - -/*! - * @brief Structure describing an output sample of the library - * - * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of - * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output - * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. - * - * @sa bsec_virtual_sensor_t - */ -typedef struct -{ - int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ - float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ - uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ - uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ - - /** - * @brief Accuracy status 0-3 - * - * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as - * follows: - * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | - * - * For example: - * - * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. - * - * | Virtual sensor | Value | Accuracy description | - * |--------------------- |-------|------------------------------------------------------------------------------| - * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | - * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | - * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | - * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | - * - * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is - * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately - * 30 minutes each. - * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | - */ - uint8_t accuracy; -} bsec_output_t; - -/*! - * @brief Structure describing sample rate of physical/virtual sensors - * - * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information - * about the sample rates used for BSEC inputs. - */ -typedef struct -{ - /** - * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] - * - * Only supported sample rates are allowed. - */ - float sample_rate; - - /** - * @brief Identifier of the virtual or physical sensor - * - * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument - * to bsec_update_subscription() or as the required_sensor_settings argument. - * - * | bsec_update_subscription() argument | sensor_id field interpretation | - * |-------------------------------------|--------------------------------| - * | requested_virtual_sensors | ::bsec_virtual_sensor_t | - * | required_sensor_settings | ::bsec_physical_sensor_t | - * - * @sa bsec_physical_sensor_t - * @sa bsec_virtual_sensor_t - */ - uint8_t sensor_id; -} bsec_sensor_configuration_t; - -/*! - * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor - * - * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. - * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling - * settings for temperature, humidity, and pressure should be set to the provided settings provided in - * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and - * bsec_bme_settings_t::pressure_oversampling, respectively. - * - * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided - * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. - */ -typedef struct -{ - int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ - uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ - uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ - uint16_t heating_duration; /*!< @brief Heating duration [ms] */ - uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ - uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ - uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ - uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ - uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ -} bsec_bme_settings_t; - -/* internal defines and backward compatibility */ -#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ - -/*@}*/ - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp8266/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp8266/libalgobsec.a deleted file mode 100644 index 2bba45dba2feac4c99cb980924d069152e384a61..0000000000000000000000000000000000000000 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp8266/libalgobsec.a and /dev/null differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp8266/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp8266/libalgobsec.a.Size.log deleted file mode 100644 index ffe768d4fc6b24ff76263753cfdeacf73f179895..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/esp8266/libalgobsec.a.Size.log +++ /dev/null @@ -1,2 +0,0 @@ - text data bss dec hex filename - 28581 0 1120 29701 7405 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/libalgobsec.a index dd1703d72b99b8f1744fd635e363cd0a020c3f5a..aad79550ad615a82a6789d10f40e3f8bde326f00 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/libalgobsec.a.Size.log index a5fbeb5297c29d007b9bf9763953815feee8e9cb..07afa2985d637eb3a1dec00fc3bc5c9d09daeee8 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/ARMv8/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 22524 0 1120 23644 5c5c (TOTALS) + 22796 0 1248 24044 5dec (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/libalgobsec.a index f6fea32d0951b40340c2d6f2c9e696cc12181020..453f3ace3cbb9be847e90918b7051e690d0a81d7 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/libalgobsec.a.Size.log index e038cf9a396f8b2c684e7c23dc787f3bcd4772db..a74592e3a335d4000e57226bdfe9f1e0a2c69da5 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_A7/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 21428 0 1120 22548 5814 (TOTALS) + 21828 0 1248 23076 5a24 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/libalgobsec.a index 84d7f8261340ea229037d4129d99d57cbc4408c2..6bb980632eb0b43cee8e28f29a19eaf6e3287282 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/libalgobsec.a.Size.log index e0ad70e5ff4e238c04d4791dabcc12667f440852..d2b00c6eab614148658763ce244e70edf1738b11 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0+/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 22444 0 1120 23564 5c0c (TOTALS) + 22932 0 1248 24180 5e74 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/libalgobsec.a index 0678a905c0136d644834f15228414db4e0d9897d..5b19c968a0b27d5f94044aef126e6739d8f5c6bf 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/libalgobsec.a.Size.log index e0ad70e5ff4e238c04d4791dabcc12667f440852..d2b00c6eab614148658763ce244e70edf1738b11 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M0/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 22444 0 1120 23564 5c0c (TOTALS) + 22932 0 1248 24180 5e74 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/libalgobsec.a index d41517506223ba197191243a68f580ed11224aed..51c6242ed2eaea4962337a49cb00fdcc4f642ff7 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/libalgobsec.a.Size.log index 801c2c2b6fa32f9acadf279bb06e0ca44cd5b9f9..cce747b4ddd8cfadde58cc6baceb301c7eb371d5 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M3/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 20608 0 1120 21728 54e0 (TOTALS) + 21036 0 1248 22284 570c (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..9aef40ecd2c4da6a1e44d492757dbb9e7fca0c39 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..f1d740b23539f98ee3426c2651f86348f5c6378e --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 21044 0 1248 22292 5714 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..95db598b8be6747905b2a27bd1ba41874165021c Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..307045683b88b3e2cba2c7c5c68d1f9a22a68485 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M33F/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 37182 0 1248 38430 961e (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/libalgobsec.a index 0750089ed2e891a7147813b09f9387ab9369df8d..4168f856390480f42a6cfebd9f8434400c2aab64 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/libalgobsec.a.Size.log index ee82b55fbd6d1c2b8924f1d5674cff546942ab80..f574fb9eaa3cf4c2d527edf4346b3e4b74ca635f 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 20620 0 1120 21740 54ec (TOTALS) + 20944 0 1248 22192 56b0 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/libalgobsec.a index c94845173553b8ae0f9f2d6d60b0957ae31a581c..0650d8682885f46c3964076337e17836fcd10fa7 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/libalgobsec.a.Size.log index 0a28272c4e38e91e75a2274db5f9176096752366..e55ce269b236d92477baf3d75d3b0ad151e2f8e7 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M4F/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 20788 0 1120 21908 5594 (TOTALS) + 21132 0 1248 22380 576c (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/libalgobsec.a index 142b6cd66fccbb29d8971633950a44ed7b197be8..d537e5c1919c98e99a1299830d41f10392068249 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/libalgobsec.a.Size.log index 5c542da4e9ea44230d5c99c370c64dac0bb5a272..a5db145124690ecb96a73f606e33bb68be7ee4ed 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Cortex_M7/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 21172 0 1120 22292 5714 (TOTALS) + 21216 0 1248 22464 57c0 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..f6e8af3ce65b4cadde1aadb54190fa9e511e607d Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..0470b2744ac991e0f0b5dda809d8b6e9262c3465 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x64/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 39535 0 1248 40783 9f4f (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/libalgobsec.a new file mode 100644 index 0000000000000000000000000000000000000000..76716307829508221d7d9247c10398e8db93ee20 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/libalgobsec.a.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..d41744f408cd26aab0d541ede3c0fe4b3dbce9d4 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Linux/x86/libalgobsec.a.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 49266 0 1228 50494 c53e (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/libalgobsec.lib new file mode 100644 index 0000000000000000000000000000000000000000..32bb24e04f9a9abe74ac83325025784545a748cc Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/libalgobsec.lib.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..e3cda1b767b7ef535960ff02b3f2719b66d6699c --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x64/libalgobsec.lib.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 36120 0 1248 37368 91f8 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/bsec_interface.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/libalgobsec.lib b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/libalgobsec.lib new file mode 100644 index 0000000000000000000000000000000000000000..b3f8f82d8f7522f7d17ff13b619773d383c95964 Binary files /dev/null and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/libalgobsec.lib differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/libalgobsec.lib.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/libalgobsec.lib.Size.log new file mode 100644 index 0000000000000000000000000000000000000000..0a3defc176c8827ed364ee15f5cca8ab105a41d9 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/gcc/Windows/x86/libalgobsec.lib.Size.log @@ -0,0 +1,2 @@ + text data bss dec hex filename + 33512 0 1248 34760 87c8 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/libalgobsec.a b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/libalgobsec.a index 1b4e45534fe3ef977a61bff017345705207664dc..2da134d20dcc65c1992285cd97799202deaee36c 100644 Binary files a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/libalgobsec.a and b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/libalgobsec.a differ diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/libalgobsec.a.Size.log b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/libalgobsec.a.Size.log index 97d5bf2fe2dba2f245d7edc64554c31dfb909e1c..b53d3e273d68097be18097e3bef1f7f867f1edb8 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/libalgobsec.a.Size.log +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/bin/msp430-elf-gcc/libalgobsec.a.Size.log @@ -1,2 +1,2 @@ text data bss dec hex filename - 34180 0 1070 35250 89b2 (TOTALS) + 34916 0 1198 36114 8d12 (TOTALS) diff --git a/lib/vendor/Bosch/BSEC/algo/normal_version/inc/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/algo/normal_version/inc/bsec_datatypes.h index 7b45f7f2359c881f1c39d2a795615eda4c438554..535ed5d7c6fefac5eab6dfbf499569606e4875e0 100644 --- a/lib/vendor/Bosch/BSEC/algo/normal_version/inc/bsec_datatypes.h +++ b/lib/vendor/Bosch/BSEC/algo/normal_version/inc/bsec_datatypes.h @@ -90,6 +90,7 @@ extern "C" #define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ #define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ #define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ #define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ #define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ @@ -387,12 +388,12 @@ typedef struct * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as * follows: * - * | Name | Value | Accuracy description | - * |----------------------------|-------|-------------------------------------------------------------| - * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | - * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | - * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | - * | HIGH_ACCURACY | 3 | High accuracy | + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | * * For example: * @@ -409,12 +410,12 @@ typedef struct * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately * 30 minutes each. * - * | Virtual sensor | Value | Accuracy description | - * |----------------------------|-------|-----------------------------------------------------------------| - * | IAQ | 0 | The sensor is not yet stabilized or in a run-in status | - * | | 1 | Calibration required | - * | | 2 | Calibration on-going | - * | | 3 | Calibration is done, now IAQ estimate achieves best performance | + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | */ uint8_t accuracy; } bsec_output_t; diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_iaq.config b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_iaq.config index ba71808c56cc0b8083584688be8d61780cb42888..082ac1a94365ea25ba6acc8d0532eb2b2b24edb6 100644 Binary files a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_iaq.config and b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_iaq.config differ diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_iaq.csv b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_iaq.csv index 25f389c894112357c96d8ae31099a74ea6c020c6..f10200c35a9108d8218783f32c24f134e2b7f21d 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_iaq.csv +++ b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_iaq.csv @@ -1 +1 @@ -454,4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,133,135,0,0 +454,0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,226,227,0,0 diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_serialized_configurations_iaq.c b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_serialized_configurations_iaq.c index 2578ade4f3ef8927a18d3c48f28867b0de59fa68..17303fc76f7099cb02b40ef780f9e0c80a9d529b 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_serialized_configurations_iaq.c +++ b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_28d/bsec_serialized_configurations_iaq.c @@ -1,5 +1,5 @@ #include "bsec_serialized_configurations_iaq.h" const uint8_t bsec_config_iaq[454] = - {4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,133,135,0,0}; + {0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,226,227,0,0}; diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_iaq.config b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_iaq.config index 255edea35b6759a9ffe7c51345bb6b9227f2b756..317a9d0c5c34e955f6fe25d59b4e6825e4c5d9e7 100644 Binary files a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_iaq.config and b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_iaq.config differ diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_iaq.csv b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_iaq.csv index ec45f85341cee8fdd6704532f72a3593f3c3e59d..35b74a6d95980b0722507c9060d17bb7308face8 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_iaq.csv +++ b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_iaq.csv @@ -1 +1 @@ -454,4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,166,224,0,0 +454,0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,193,132,0,0 diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_serialized_configurations_iaq.c b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_serialized_configurations_iaq.c index 7a1b214fd929a833f04539ea8871a6a9836e744d..f742355fc3f872628a4df70df119fb895f4edc3d 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_serialized_configurations_iaq.c +++ b/lib/vendor/Bosch/BSEC/config/generic_18v_300s_4d/bsec_serialized_configurations_iaq.c @@ -1,5 +1,5 @@ #include "bsec_serialized_configurations_iaq.h" const uint8_t bsec_config_iaq[454] = - {4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,166,224,0,0}; + {0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,193,132,0,0}; diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_iaq.config b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_iaq.config index 0d0f06dc1182515cab969d5e9b323105ed481a91..caa3117bdbe60fbba13bb65fbe9578a8c670fbde 100644 Binary files a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_iaq.config and b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_iaq.config differ diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_iaq.csv b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_iaq.csv index 84c7e00fde7f4a8de53e6ac3ca3cface0fccdbd6..adbe7cea89ca6d22ae15a936d46748adc86d29d9 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_iaq.csv +++ b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_iaq.csv @@ -1 +1 @@ -454,4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,23,142,0,0 +454,0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,112,234,0,0 diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_serialized_configurations_iaq.c b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_serialized_configurations_iaq.c index 922c4fcee4921328e2406bd6a106e1e1ea107a25..30b91e8eb092796141b443029e9af3d688811334 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_serialized_configurations_iaq.c +++ b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_28d/bsec_serialized_configurations_iaq.c @@ -1,5 +1,5 @@ #include "bsec_serialized_configurations_iaq.h" const uint8_t bsec_config_iaq[454] = - {4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,23,142,0,0}; + {0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,112,234,0,0}; diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_iaq.config b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_iaq.config index 565ed67ff91fec461a4d709420411c0dd703a6ec..a398d41a009087052fa17b5a1a6cce196ff92c1b 100644 Binary files a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_iaq.config and b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_iaq.config differ diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_iaq.csv b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_iaq.csv index 9b52849a7472344248110e46953ae2f064dd44df..0bb4efe92c102519871955367f1a813ee7bf5ca3 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_iaq.csv +++ b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_iaq.csv @@ -1 +1 @@ -454,4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,52,233,0,0 +454,0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,83,141,0,0 diff --git a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_serialized_configurations_iaq.c b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_serialized_configurations_iaq.c index 62fc60ef251c9c156412082484f0389f5e94774b..c61e772611a69ca7808ef4ce6d2d190926011105 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_serialized_configurations_iaq.c +++ b/lib/vendor/Bosch/BSEC/config/generic_18v_3s_4d/bsec_serialized_configurations_iaq.c @@ -1,5 +1,5 @@ #include "bsec_serialized_configurations_iaq.h" const uint8_t bsec_config_iaq[454] = - {4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,52,233,0,0}; + {0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,7,240,150,61,0,0,0,0,0,0,0,0,28,124,225,61,52,128,215,63,0,0,160,64,0,0,0,0,0,0,0,0,205,204,12,62,103,213,39,62,230,63,76,192,0,0,0,0,0,0,0,0,145,237,60,191,251,58,64,63,177,80,131,64,0,0,0,0,0,0,0,0,93,254,227,62,54,60,133,191,0,0,64,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,83,141,0,0}; diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_iaq.config b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_iaq.config index 96fe3234ba08432765240858079e1c3051d632de..097d6d48229077efa350fe0ab1492e9167930d7b 100644 Binary files a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_iaq.config and b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_iaq.config differ diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_iaq.csv b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_iaq.csv index beb23ae105712bdf03c807e19b96d1cced6256e4..3fd045cf482173aca9e90ff206dc56cfe2a36923 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_iaq.csv +++ b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_iaq.csv @@ -1 +1 @@ -454,4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,59,62,0,0 +454,0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,92,90,0,0 diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_serialized_configurations_iaq.c b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_serialized_configurations_iaq.c index 17206d19d8082ed0b1d954d136233c84144e50e5..d650e0ae579a314151abecf7aa3dd8465c93f7bc 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_serialized_configurations_iaq.c +++ b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_28d/bsec_serialized_configurations_iaq.c @@ -1,5 +1,5 @@ #include "bsec_serialized_configurations_iaq.h" const uint8_t bsec_config_iaq[454] = - {4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,59,62,0,0}; + {0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,92,90,0,0}; diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_iaq.config b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_iaq.config index 7d181b0ccb8888c90475e93d8fb5d1697859c71b..f0d1c4ba391a760a3b868ba23916877abfc84e93 100644 Binary files a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_iaq.config and b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_iaq.config differ diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_iaq.csv b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_iaq.csv index 2e17310e4b917b20177b61f8845622084f520e5c..ea78598f69cc9bae51b088ea87dde89152f4f4e3 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_iaq.csv +++ b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_iaq.csv @@ -1 +1 @@ -454,4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,24,89,0,0 +454,0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,127,61,0,0 diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_serialized_configurations_iaq.c b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_serialized_configurations_iaq.c index a146e676539c0bb340478f665df9d398eaa6af64..534089038f0dc519f81bc288774665625d101754 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_serialized_configurations_iaq.c +++ b/lib/vendor/Bosch/BSEC/config/generic_33v_300s_4d/bsec_serialized_configurations_iaq.c @@ -1,5 +1,5 @@ #include "bsec_serialized_configurations_iaq.h" const uint8_t bsec_config_iaq[454] = - {4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,24,89,0,0}; + {0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,48,117,0,0,0,0,127,61,0,0}; diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_iaq.config b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_iaq.config index 82a58c2716e154dcf9eefc5fdda9cdda615a074b..f2ce16cc598a39e4429a1517f46a34a3050c8d83 100644 Binary files a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_iaq.config and b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_iaq.config differ diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_iaq.csv b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_iaq.csv index becd5d76150556363da8f8a4040e7a5bb3756d51..a7113d05d1e87b053ff9238b827d752721702290 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_iaq.csv +++ b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_iaq.csv @@ -1 +1 @@ -454,4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,169,55,0,0 +454,0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,206,83,0,0 diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_serialized_configurations_iaq.c b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_serialized_configurations_iaq.c index 4a76a130be1f71516c9226fec83fdf1e2cf0a537..a2f363427e6523868d0bf9fce8f519c8e93f8195 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_serialized_configurations_iaq.c +++ b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_28d/bsec_serialized_configurations_iaq.c @@ -1,5 +1,5 @@ #include "bsec_serialized_configurations_iaq.h" const uint8_t bsec_config_iaq[454] = - {4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,169,55,0,0}; + {0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,168,19,73,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,206,83,0,0}; diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_iaq.config b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_iaq.config index 4ebfbd45c12468cdef0bb525c8244a0466f293e6..d76ed0a0e8f4d14cd0086f8d826771548e3343fd 100644 Binary files a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_iaq.config and b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_iaq.config differ diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_iaq.csv b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_iaq.csv index 687e6fb32fe393a17729ca8373ac2364ba9f5753..02fd8d3a41ec3005542e47f64a3a6d030c97034e 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_iaq.csv +++ b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_iaq.csv @@ -1 +1 @@ -454,4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,138,80,0,0 +454,0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,237,52,0,0 diff --git a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_serialized_configurations_iaq.c b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_serialized_configurations_iaq.c index d53ae58ab91035353207ea090c282ee6547a947d..1f3c4acabc2022085bb36a890f069d97f87c8ec5 100644 --- a/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_serialized_configurations_iaq.c +++ b/lib/vendor/Bosch/BSEC/config/generic_33v_3s_4d/bsec_serialized_configurations_iaq.c @@ -1,5 +1,5 @@ #include "bsec_serialized_configurations_iaq.h" const uint8_t bsec_config_iaq[454] = - {4,7,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,63,205,204,204,62,0,0,64,63,205,204,204,62,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,138,80,0,0}; + {0,8,4,1,61,0,0,0,0,0,0,0,174,1,0,0,48,0,1,0,0,192,168,71,64,49,119,76,0,0,225,68,137,65,0,191,205,204,204,190,0,0,64,191,225,122,148,190,0,0,0,0,216,85,0,100,0,0,0,0,0,0,0,0,28,0,2,0,0,244,1,225,0,25,0,0,128,64,0,0,32,65,144,1,0,0,112,65,0,0,0,63,16,0,3,0,10,215,163,60,10,215,35,59,10,215,35,59,9,0,5,0,0,0,0,0,1,88,0,9,0,229,208,34,62,0,0,0,0,0,0,0,0,218,27,156,62,225,11,67,64,0,0,160,64,0,0,0,0,0,0,0,0,94,75,72,189,93,254,159,64,66,62,160,191,0,0,0,0,0,0,0,0,33,31,180,190,138,176,97,64,65,241,99,190,0,0,0,0,0,0,0,0,167,121,71,61,165,189,41,192,184,30,189,64,12,0,10,0,0,0,0,0,0,0,0,0,229,0,254,0,2,1,5,48,117,100,0,44,1,112,23,151,7,132,3,197,0,92,4,144,1,64,1,64,1,144,1,48,117,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,48,117,48,117,100,0,100,0,100,0,100,0,48,117,48,117,48,117,100,0,100,0,100,0,48,117,48,117,100,0,100,0,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,44,1,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,8,7,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,112,23,255,255,255,255,255,255,255,255,220,5,220,5,220,5,255,255,255,255,255,255,220,5,220,5,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,44,1,0,0,0,0,237,52,0,0}; diff --git a/lib/vendor/Bosch/BSEC/API/bme680.c b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bme680.c similarity index 92% rename from lib/vendor/Bosch/BSEC/API/bme680.c rename to lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bme680.c index ccd1bf89907c8931f7b2dbc7cf2bf401a8c6d8ee..5b138c0027ddc650ea0ee9892e1bb366ecc26b1e 100644 --- a/lib/vendor/Bosch/BSEC/API/bme680.c +++ b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bme680.c @@ -1,47 +1,38 @@ /**\mainpage - * Copyright (C) 2017 - 2018 Bosch Sensortec GmbH + * Copyright (c) 2020 Bosch Sensortec GmbH. All rights reserved. + * + * BSD-3-Clause * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * - * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. * - * Neither the name of the copyright holder nor the names of the - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND - * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL COPYRIGHT HOLDER - * OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, - * OR CONSEQUENTIAL DAMAGES(INCLUDING, BUT NOT LIMITED TO, - * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - * ANY WAY OUT OF THE USE OF THIS - * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE + * 3. Neither the name of the copyright holder nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. * - * The information provided is believed to be accurate and reliable. - * The copyright holder assumes no responsibility - * for the consequences of use - * of such information nor for any infringement of patents or - * other rights of third parties which may result from its use. - * No license is granted by implication or otherwise under any patent or - * patent rights of the copyright holder. + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING + * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. * * File bme680.c - * @date 19 Jun 2018 - * @version 3.5.9 + * @date 23 Jan 2020 + * @version 3.5.10 * */ diff --git a/lib/vendor/Bosch/BSEC/API/bme680.h b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bme680.h similarity index 75% rename from lib/vendor/Bosch/BSEC/API/bme680.h rename to lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bme680.h index 8274a8e385e0136430f11f7a799acdb801059b5f..f436215a3471b0eb43d6f1c9e11aceca538cb6aa 100644 --- a/lib/vendor/Bosch/BSEC/API/bme680.h +++ b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bme680.h @@ -1,47 +1,38 @@ /** - * Copyright (C) 2017 - 2018 Bosch Sensortec GmbH + * Copyright (c) 2020 Bosch Sensortec GmbH. All rights reserved. + * + * BSD-3-Clause * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * - * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * Neither the name of the copyright holder nor the names of the - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND - * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL COPYRIGHT HOLDER - * OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, - * OR CONSEQUENTIAL DAMAGES(INCLUDING, BUT NOT LIMITED TO, - * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - * ANY WAY OUT OF THE USE OF THIS - * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE - * - * The information provided is believed to be accurate and reliable. - * The copyright holder assumes no responsibility - * for the consequences of use - * of such information nor for any infringement of patents or - * other rights of third parties which may result from its use. - * No license is granted by implication or otherwise under any patent or - * patent rights of the copyright holder. + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * 3. Neither the name of the copyright holder nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING + * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. * * @file bme680.h - * @date 19 Jun 2018 - * @version 3.5.9 + * @date 23 Jan 2020 + * @version 3.5.10 * @brief * */ diff --git a/lib/vendor/Bosch/BSEC/API/bme680_defs.h b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bme680_defs.h similarity index 86% rename from lib/vendor/Bosch/BSEC/API/bme680_defs.h rename to lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bme680_defs.h index b7c52d8bfb664cff7202010e74cf92c7be46bd51..429775d74f49c63f6e0e1a62a1343c12ac68ba69 100644 --- a/lib/vendor/Bosch/BSEC/API/bme680_defs.h +++ b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bme680_defs.h @@ -1,47 +1,38 @@ /** - * Copyright (C) 2017 - 2018 Bosch Sensortec GmbH + * Copyright (c) 2020 Bosch Sensortec GmbH. All rights reserved. + * + * BSD-3-Clause * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * - * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. * - * Neither the name of the copyright holder nor the names of the - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND - * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL COPYRIGHT HOLDER - * OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, - * OR CONSEQUENTIAL DAMAGES(INCLUDING, BUT NOT LIMITED TO, - * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - * ANY WAY OUT OF THE USE OF THIS - * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE + * 3. Neither the name of the copyright holder nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. * - * The information provided is believed to be accurate and reliable. - * The copyright holder assumes no responsibility - * for the consequences of use - * of such information nor for any infringement of patents or - * other rights of third parties which may result from its use. - * No license is granted by implication or otherwise under any patent or - * patent rights of the copyright holder. + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING + * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. * * @file bme680_defs.h - * @date 19 Jun 2018 - * @version 3.5.9 + * @date 23 Jan 2020 + * @version 3.5.10 * @brief * */ diff --git a/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_datatypes.h b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_datatypes.h new file mode 100644 index 0000000000000000000000000000000000000000..535ed5d7c6fefac5eab6dfbf499569606e4875e0 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_datatypes.h @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + + /** + * @file bsec_datatypes.h + * + * @brief + * Contains the data types used by BSEC + * + */ + +#ifndef __BSEC_DATATYPES_H__ +#define __BSEC_DATATYPES_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +/*! + * @addtogroup bsec_interface BSEC C Interface + * @{*/ + +#ifdef __KERNEL__ +#include <linux/types.h> +#endif +#include <stdint.h> +#include <stddef.h> + +#define BSEC_MAX_WORKBUFFER_SIZE (2048) /*!< Maximum size (in bytes) of the work buffer */ +#define BSEC_MAX_PHYSICAL_SENSOR (8) /*!< Number of physical sensors that need allocated space before calling bsec_update_subscription() */ +#define BSEC_MAX_PROPERTY_BLOB_SIZE (454) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_configuration() */ +#define BSEC_MAX_STATE_BLOB_SIZE (139) /*!< Maximum size (in bytes) of the data blobs returned by bsec_get_state()*/ +#define BSEC_SAMPLE_RATE_DISABLED (65535.0f) /*!< Sample rate of a disabled sensor */ +#define BSEC_SAMPLE_RATE_ULP (0.0033333f) /*!< Sample rate in case of Ultra Low Power Mode */ +#define BSEC_SAMPLE_RATE_CONTINUOUS (1.0f) /*!< Sample rate in case of Continuous Mode */ +#define BSEC_SAMPLE_RATE_LP (0.33333f) /*!< Sample rate in case of Low Power Mode */ +#define BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND (0.0f) /*!< Input value used to trigger an extra measurment (ULP plus) */ + +#define BSEC_PROCESS_PRESSURE (1 << (BSEC_INPUT_PRESSURE-1)) /*!< process_data bitfield constant for pressure @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_TEMPERATURE (1 << (BSEC_INPUT_TEMPERATURE-1)) /*!< process_data bitfield constant for temperature @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_HUMIDITY (1 << (BSEC_INPUT_HUMIDITY-1)) /*!< process_data bitfield constant for humidity @sa bsec_bme_settings_t */ +#define BSEC_PROCESS_GAS (1 << (BSEC_INPUT_GASRESISTOR-1)) /*!< process_data bitfield constant for gas sensor @sa bsec_bme_settings_t */ +#define BSEC_NUMBER_OUTPUTS (14) /*!< Number of outputs, depending on solution */ +#define BSEC_OUTPUT_INCLUDED (1210863) /*!< bitfield that indicates which outputs are included in the solution */ + +/*! + * @brief Enumeration for input (physical) sensors. + * + * Used to populate bsec_input_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * returned in the parameter required_sensor_settings of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_input_t + */ +typedef enum +{ + /** + * @brief Pressure sensor output of BMExxx [Pa] + */ + BSEC_INPUT_PRESSURE = 1, + + /** + * @brief Humidity sensor output of BMExxx [%] + * + * @note Relative humidity strongly depends on the temperature (it is measured at). It may require a conversion to + * the temperature outside of the device. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HUMIDITY = 2, + + /** + * @brief Temperature sensor output of BMExxx [degrees Celsius] + * + * @note The BME680 is factory trimmed, thus the temperature sensor of the BME680 is very accurate. + * The temperature value is a very local measurement value and can be influenced by external heat sources. + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_TEMPERATURE = 3, + + /** + * @brief Gas sensor resistance output of BMExxx [Ohm] + * + * The resistance value changes due to varying VOC concentrations (the higher the concentration of reducing VOCs, + * the lower the resistance and vice versa). + */ + BSEC_INPUT_GASRESISTOR = 4, /*!< */ + + /** + * @brief Additional input for device heat compensation + * + * IAQ solution: The value is subtracted from ::BSEC_INPUT_TEMPERATURE to compute + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * ALL solution: Generic heat source 1 + * + * @sa bsec_virtual_sensor_t + */ + BSEC_INPUT_HEATSOURCE = 14, + + /** + * @brief Additional input for device heat compensation 8 + * + * Generic heat source 8 + */ + + + /** + * @brief Additional input that disables baseline tracker + * + * 0 - Normal + * 1 - Event 1 + * 2 - Event 2 + */ + BSEC_INPUT_DISABLE_BASELINE_TRACKER = 23, + +} bsec_physical_sensor_t; + +/*! + * @brief Enumeration for output (virtual) sensors + * + * Used to populate bsec_output_t::sensor_id. It is also used in bsec_sensor_configuration_t::sensor_id structs + * passed in the parameter requested_virtual_sensors of bsec_update_subscription(). + * + * @sa bsec_sensor_configuration_t @sa bsec_output_t + */ +typedef enum +{ + /** + * @brief Indoor-air-quality estimate [0-500] + * + * Indoor-air-quality (IAQ) gives an indication of the relative change in ambient TVOCs detected by BME680. + * + * @note The IAQ scale ranges from 0 (clean air) to 500 (heavily polluted air). During operation, algorithms + * automatically calibrate and adapt themselves to the typical environments where the sensor is operated + * (e.g., home, workplace, inside a car, etc.).This automatic background calibration ensures that users experience + * consistent IAQ performance. The calibration process considers the recent measurement history (typ. up to four + * days) to ensure that IAQ=25 corresponds to typical good air and IAQ=250 indicates typical polluted air. + */ + BSEC_OUTPUT_IAQ = 1, + BSEC_OUTPUT_STATIC_IAQ = 2, /*!< Unscaled indoor-air-quality estimate */ + BSEC_OUTPUT_CO2_EQUIVALENT = 3, /*!< co2 equivalent estimate [ppm] */ + BSEC_OUTPUT_BREATH_VOC_EQUIVALENT = 4, /*!< breath VOC concentration estimate [ppm] */ + + /** + * @brief Temperature sensor signal [degrees Celsius] + * + * Temperature directly measured by BME680 in degree Celsius. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_TEMPERATURE = 6, + + /** + * @brief Pressure sensor signal [Pa] + * + * Pressure directly measured by the BME680 in Pa. + */ + BSEC_OUTPUT_RAW_PRESSURE = 7, + + /** + * @brief Relative humidity sensor signal [%] + * + * Relative humidity directly measured by the BME680 in %. + * + * @note This value is cross-influenced by the sensor heating and device specific heating. + */ + BSEC_OUTPUT_RAW_HUMIDITY = 8, + + /** + * @brief Gas sensor signal [Ohm] + * + * Gas resistance measured directly by the BME680 in Ohm.The resistance value changes due to varying VOC + * concentrations (the higher the concentration of reducing VOCs, the lower the resistance and vice versa). + */ + BSEC_OUTPUT_RAW_GAS = 9, + + /** + * @brief Gas sensor stabilization status [boolean] + * + * Indicates initial stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_STABILIZATION_STATUS = 12, + + /** + * @brief Gas sensor run-in status [boolean] + * + * Indicates power-on stabilization status of the gas sensor element: stabilization is ongoing (0) or stabilization + * is finished (1). + */ + BSEC_OUTPUT_RUN_IN_STATUS = 13, + + /** + * @brief Sensor heat compensated temperature [degrees Celsius] + * + * Temperature measured by BME680 which is compensated for the influence of sensor (heater) in degree Celsius. + * The self heating introduced by the heater is depending on the sensor operation mode and the sensor supply voltage. + * + * + * @note IAQ solution: In addition, the temperature output can be compensated by an user defined value + * (::BSEC_INPUT_HEATSOURCE in degrees Celsius), which represents the device specific self-heating. + * + * Thus, the value is calculated as follows: + * * IAQ solution: ```BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage) - ::BSEC_INPUT_HEATSOURCE``` + * * other solutions: ```::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = ::BSEC_INPUT_TEMPERATURE - function(sensor operation mode, sensor supply voltage)``` + * + * The self-heating in operation mode BSEC_SAMPLE_RATE_ULP is negligible. + * The self-heating in operation mode BSEC_SAMPLE_RATE_LP is supported for 1.8V by default (no config file required). If the BME680 sensor supply voltage is 3.3V, the IoT_LP_3_3V.config shall be used. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE = 14, + + /** + * @brief Sensor heat compensated humidity [%] + * + * Relative measured by BME680 which is compensated for the influence of sensor (heater) in %. + * + * It converts the ::BSEC_INPUT_HUMIDITY from temperature ::BSEC_INPUT_TEMPERATURE to temperature + * ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE. + * + * @note IAQ solution: If ::BSEC_INPUT_HEATSOURCE is used for device specific temperature compensation, it will be + * effective for ::BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY too. + */ + BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY = 15, + + BSEC_OUTPUT_COMPENSATED_GAS = 18, /*!< Reserved internal debug output */ + BSEC_OUTPUT_GAS_PERCENTAGE = 21 /*!< percentage of min and max filtered gas value [%] */ +} bsec_virtual_sensor_t; + +/*! + * @brief Enumeration for function return codes + */ +typedef enum +{ + BSEC_OK = 0, /*!< Function execution successful */ + BSEC_E_DOSTEPS_INVALIDINPUT = -1, /*!< Input (physical) sensor id passed to bsec_do_steps() is not in the valid range or not valid for requested virtual sensor */ + BSEC_E_DOSTEPS_VALUELIMITS = -2, /*!< Value of input (physical) sensor signal passed to bsec_do_steps() is not in the valid range */ + BSEC_E_DOSTEPS_DUPLICATEINPUT = -6, /*!< Duplicate input (physical) sensor ids passed as input to bsec_do_steps() */ + BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE = 2, /*!< No memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs == 0 */ + BSEC_W_DOSTEPS_EXCESSOUTPUTS = 3, /*!< Not enough memory allocated to hold return values from bsec_do_steps(), i.e., n_outputs < maximum number of requested output (virtual) sensors */ + BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE = 4, /*!< Duplicate timestamps passed to bsec_do_steps() */ + BSEC_E_SU_WRONGDATARATE = -10, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is zero */ + BSEC_E_SU_SAMPLERATELIMITS = -12, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not match with the sampling rate allowed for that sensor */ + BSEC_E_SU_DUPLICATEGATE = -13, /*!< Duplicate output (virtual) sensor ids requested through bsec_update_subscription() */ + BSEC_E_SU_INVALIDSAMPLERATE = -14, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() does not fall within the global minimum and maximum sampling rates */ + BSEC_E_SU_GATECOUNTEXCEEDSARRAY = -15, /*!< Not enough memory allocated to hold returned input (physical) sensor data from bsec_update_subscription(), i.e., n_required_sensor_settings < #BSEC_MAX_PHYSICAL_SENSOR */ + BSEC_E_SU_SAMPLINTVLINTEGERMULT = -16, /*!< The sample_rate of the requested output (virtual) sensor passed to bsec_update_subscription() is not correct */ + BSEC_E_SU_MULTGASSAMPLINTVL = -17, /*!< The sample_rate of the requested output (virtual), which requires the gas sensor, is not equal to the sample_rate that the gas sensor is being operated */ + BSEC_E_SU_HIGHHEATERONDURATION = -18, /*!< The duration of one measurement is longer than the requested sampling interval */ + BSEC_W_SU_UNKNOWNOUTPUTGATE = 10, /*!< Output (virtual) sensor id passed to bsec_update_subscription() is not in the valid range; e.g., n_requested_virtual_sensors > actual number of output (virtual) sensors requested */ + BSEC_W_SU_MODINNOULP = 11, /*!< ULP plus can not be requested in non-ulp mode */ /*MOD_ONLY*/ + BSEC_I_SU_SUBSCRIBEDOUTPUTGATES = 12, /*!< No output (virtual) sensor data were requested via bsec_update_subscription() */ + BSEC_E_PARSE_SECTIONEXCEEDSWORKBUFFER = -32, /*!< n_work_buffer_size passed to bsec_set_[configuration/state]() not sufficient */ + BSEC_E_CONFIG_FAIL = -33, /*!< Configuration failed */ + BSEC_E_CONFIG_VERSIONMISMATCH = -34, /*!< Version encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current version */ + BSEC_E_CONFIG_FEATUREMISMATCH = -35, /*!< Enabled features encoded in serialized_[settings/state] passed to bsec_set_[configuration/state]() does not match with current library implementation */ + BSEC_E_CONFIG_CRCMISMATCH = -36, /*!< serialized_[settings/state] passed to bsec_set_[configuration/state]() is corrupted */ + BSEC_E_CONFIG_EMPTY = -37, /*!< n_serialized_[settings/state] passed to bsec_set_[configuration/state]() is to short to be valid */ + BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER = -38, /*!< Provided work_buffer is not large enough to hold the desired string */ + BSEC_E_CONFIG_INVALIDSTRINGSIZE = -40, /*!< String size encoded in configuration/state strings passed to bsec_set_[configuration/state]() does not match with the actual string size n_serialized_[settings/state] passed to these functions */ + BSEC_E_CONFIG_INSUFFICIENTBUFFER = -41, /*!< String buffer insufficient to hold serialized data from BSEC library */ + BSEC_E_SET_INVALIDCHANNELIDENTIFIER = -100, /*!< Internal error code, size of work buffer in setConfig must be set to BSEC_MAX_WORKBUFFER_SIZE */ + BSEC_E_SET_INVALIDLENGTH = -104, /*!< Internal error code */ + BSEC_W_SC_CALL_TIMING_VIOLATION = 100, /*!< Difference between actual and defined sampling intervals of bsec_sensor_control() greater than allowed */ + BSEC_W_SC_MODEXCEEDULPTIMELIMIT = 101, /*!< ULP plus is not allowed because an ULP measurement just took or will take place */ /*MOD_ONLY*/ + BSEC_W_SC_MODINSUFFICIENTWAITTIME = 102 /*!< ULP plus is not allowed because not sufficient time passed since last ULP plus */ /*MOD_ONLY*/ +} bsec_library_return_t; + +/*! + * @brief Structure containing the version information + * + * Please note that configuration and state strings are coded to a specific version and will not be accepted by other + * versions of BSEC. + * + */ +typedef struct +{ + uint8_t major; /**< @brief Major version */ + uint8_t minor; /**< @brief Minor version */ + uint8_t major_bugfix; /**< @brief Major bug fix version */ + uint8_t minor_bugfix; /**< @brief Minor bug fix version */ +} bsec_version_t; + +/*! + * @brief Structure describing an input sample to the library + * + * Each input sample is provided to BSEC as an element in a struct array of this type. Timestamps must be provided + * in nanosecond resolution. Moreover, duplicate timestamps for subsequent samples are not allowed and will results in + * an error code being returned from bsec_do_steps(). + * + * The meaning unit of the signal field are determined by the bsec_input_t::sensor_id field content. Possible + * bsec_input_t::sensor_id values and and their meaning are described in ::bsec_physical_sensor_t. + * + * @sa bsec_physical_sensor_t + * + */ +typedef struct +{ + /** + * @brief Time stamp in nanosecond resolution [ns] + * + * Timestamps must be provided as non-repeating and increasing values. They can have their 0-points at system start or + * at a defined wall-clock time (e.g., 01-Jan-1970 00:00:00) + */ + int64_t time_stamp; + float signal; /*!< @brief Signal sample in the unit defined for the respective sensor_id @sa bsec_physical_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of physical sensor @sa bsec_physical_sensor_t */ +} bsec_input_t; + +/*! + * @brief Structure describing an output sample of the library + * + * Each output sample is returned from BSEC by populating the element of a struct array of this type. The contents of + * the signal field is defined by the supplied bsec_output_t::sensor_id. Possible output + * bsec_output_t::sensor_id values are defined in ::bsec_virtual_sensor_t. + * + * @sa bsec_virtual_sensor_t + */ +typedef struct +{ + int64_t time_stamp; /*!< @brief Time stamp in nanosecond resolution as provided as input [ns] */ + float signal; /*!< @brief Signal sample in the unit defined for the respective bsec_output_t::sensor_id @sa bsec_virtual_sensor_t */ + uint8_t signal_dimensions; /*!< @brief Signal dimensions (reserved for future use, shall be set to 1) */ + uint8_t sensor_id; /*!< @brief Identifier of virtual sensor @sa bsec_virtual_sensor_t */ + + /** + * @brief Accuracy status 0-3 + * + * Some virtual sensors provide a value in the accuracy field. If this is the case, the meaning of the field is as + * follows: + * + * | Name | Value | Accuracy description | + * |----------------------------|-------|-------------------------------------------------------------------------------------------------------------| + * | UNRELIABLE | 0 | Sensor data is unreliable, the sensor must be calibrated | + * | LOW_ACCURACY | 1 | Low accuracy, sensor should be calibrated | + * | MEDIUM_ACCURACY | 2 | Medium accuracy, sensor calibration may improve performance | + * | HIGH_ACCURACY | 3 | High accuracy | + * + * For example: + * + * - Ambient temperature accuracy is derived from change in the temperature in 1 minute. + * + * | Virtual sensor | Value | Accuracy description | + * |--------------------- |-------|------------------------------------------------------------------------------| + * | Ambient temperature | 0 | The difference in ambient temperature is greater than 4 degree in one minute | + * | | 1 | The difference in ambient temperature is less than 4 degree in one minute | + * | | 2 | The difference in ambient temperature is less than 3 degree in one minute | + * | | 3 | The difference in ambient temperature is less than 2 degree in one minute | + * + * - IAQ accuracy indicator will notify the user when she/he should initiate a calibration process. Calibration is + * performed automatically in the background if the sensor is exposed to clean and polluted air for approximately + * 30 minutes each. + * + * | Virtual sensor | Value | Accuracy description | + * |----------------------------|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------| + * | IAQ | 0 | Stabilization / run-in ongoing | + * | | 1 | Low accuracy,to reach high accuracy(3),please expose sensor once to good air (e.g. outdoor air) and bad air (e.g. box with exhaled breath) for auto-trimming | + * | | 2 | Medium accuracy: auto-trimming ongoing | + * | | 3 | High accuracy | + */ + uint8_t accuracy; +} bsec_output_t; + +/*! + * @brief Structure describing sample rate of physical/virtual sensors + * + * This structure is used together with bsec_update_subscription() to enable BSEC outputs and to retrieve information + * about the sample rates used for BSEC inputs. + */ +typedef struct +{ + /** + * @brief Sample rate of the virtual or physical sensor in Hertz [Hz] + * + * Only supported sample rates are allowed. + */ + float sample_rate; + + /** + * @brief Identifier of the virtual or physical sensor + * + * The meaning of this field changes depending on whether the structs are as the requested_virtual_sensors argument + * to bsec_update_subscription() or as the required_sensor_settings argument. + * + * | bsec_update_subscription() argument | sensor_id field interpretation | + * |-------------------------------------|--------------------------------| + * | requested_virtual_sensors | ::bsec_virtual_sensor_t | + * | required_sensor_settings | ::bsec_physical_sensor_t | + * + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + */ + uint8_t sensor_id; +} bsec_sensor_configuration_t; + +/*! + * @brief Structure returned by bsec_sensor_control() to configure BMExxx sensor + * + * This structure contains settings that must be used to configure the BMExxx to perform a forced-mode measurement. + * A measurement should only be executed if bsec_bme_settings_t::trigger_measurement is 1. If so, the oversampling + * settings for temperature, humidity, and pressure should be set to the provided settings provided in + * bsec_bme_settings_t::temperature_oversampling, bsec_bme_settings_t::humidity_oversampling, and + * bsec_bme_settings_t::pressure_oversampling, respectively. + * + * In case of bsec_bme_settings_t::run_gas = 1, the gas sensor must be enabled with the provided + * bsec_bme_settings_t::heater_temperature and bsec_bme_settings_t::heating_duration settings. + */ +typedef struct +{ + int64_t next_call; /*!< @brief Time stamp of the next call of the sensor_control*/ + uint32_t process_data; /*!< @brief Bit field describing which data is to be passed to bsec_do_steps() @sa BSEC_PROCESS_* */ + uint16_t heater_temperature; /*!< @brief Heating temperature [degrees Celsius] */ + uint16_t heating_duration; /*!< @brief Heating duration [ms] */ + uint8_t run_gas; /*!< @brief Enable gas measurements [0/1] */ + uint8_t pressure_oversampling; /*!< @brief Pressure oversampling settings [0-5] */ + uint8_t temperature_oversampling; /*!< @brief Temperature oversampling settings [0-5] */ + uint8_t humidity_oversampling; /*!< @brief Humidity oversampling settings [0-5] */ + uint8_t trigger_measurement; /*!< @brief Trigger a forced measurement with these settings now [0/1] */ +} bsec_bme_settings_t; + +/* internal defines and backward compatibility */ +#define BSEC_STRUCT_NAME Bsec /*!< Internal struct name */ + +/*@}*/ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/lib/vendor/Bosch/BSEC/examples/bsec_integration.c b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_integration.c similarity index 92% rename from lib/vendor/Bosch/BSEC/examples/bsec_integration.c rename to lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_integration.c index c00db62cb9e956e5e7225345bc7500d5432788c6..74fbd583008d812d5237fc6b346e49579e7090ab 100644 --- a/lib/vendor/Bosch/BSEC/examples/bsec_integration.c +++ b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_integration.c @@ -84,7 +84,7 @@ /* local macro definitions */ /**********************************************************************************************************************/ -#define NUM_USED_OUTPUTS 10 +#define NUM_USED_OUTPUTS 8 /**********************************************************************************************************************/ /* global variable declarations */ @@ -135,10 +135,6 @@ static bsec_library_return_t bme680_bsec_update_subscription(float sample_rate) requested_virtual_sensors[6].sample_rate = sample_rate; requested_virtual_sensors[7].sensor_id = BSEC_OUTPUT_STATIC_IAQ; requested_virtual_sensors[7].sample_rate = sample_rate; - requested_virtual_sensors[8].sensor_id = BSEC_OUTPUT_CO2_EQUIVALENT; - requested_virtual_sensors[8].sample_rate = sample_rate; - requested_virtual_sensors[9].sensor_id = BSEC_OUTPUT_BREATH_VOC_EQUIVALENT; - requested_virtual_sensors[9].sample_rate = sample_rate; /* Call bsec_update_subscription() to enable/disable the requested virtual sensors */ status = bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, @@ -164,10 +160,11 @@ return_values_init bsec_iot_init(float sample_rate, float temperature_offset, bm bme680_com_fptr_t bus_read, sleep_fct sleep, state_load_fct state_load, config_load_fct config_load) { return_values_init ret = {BME680_OK, BSEC_OK}; - __attribute__((unused)) bsec_library_return_t bsec_status = BSEC_OK; + bsec_library_return_t bsec_status = BSEC_OK; - uint8_t bsec_data[BSEC_MAX_PROPERTY_BLOB_SIZE] = {0}; - uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE] = {0}; + uint8_t bsec_state[BSEC_MAX_STATE_BLOB_SIZE] = {0}; + uint8_t bsec_config[BSEC_MAX_PROPERTY_BLOB_SIZE] = {0}; + uint8_t work_buffer[BSEC_MAX_WORKBUFFER_SIZE] = {0}; int bsec_state_len, bsec_config_len; /* Fixed I2C configuration */ @@ -193,10 +190,10 @@ return_values_init bsec_iot_init(float sample_rate, float temperature_offset, bm } /* Load library config, if available */ - bsec_config_len = config_load(bsec_data, sizeof(bsec_data)); + bsec_config_len = config_load(bsec_config, sizeof(bsec_config)); if (bsec_config_len != 0) { - ret.bsec_status = bsec_set_configuration(bsec_data, bsec_config_len, work_buffer, sizeof(work_buffer)); + ret.bsec_status = bsec_set_configuration(bsec_config, bsec_config_len, work_buffer, sizeof(work_buffer)); if (ret.bsec_status != BSEC_OK) { return ret; @@ -204,10 +201,10 @@ return_values_init bsec_iot_init(float sample_rate, float temperature_offset, bm } /* Load previous library state, if available */ - bsec_state_len = state_load(bsec_data, sizeof(bsec_data)); + bsec_state_len = state_load(bsec_state, sizeof(bsec_state)); if (bsec_state_len != 0) { - ret.bsec_status = bsec_set_state(bsec_data, bsec_state_len, work_buffer, sizeof(work_buffer)); + ret.bsec_status = bsec_set_state(bsec_state, bsec_state_len, work_buffer, sizeof(work_buffer)); if (ret.bsec_status != BSEC_OK) { return ret; @@ -239,7 +236,7 @@ static void bme680_bsec_trigger_measurement(bsec_bme_settings_t *sensor_settings { uint16_t meas_period; uint8_t set_required_settings; - __attribute__((unused)) int8_t bme680_status = BME680_OK; + int8_t bme680_status = BME680_OK; /* Check if a forced-mode measurement should be triggered now */ if (sensor_settings->trigger_measurement) @@ -299,7 +296,7 @@ static void bme680_bsec_read_data(int64_t time_stamp_trigger, bsec_input_t *inpu int32_t bsec_process_data) { static struct bme680_field_data data; - __attribute__((unused)) int8_t bme680_status = BME680_OK; + int8_t bme680_status = BME680_OK; /* We only have to read data if the previous call the bsec_sensor_control() actually asked for it */ if (bsec_process_data) @@ -395,15 +392,15 @@ static void bme680_bsec_process_data(bsec_input_t *bsec_inputs, uint8_t num_bsec float raw_humidity = 0.0f; float raw_gas = 0.0f; float static_iaq = 0.0f; - __attribute__((unused)) uint8_t static_iaq_accuracy = 0; + uint8_t static_iaq_accuracy = 0; float co2_equivalent = 0.0f; - __attribute__((unused)) uint8_t co2_accuracy = 0; + uint8_t co2_accuracy = 0; float breath_voc_equivalent = 0.0f; - __attribute__((unused)) uint8_t breath_voc_accuracy = 0; - __attribute__((unused)) float comp_gas_value = 0.0f; - __attribute__((unused)) uint8_t comp_gas_accuracy = 0; - __attribute__((unused)) float gas_percentage = 0.0f; - __attribute__((unused)) uint8_t gas_percentage_acccuracy = 0; + uint8_t breath_voc_accuracy = 0; + float comp_gas_value = 0.0f; + uint8_t comp_gas_accuracy = 0; + float gas_percentage = 0.0f; + uint8_t gas_percentage_acccuracy = 0; /* Check if something should be processed by BSEC */ if (num_bsec_inputs > 0) @@ -509,7 +506,7 @@ void bsec_iot_loop(sleep_fct sleep, get_timestamp_us_fct get_timestamp_us, outpu /* Save state variables */ uint8_t bsec_state[BSEC_MAX_STATE_BLOB_SIZE]; - uint8_t work_buffer[BSEC_MAX_STATE_BLOB_SIZE]; + uint8_t work_buffer[BSEC_MAX_WORKBUFFER_SIZE]; uint32_t bsec_state_len = 0; uint32_t n_samples = 0; diff --git a/lib/vendor/Bosch/BSEC/examples/bsec_integration.h b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_integration.h similarity index 100% rename from lib/vendor/Bosch/BSEC/examples/bsec_integration.h rename to lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_integration.h diff --git a/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_interface.h b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_interface.h new file mode 100644 index 0000000000000000000000000000000000000000..d6c09a392958a326a5553bf2c5bbb4afa2d0cedc --- /dev/null +++ b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_interface.h @@ -0,0 +1,564 @@ +/* + * Copyright (C) 2015, 2016, 2017 Robert Bosch. All Rights Reserved. + * + * Disclaimer + * + * Common: + * Bosch Sensortec products are developed for the consumer goods industry. They may only be used + * within the parameters of the respective valid product data sheet. Bosch Sensortec products are + * provided with the express understanding that there is no warranty of fitness for a particular purpose. + * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device + * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, + * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. + * The resale and/or use of products are at the purchasers own risk and his own responsibility. The + * examination of fitness for the intended use is the sole responsibility of the Purchaser. + * + * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for + * incidental, or consequential damages, arising from any product use not covered by the parameters of + * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch + * Sensortec for all costs in connection with such claims. + * + * The purchaser must monitor the market for the purchased products, particularly with regard to + * product safety and inform Bosch Sensortec without delay of all security relevant incidents. + * + * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid + * technical specifications of the product series. They are therefore not intended or fit for resale to third + * parties or for use in end products. Their sole purpose is internal client testing. The testing of an + * engineering sample may in no way replace the testing of a product series. Bosch Sensortec + * assumes no liability for the use of engineering samples. By accepting the engineering samples, the + * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering + * samples. + * + * Special: + * This software module (hereinafter called "Software") and any information on application-sheets + * (hereinafter called "Information") is provided free of charge for the sole purpose to support your + * application work. The Software and Information is subject to the following terms and conditions: + * + * The Software is specifically designed for the exclusive use for Bosch Sensortec products by + * personnel who have special experience and training. Do not use this Software if you do not have the + * proper experience or training. + * + * This Software package is provided `` as is `` and without any expressed or implied warranties, + * including without limitation, the implied warranties of merchantability and fitness for a particular + * purpose. + * + * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment + * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their + * representatives and agents shall not be liable for any direct or indirect damages or injury, except as + * otherwise stipulated in mandatory applicable law. + * + * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no + * responsibility for the consequences of use of such Information nor for any infringement of patents or + * other rights of third parties which may result from its use. No license is granted by implication or + * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are + * subject to change without notice. + * + * It is not allowed to deliver the source code of the Software to any third party without permission of + * Bosch Sensortec. + * + */ + /*! + * + * @file bsec_interface.h + * + * @brief + * Contains the API for BSEC + * + */ + + +#ifndef __BSEC_INTERFACE_H__ +#define __BSEC_INTERFACE_H__ + +#include "bsec_datatypes.h" + +#ifdef __cplusplus + extern "C" { +#endif + + + /*! @addtogroup bsec_interface BSEC C Interface + * @brief Interfaces of BSEC signal processing library + * + * ### Interface usage + * + * The following provides a short overview on the typical operation sequence for BSEC. + * + * - Initialization of the library + * + * | Steps | Function | + * |---------------------------------------------------------------------|--------------------------| + * | Initialization of library | bsec_init() | + * | Update configuration settings (optional) | bsec_set_configuration() | + * | Restore the state of the library (optional) | bsec_set_state() | + * + * + * - The following function is called to enable output signals and define their sampling rate / operation mode. + * + * | Steps | Function | + * |---------------------------------------------|----------------------------| + * | Enable library outputs with specified mode | bsec_update_subscription() | + * + * + * - This table describes the main processing loop. + * + * | Steps | Function | + * |-------------------------------------------|----------------------------------| + * | Retrieve sensor settings to be used | bsec_sensor_control() | + * | Configure sensor and trigger measurement | See BME680 API and example codes | + * | Read results from sensor | See BME680 API and example codes | + * | Perform signal processing | bsec_do_steps() | + * + * + * - Before shutting down the system, the current state of BSEC can be retrieved and can then be used during + * re-initialization to continue processing. + * + * | Steps | Function | + * |----------------------------------------|-------------------| + * | To retrieve the current library state | bsec_get_state() | + * + * + * + * ### Configuration and state + * + * Values of variables belonging to a BSEC instance are divided into two groups: + * - Values **not updated by processing** of signals belong to the **configuration group**. If available, BSEC can be + * configured before use with a customer specific configuration string. + * - Values **updated during processing** are member of the **state group**. Saving and restoring of the state of BSEC + * is necessary to maintain previously estimated sensor models and baseline information which is important for best + * performance of the gas sensor outputs. + * + * @note BSEC library consists of adaptive algorithms which models the gas sensor which improves its performance over + * the time. These will be lost if library is initialized due to system reset. In order to avoid this situation + * library state shall be stored in non volatile memory so that it can be loaded after system reset. + * + * + * @{ + */ + + +/*! + * @brief Return the version information of BSEC library + * + * @param [out] bsec_version_p pointer to struct which is to be populated with the version information + * + * @return Zero if successful, otherwise an error code + * + * See also: bsec_version_t + * + \code{.c} + // Example // + bsec_version_t version; + bsec_get_version(&version); + printf("BSEC version: %d.%d.%d.%d",version.major, version.minor, version.major_bugfix, version.minor_bugfix); + + \endcode +*/ + +bsec_library_return_t bsec_get_version(bsec_version_t * bsec_version_p); + + +/*! + * @brief Initialize the library + * + * Initialization and reset of BSEC is performed by calling bsec_init(). Calling this function sets up the relation + * among all internal modules, initializes run-time dependent library states and resets the configuration and state + * of all BSEC signal processing modules to defaults. + * + * Before any further use, the library must be initialized. This ensure that all memory and states are in defined + * conditions prior to processing any data. + * + * @return Zero if successful, otherwise an error code + * + \code{.c} + + // Initialize BSEC library before further use + bsec_init(); + + \endcode +*/ + +bsec_library_return_t bsec_init(void); + +/*! + * @brief Subscribe to library virtual sensors outputs + * + * Use bsec_update_subscription() to instruct BSEC which of the processed output signals are requested at which sample rates. + * See ::bsec_virtual_sensor_t for available library outputs. + * + * Based on the requested virtual sensors outputs, BSEC will provide information about the required physical sensor input signals + * (see ::bsec_physical_sensor_t) with corresponding sample rates. This information is purely informational as bsec_sensor_control() + * will ensure the sensor is operated in the required manner. To disable a virtual sensor, set the sample rate to BSEC_SAMPLE_RATE_DISABLED. + * + * The subscription update using bsec_update_subscription() is apart from the signal processing one of the the most + * important functions. It allows to enable the desired library outputs. The function determines which physical input + * sensor signals are required at which sample rate to produce the virtual output sensor signals requested by the user. + * When this function returns with success, the requested outputs are called subscribed. A very important feature is the + * retaining of already subscribed outputs. Further outputs can be requested or disabled both individually and + * group-wise in addition to already subscribed outputs without changing them unless a change of already subscribed + * outputs is requested. + * + * @note The state of the library concerning the subscribed outputs cannot be retained among reboots. + * + * The interface of bsec_update_subscription() requires the usage of arrays of sensor configuration structures. + * Such a structure has the fields sensor identifier and sample rate. These fields have the properties: + * - Output signals of virtual sensors must be requested using unique identifiers (Member of ::bsec_virtual_sensor_t) + * - Different sets of identifiers are available for inputs of physical sensors and outputs of virtual sensors + * - Identifiers are unique values defined by the library, not from external + * - Sample rates must be provided as value of + * - An allowed sample rate for continuously sampled signals + * - 65535.0f (BSEC_SAMPLE_RATE_DISABLED) to turn off outputs and identify disabled inputs + * + * @note The same sensor identifiers are also used within the functions bsec_do_steps(). + * + * The usage principles of bsec_update_subscription() are: + * - Differential updates (i.e., only asking for outputs that the user would like to change) is supported. + * - Invalid requests of outputs are ignored. Also if one of the requested outputs is unavailable, all the requests + * are ignored. At the same time, a warning is returned. + * - To disable BSEC, all outputs shall be turned off. Only enabled (subscribed) outputs have to be disabled while + * already disabled outputs do not have to be disabled explicitly. + * + * @param[in] requested_virtual_sensors Pointer to array of requested virtual sensor (output) configurations for the library + * @param[in] n_requested_virtual_sensors Number of virtual sensor structs pointed by requested_virtual_sensors + * @param[out] required_sensor_settings Pointer to array of required physical sensor configurations for the library + * @param[in,out] n_required_sensor_settings [in] Size of allocated required_sensor_settings array, [out] number of sensor configurations returned + * + * @return Zero when successful, otherwise an error code + * + * @sa bsec_sensor_configuration_t + * @sa bsec_physical_sensor_t + * @sa bsec_virtual_sensor_t + * + \code{.c} + // Example // + + // Change 3 virtual sensors (switch IAQ and raw temperature -> on / pressure -> off) + bsec_sensor_configuration_t requested_virtual_sensors[3]; + uint8_t n_requested_virtual_sensors = 3; + + requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; + requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE; + requested_virtual_sensors[1].sample_rate = BSEC_SAMPLE_RATE_ULP; + requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE; + requested_virtual_sensors[2].sample_rate = BSEC_SAMPLE_RATE_DISABLED; + + // Allocate a struct for the returned physical sensor settings + bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; + uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; + + // Call bsec_update_subscription() to enable/disable the requested virtual sensors + bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, &n_required_sensor_settings); + \endcode + * + */ +bsec_library_return_t bsec_update_subscription(const bsec_sensor_configuration_t * const requested_virtual_sensors, + const uint8_t n_requested_virtual_sensors, bsec_sensor_configuration_t * required_sensor_settings, + uint8_t * n_required_sensor_settings); + + +/*! + * @brief Main signal processing function of BSEC + * + * + * Processing of the input signals and returning of output samples is performed by bsec_do_steps(). + * - The samples of all library inputs must be passed with unique identifiers representing the input signals from + * physical sensors where the order of these inputs can be chosen arbitrary. However, all input have to be provided + * within the same time period as they are read. A sequential provision to the library might result in undefined + * behavior. + * - The samples of all library outputs are returned with unique identifiers corresponding to the output signals of + * virtual sensors where the order of the returned outputs may be arbitrary. + * - The samples of all input as well as output signals of physical as well as virtual sensors use the same + * representation in memory with the following fields: + * - Sensor identifier: + * - For inputs: required to identify the input signal from a physical sensor + * - For output: overwritten by bsec_do_steps() to identify the returned signal from a virtual sensor + * - Time stamp of the sample + * + * Calling bsec_do_steps() requires the samples of the input signals to be provided along with their time stamp when + * they are recorded and only when they are acquired. Repetition of samples with the same time stamp are ignored and + * result in a warning. Repetition of values of samples which are not acquired anew by a sensor result in deviations + * of the computed output signals. Concerning the returned output samples, an important feature is, that a value is + * returned for an output only when a new occurrence has been computed. A sample of an output signal is returned only + * once. + * + * + * @param[in] inputs Array of input data samples. Each array element represents a sample of a different physical sensor. + * @param[in] n_inputs Number of passed input data structs. + * @param[out] outputs Array of output data samples. Each array element represents a sample of a different virtual sensor. + * @param[in,out] n_outputs [in] Number of allocated output structs, [out] number of outputs returned + * + * @return Zero when successful, otherwise an error code + * + + \code{.c} + // Example // + + // Allocate input and output memory + bsec_input_t input[3]; + uint8_t n_input = 3; + bsec_output_t output[2]; + uint8_t n_output=2; + + bsec_library_return_t status; + + // Populate the input structs, assuming the we have timestamp (ts), + // gas sensor resistance (R), temperature (T), and humidity (rH) available + // as input variables + input[0].sensor_id = BSEC_INPUT_GASRESISTOR; + input[0].signal = R; + input[0].time_stamp= ts; + input[1].sensor_id = BSEC_INPUT_TEMPERATURE; + input[1].signal = T; + input[1].time_stamp= ts; + input[2].sensor_id = BSEC_INPUT_HUMIDITY; + input[2].signal = rH; + input[2].time_stamp= ts; + + + // Invoke main processing BSEC function + status = bsec_do_steps( input, n_input, output, &n_output ); + + // Iterate through the BSEC output data, if the call succeeded + if(status == BSEC_OK) + { + for(int i = 0; i < n_output; i++) + { + switch(output[i].sensor_id) + { + case BSEC_OUTPUT_IAQ: + // Retrieve the IAQ results from output[i].signal + // and do something with the data + break; + case BSEC_OUTPUT_AMBIENT_TEMPERATURE: + // Retrieve the ambient temperature results from output[i].signal + // and do something with the data + break; + + } + } + } + + \endcode + */ + +bsec_library_return_t bsec_do_steps(const bsec_input_t * const inputs, const uint8_t n_inputs, bsec_output_t * outputs, uint8_t * n_outputs); + + +/*! + * @brief Reset a particular virtual sensor output + * + * This function allows specific virtual sensor outputs to be reset. The meaning of "reset" depends on the specific + * output. In case of the IAQ output, reset means zeroing the output to the current ambient conditions. + * + * @param[in] sensor_id Virtual sensor to be reset + * + * @return Zero when successful, otherwise an error code + * + * + \code{.c} + // Example // + bsec_reset_output(BSEC_OUTPUT_IAQ); + + \endcode + */ + +bsec_library_return_t bsec_reset_output(uint8_t sensor_id); + + +/*! + * @brief Update algorithm configuration parameters + * + * BSEC uses a default configuration for the modules and common settings. The initial configuration can be customized + * by bsec_set_configuration(). This is an optional step. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose + * the serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting + * the required size. + * + * @param[in] serialized_settings Settings serialized to a binary blob + * @param[in] n_serialized_settings Size of the settings blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a provided config string into serialized_settings + + // Apply the configuration + bsec_set_configuration(serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer); + + \endcode + */ + +bsec_library_return_t bsec_set_configuration(const uint8_t * const serialized_settings, + const uint32_t n_serialized_settings, uint8_t * work_buffer, + const uint32_t n_work_buffer_size); + + +/*! + * @brief Restore the internal state of the library + * + * BSEC uses a default state for all signal processing modules and the BSEC module. To ensure optimal performance, + * especially of the gas sensor functionality, it is recommended to retrieve the state using bsec_get_state() + * before unloading the library, storing it in some form of non-volatile memory, and setting it using bsec_set_state() + * before resuming further operation of the library. + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * @param[in] serialized_state States serialized to a binary blob + * @param[in] n_serialized_state Size of the state blob + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer_size Length of the work buffer available for parsing the blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_state = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_PROPERTY_BLOB_SIZE; + + // Here we will load a state string from a previous use of BSEC + + // Apply the previous state to the current BSEC session + bsec_set_state(serialized_state, n_serialized_state, work_buffer_state, n_work_buffer_size); + + \endcode +*/ + +bsec_library_return_t bsec_set_state(const uint8_t * const serialized_state, const uint32_t n_serialized_state, + uint8_t * work_buffer, const uint32_t n_work_buffer_size); + + +/*! + * @brief Retrieve the current library configuration + * + * BSEC allows to retrieve the current configuration using bsec_get_configuration(). Returns a binary blob encoding + * the current configuration parameters of the library in a format compatible with bsec_set_configuration(). + * + * @note The function bsec_get_configuration() is required to be used for debugging purposes only. + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_PROPERTY_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] config_id Identifier for a specific set of configuration settings to be returned; + * shall be zero to retrieve all configuration settings. + * @param[out] serialized_settings Buffer to hold the serialized config blob + * @param[in] n_serialized_settings_max Maximum available size for the serialized settings + * @param[in,out] work_buffer Work buffer used to parse the binary blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_settings Actual size of the returned serialized configuration blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_settings[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_serialized_settings_max = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint8_t work_buffer[BSEC_MAX_PROPERTY_BLOB_SIZE]; + uint32_t n_work_buffer = BSEC_MAX_PROPERTY_BLOB_SIZE; + uint32_t n_serialized_settings = 0; + + // Configuration of BSEC algorithm is stored in 'serialized_settings' + bsec_get_configuration(0, serialized_settings, n_serialized_settings_max, work_buffer, n_work_buffer, &n_serialized_settings); + + \endcode + */ + +bsec_library_return_t bsec_get_configuration(const uint8_t config_id, uint8_t * serialized_settings, const uint32_t n_serialized_settings_max, + uint8_t * work_buffer, const uint32_t n_work_buffer, uint32_t * n_serialized_settings); + + +/*! + *@brief Retrieve the current internal library state + * + * BSEC allows to retrieve the current states of all signal processing modules and the BSEC module using + * bsec_get_state(). This allows a restart of the processing after a reboot of the system by calling bsec_set_state(). + * + * @note A work buffer with sufficient size is required and has to be provided by the function caller to decompose the + * serialization and apply it to the library and its modules. Please use #BSEC_MAX_STATE_BLOB_SIZE for allotting the + * required size. + * + * + * @param[in] state_set_id Identifier for a specific set of states to be returned; shall be + * zero to retrieve all states. + * @param[out] serialized_state Buffer to hold the serialized config blob + * @param[in] n_serialized_state_max Maximum available size for the serialized states + * @param[in,out] work_buffer Work buffer used to parse the blob + * @param[in] n_work_buffer Length of the work buffer available for parsing the blob + * @param[out] n_serialized_state Actual size of the returned serialized blob + * + * @return Zero when successful, otherwise an error code + * + \code{.c} + // Example // + + // Allocate variables + uint8_t serialized_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_serialized_state_max = BSEC_MAX_STATE_BLOB_SIZE; + uint32_t n_serialized_state = BSEC_MAX_STATE_BLOB_SIZE; + uint8_t work_buffer_state[BSEC_MAX_STATE_BLOB_SIZE]; + uint32_t n_work_buffer_size = BSEC_MAX_STATE_BLOB_SIZE; + + // Algorithm state is stored in 'serialized_state' + bsec_get_state(0, serialized_state, n_serialized_state_max, work_buffer_state, n_work_buffer_size, &n_serialized_state); + + \endcode + */ + +bsec_library_return_t bsec_get_state(const uint8_t state_set_id, uint8_t * serialized_state, + const uint32_t n_serialized_state_max, uint8_t * work_buffer, const uint32_t n_work_buffer, + uint32_t * n_serialized_state); + +/*! + * @brief Retrieve BMExxx sensor instructions + * + * The bsec_sensor_control() interface is a key feature of BSEC, as it allows an easy way for the signal processing + * library to control the operation of the BME sensor. This is important since gas sensor behaviour is mainly + * determined by how the integrated heater is configured. To ensure an easy integration of BSEC into any system, + * bsec_sensor_control() will provide the caller with information about the current sensor configuration that is + * necessary to fulfill the input requirements derived from the current outputs requested via + * bsec_update_subscription(). + * + * In practice the use of this function shall be as follows: + * - Call bsec_sensor_control() which returns a bsec_bme_settings_t struct. + * - Based on the information contained in this struct, the sensor is configured and a forced-mode measurement is + * triggered if requested by bsec_sensor_control(). + * - Once this forced-mode measurement is complete, the signals specified in this struct shall be passed to + * bsec_do_steps() to perform the signal processing. + * - After processing, the process should sleep until the bsec_bme_settings_t::next_call timestamp is reached. + * + * + * @param [in] time_stamp Current timestamp in [ns] + * @param[out] sensor_settings Settings to be passed to API to operate sensor at this time instance + * + * @return Zero when successful, otherwise an error code + */ + +bsec_library_return_t bsec_sensor_control(const int64_t time_stamp, bsec_bme_settings_t *sensor_settings); + +/*@}*/ //BSEC Interface + +#ifdef __cplusplus + } +#endif + +#endif /* __BSEC_INTERFACE_H__ */ diff --git a/lib/vendor/Bosch/BSEC/examples/bsec_iot_example.ino b/lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_iot_example.ino similarity index 100% rename from lib/vendor/Bosch/BSEC/examples/bsec_iot_example.ino rename to lib/vendor/Bosch/BSEC/examples/bsec_iot_example/bsec_iot_example.ino diff --git a/lib/vendor/Bosch/BSEC/examples/bsec_iot_ulp_plus_example.c b/lib/vendor/Bosch/BSEC/examples/bsec_iot_ulp_plus_example.c deleted file mode 100644 index 33edb90c863f725aad4fa6aad95964facb30afc9..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/examples/bsec_iot_ulp_plus_example.c +++ /dev/null @@ -1,290 +0,0 @@ -/* - * Copyright (C) 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - -/*! - * @file bsec_iot_ulp_plus_example.c - * - * @brief - * Example for using of BSEC library in a fixed configuration with the BME680 sensor. - * This works by running an endless loop in the bsec_iot_loop() function. - */ - -/*! - * @addtogroup bsec_examples BSEC Examples - * @brief BSEC usage examples - * @{*/ - -/**********************************************************************************************************************/ -/* header files */ -/**********************************************************************************************************************/ -/* BSEC configuration files are available in the config/ folder of the release package. Please chose a configuration file with 3s maximum time between `bsec_sensor_control()` calls */ -#include "bsec_integration.h" - -/**********************************************************************************************************************/ -/* functions */ -/**********************************************************************************************************************/ - -/*! - * @brief Write operation in either I2C or SPI - * - * param[in] dev_addr I2C or SPI device address - * param[in] reg_addr register address - * param[in] reg_data_ptr pointer to the data to be written - * param[in] data_len number of bytes to be written - * - * @return result of the bus communication function - */ -int8_t bus_write(uint8_t dev_addr, uint8_t reg_addr, uint8_t *reg_data_ptr, uint16_t data_len) -{ - // ... - // Please insert system specific function to write to the bus where BME680 is connected - // ... - return 0; -} - -/*! - * @brief Read operation in either I2C or SPI - * - * param[in] dev_addr I2C or SPI device address - * param[in] reg_addr register address - * param[out] reg_data_ptr pointer to the memory to be used to store the read data - * param[in] data_len number of bytes to be read - * - * @return result of the bus communication function - */ -int8_t bus_read(uint8_t dev_addr, uint8_t reg_addr, uint8_t *reg_data_ptr, uint16_t data_len) -{ - // ... - // Please insert system specific function to read from bus where BME680 is connected - // ... - return 0; -} - -/*! - * @brief System specific implementation of sleep function - * - * @param[in] t_ms time in milliseconds - * - * @return none - */ -void sleep(uint32_t t_ms) -{ - // ... - // Please insert system specific function sleep or delay for t_ms milliseconds - // ... -} - -/*! - * @brief Capture the system time in microseconds - * - * @return system_current_time current system timestamp in microseconds - */ -int64_t get_timestamp_us() -{ - int64_t system_current_time = 0; - // ... - // Please insert system specific function to retrieve a timestamp (in microseconds) - // ... - return system_current_time; -} - -/*! - * @brief Handling of the ready outputs - * - * @param[in] timestamp time in nanoseconds - * @param[in] iaq IAQ signal - * @param[in] iaq_accuracy accuracy of IAQ signal - * @param[in] temperature temperature signal - * @param[in] humidity humidity signal - * @param[in] pressure pressure signal - * @param[in] raw_temperature raw temperature signal - * @param[in] raw_humidity raw humidity signal - * @param[in] gas raw gas sensor signal - * @param[in] bsec_status value returned by the bsec_do_steps() call - * - * @return none - */ -void output_ready(int64_t timestamp, float iaq, uint8_t iaq_accuracy, float temperature, float humidity, - float pressure, float raw_temperature, float raw_humidity, float gas, bsec_library_return_t bsec_status, - float static_iaq, float co2_equivalent, float breath_voc_equivalent) -{ - // ... - // Please insert system specific code to further process or display the BSEC outputs - // ... -} - -/*! - * @brief Load previous library state from non-volatile memory - * - * @param[in,out] state_buffer buffer to hold the loaded state string - * @param[in] n_buffer size of the allocated state buffer - * - * @return number of bytes copied to state_buffer - */ -uint32_t state_load(uint8_t *state_buffer, uint32_t n_buffer) -{ - // ... - // Load a previous library state from non-volatile memory, if available. - // - // Return zero if loading was unsuccessful or no state was available, - // otherwise return length of loaded state string. - // ... - return 0; -} - -/*! - * @brief Save library state to non-volatile memory - * - * @param[in] state_buffer buffer holding the state to be stored - * @param[in] length length of the state string to be stored - * - * @return none - */ -void state_save(const uint8_t *state_buffer, uint32_t length) -{ - // ... - // Save the string some form of non-volatile memory, if possible. - // ... -} - -/*! - * @brief Load library config from non-volatile memory - * - * @param[in,out] config_buffer buffer to hold the loaded state string - * @param[in] n_buffer size of the allocated state buffer - * - * @return number of bytes copied to config_buffer - */ -uint32_t config_load(uint8_t *config_buffer, uint32_t n_buffer) -{ - // ... - // Load a library config from non-volatile memory, if available. - // - // Return zero if loading was unsuccessful or no config was available, - // otherwise return length of loaded config string. - // ... - return 0; -} - -/*! - * @brief Interrupt handler for press of a ULP plus button - * - * @return none - */ -void ulp_plus_button_press() -{ - /* We call bsec_update_subscription() in order to instruct BSEC to perform an extra measurement at the next - * possible time slot - */ - - bsec_sensor_configuration_t requested_virtual_sensors[1]; - uint8_t n_requested_virtual_sensors = 1; - bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; - uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; - bsec_library_return_t status = BSEC_OK; - - /* To trigger a ULP plus, we request the IAQ virtual sensor with a specific sample rate code */ - requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ; - requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND; - - /* Call bsec_update_subscription() to enable/disable the requested virtual sensors */ - status = bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, - &n_required_sensor_settings); - - /* The status code would tell is if the request was accepted. It will be rejected if the sensor is not already in - * ULP mode, or if the time difference between requests is too short, for example. */ -} - -/*! - * @brief Main function which configures BSEC library and then reads and processes the data from sensor based - * on timer ticks - * - * @return result of the processing - */ -int main() -{ - return_values_init ret; - // ... - // Attach a button (or other) interrupt here to the ulp_plus_button_press() handler function to - // enable this interrupt to trigger a ULP plus - // ... - - /* Call to the function which initializes the BSEC library - * Switch on ultra_low-power mode and provide no temperature offset */ - ret = bsec_iot_init(BSEC_SAMPLE_RATE_ULP, 0.0f, bus_write, bus_read, sleep, state_load, config_load); - if (ret.bme680_status) - { - /* Could not intialize BME680 or BSEC library */ - return (int)ret.bme680_status; - } - else if (ret.bsec_status) - { - /* Could not intialize BSEC library */ - return (int)ret.bsec_status; - } - /* Call to endless loop function which reads and processes data based on sensor settings */ - /* State is saved every 10.000 samples, which means every 100 * 300 secs = 500 minutes */ - bsec_iot_loop(sleep, get_timestamp_us, output_ready, state_save, 100); - - return 0; -} - -/*! @}*/ - diff --git a/lib/vendor/Bosch/BSEC/examples/bsec_iot_ulp_plus_example.ino b/lib/vendor/Bosch/BSEC/examples/bsec_iot_ulp_plus_example.ino deleted file mode 100644 index c96fa2616638ad0a3775c510f3515c2aa4760ca8..0000000000000000000000000000000000000000 --- a/lib/vendor/Bosch/BSEC/examples/bsec_iot_ulp_plus_example.ino +++ /dev/null @@ -1,342 +0,0 @@ -/* - * Copyright (C) 2017 Robert Bosch. All Rights Reserved. - * - * Disclaimer - * - * Common: - * Bosch Sensortec products are developed for the consumer goods industry. They may only be used - * within the parameters of the respective valid product data sheet. Bosch Sensortec products are - * provided with the express understanding that there is no warranty of fitness for a particular purpose. - * They are not fit for use in life-sustaining, safety or security sensitive systems or any system or device - * that may lead to bodily harm or property damage if the system or device malfunctions. In addition, - * Bosch Sensortec products are not fit for use in products which interact with motor vehicle systems. - * The resale and/or use of products are at the purchasers own risk and his own responsibility. The - * examination of fitness for the intended use is the sole responsibility of the Purchaser. - * - * The purchaser shall indemnify Bosch Sensortec from all third party claims, including any claims for - * incidental, or consequential damages, arising from any product use not covered by the parameters of - * the respective valid product data sheet or not approved by Bosch Sensortec and reimburse Bosch - * Sensortec for all costs in connection with such claims. - * - * The purchaser must monitor the market for the purchased products, particularly with regard to - * product safety and inform Bosch Sensortec without delay of all security relevant incidents. - * - * Engineering Samples are marked with an asterisk (*) or (e). Samples may vary from the valid - * technical specifications of the product series. They are therefore not intended or fit for resale to third - * parties or for use in end products. Their sole purpose is internal client testing. The testing of an - * engineering sample may in no way replace the testing of a product series. Bosch Sensortec - * assumes no liability for the use of engineering samples. By accepting the engineering samples, the - * Purchaser agrees to indemnify Bosch Sensortec from all claims arising from the use of engineering - * samples. - * - * Special: - * This software module (hereinafter called "Software") and any information on application-sheets - * (hereinafter called "Information") is provided free of charge for the sole purpose to support your - * application work. The Software and Information is subject to the following terms and conditions: - * - * The Software is specifically designed for the exclusive use for Bosch Sensortec products by - * personnel who have special experience and training. Do not use this Software if you do not have the - * proper experience or training. - * - * This Software package is provided `` as is `` and without any expressed or implied warranties, - * including without limitation, the implied warranties of merchantability and fitness for a particular - * purpose. - * - * Bosch Sensortec and their representatives and agents deny any liability for the functional impairment - * of this Software in terms of fitness, performance and safety. Bosch Sensortec and their - * representatives and agents shall not be liable for any direct or indirect damages or injury, except as - * otherwise stipulated in mandatory applicable law. - * - * The Information provided is believed to be accurate and reliable. Bosch Sensortec assumes no - * responsibility for the consequences of use of such Information nor for any infringement of patents or - * other rights of third parties which may result from its use. No license is granted by implication or - * otherwise under any patent or patent rights of Bosch. Specifications mentioned in the Information are - * subject to change without notice. - * - * It is not allowed to deliver the source code of the Software to any third party without permission of - * Bosch Sensortec. - * - */ - -/*! - * @file bsec_iot_ulp_plus_example.ino - * - * @brief - * Example for using of BSEC library in a fixed configuration with the BME680 sensor. - * This works by running an endless loop in the bsec_iot_loop() function. - */ - -/*! - * @addtogroup bsec_examples BSEC Examples - * @brief BSEC usage examples - * @{*/ - -/**********************************************************************************************************************/ -/* header files */ -/**********************************************************************************************************************/ - -#include "bsec_integration.h" -#include "bsec_serialized_configurations_iaq.h" -#include <Wire.h> - -/**********************************************************************************************************************/ -/* functions */ -/**********************************************************************************************************************/ - -/*! - * @brief Write operation in either Wire or SPI - * - * param[in] dev_addr Wire or SPI device address - * param[in] reg_addr register address - * param[in] reg_data_ptr pointer to the data to be written - * param[in] data_len number of bytes to be written - * - * @return result of the bus communication function - */ -int8_t bus_write(uint8_t dev_addr, uint8_t reg_addr, uint8_t *reg_data_ptr, uint16_t data_len) -{ - Wire.beginTransmission(dev_addr); - Wire.write(reg_addr); /* Set register address to start writing to */ - - /* Write the data */ - for (int index = 0; index < data_len; index++) { - Wire.write(reg_data_ptr[index]); - } - - return (int8_t)Wire.endTransmission(); -} - -/*! - * @brief Read operation in either Wire or SPI - * - * param[in] dev_addr Wire or SPI device address - * param[in] reg_addr register address - * param[out] reg_data_ptr pointer to the memory to be used to store the read data - * param[in] data_len number of bytes to be read - * - * @return result of the bus communication function - */ -int8_t bus_read(uint8_t dev_addr, uint8_t reg_addr, uint8_t *reg_data_ptr, uint16_t data_len) -{ - int8_t comResult = 0; - Wire.beginTransmission(dev_addr); - Wire.write(reg_addr); /* Set register address to start reading from */ - comResult = Wire.endTransmission(); - - delayMicroseconds(150); /* Precautionary response delay */ - Wire.requestFrom(dev_addr, (uint8_t)data_len); /* Request data */ - - int index = 0; - while (Wire.available()) /* The slave device may send less than requested (burst read) */ - { - reg_data_ptr[index] = Wire.read(); - index++; - } - - return comResult; -} - -/*! - * @brief System specific implementation of sleep function - * - * @param[in] t_ms time in milliseconds - * - * @return none - */ -void sleep(uint32_t t_ms) -{ - delay(t_ms); -} - -/*! - * @brief Capture the system time in microseconds - * - * @return system_current_time current system timestamp in microseconds - */ -int64_t get_timestamp_us() -{ - return (int64_t) millis() * 1000; -} - -/*! - * @brief Handling of the ready outputs - * - * @param[in] timestamp time in nanoseconds - * @param[in] iaq IAQ signal - * @param[in] iaq_accuracy accuracy of IAQ signal - * @param[in] temperature temperature signal - * @param[in] humidity humidity signal - * @param[in] pressure pressure signal - * @param[in] raw_temperature raw temperature signal - * @param[in] raw_humidity raw humidity signal - * @param[in] gas raw gas sensor signal - * @param[in] bsec_status value returned by the bsec_do_steps() call - * - * @return none - */ -void output_ready(int64_t timestamp, float iaq, uint8_t iaq_accuracy, float temperature, float humidity, - float pressure, float raw_temperature, float raw_humidity, float gas, bsec_library_return_t bsec_status, - float static_iaq, float co2_equivalent, float breath_voc_equivalent) -{ - Serial.print("["); - Serial.print(timestamp/1e6); - Serial.print("] T: "); - Serial.print(temperature); - Serial.print("| rH: "); - Serial.print(humidity); - Serial.print("| IAQ: "); - Serial.print(iaq); - Serial.print(" ("); - Serial.print(iaq_accuracy); - Serial.println(")"); -} - -/*! - * @brief Load previous library state from non-volatile memory - * - * @param[in,out] state_buffer buffer to hold the loaded state string - * @param[in] n_buffer size of the allocated state buffer - * - * @return number of bytes copied to state_buffer - */ -uint32_t state_load(uint8_t *state_buffer, uint32_t n_buffer) -{ - // ... - // Load a previous library state from non-volatile memory, if available. - // - // Return zero if loading was unsuccessful or no state was available, - // otherwise return length of loaded state string. - // ... - return 0; -} - -/*! - * @brief Save library state to non-volatile memory - * - * @param[in] state_buffer buffer holding the state to be stored - * @param[in] length length of the state string to be stored - * - * @return none - */ -void state_save(const uint8_t *state_buffer, uint32_t length) -{ - // ... - // Save the string some form of non-volatile memory, if possible. - // ... -} - -/*! - * @brief Load library config from non-volatile memory - * - * @param[in,out] config_buffer buffer to hold the loaded state string - * @param[in] n_buffer size of the allocated state buffer - * - * @return number of bytes copied to config_buffer - */ -uint32_t config_load(uint8_t *config_buffer, uint32_t n_buffer) -{ - // ... - // Load a library config from non-volatile memory, if available. - // - // Return zero if loading was unsuccessful or no config was available, - // otherwise return length of loaded config string. - // ... - - memcpy(config_buffer, bsec_config_iaq, sizeof(bsec_config_iaq)); - return sizeof(bsec_config_iaq); -} - -/*! - * @brief Interrupt handler for press of a ULP plus button - * - * @return none - */ -void ulp_plus_button_press() -{ - /* We call bsec_update_subscription() in order to instruct BSEC to perform an extra measurement at the next - * possible time slot - */ - - bsec_sensor_configuration_t requested_virtual_sensors[1]; - uint8_t n_requested_virtual_sensors = 1; - bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR]; - uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR; - bsec_library_return_t status = BSEC_OK; - - /* To trigger a ULP plus, we request the IAQ virtual sensor with a specific sample rate code */ - requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ_ESTIMATE; - requested_virtual_sensors[0].sample_rate = BSEC_SAMPLE_RATE_ULP_MEASUREMENT_ON_DEMAND; - - /* Call bsec_update_subscription() to enable/disable the requested virtual sensors */ - status = bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings, - &n_required_sensor_settings); - - /* The status code would tell is if the request was accepted. It will be rejected if the sensor is not already in - * ULP mode, or if the time difference between requests is too short, for example. */ - if (status == BSEC_OK) - { - Serial.println("ULP plus triggered sucessfully."); - } - else - { - Serial.print("ULP plus request rejected. "); - switch (status) - { - case BSEC_W_SC_MODEXCEEDULPTIMELIMIT: - Serial.println("Request came within 20 s of a previous measurement."); - break; - case BSEC_W_SC_MODINSUFFICIENTWAITTIME: - Serial.println("Request came within 20 s of a ULP plus."); - break; - case BSEC_W_SU_MODINNOULP: - Serial.println("Sensor not in ULP mode."); - break; - } - } -} - -/*! - * @brief Main function which configures BSEC library and then reads and processes the data from sensor based - * on timer ticks - * - * @return result of the processing - */ -void setup() -{ - return_values_init ret; - - /* Init I2C and serial communication */ - Wire.begin(); - Serial.begin(115200); - - /* Setup button interrupt to trigger ULP plus */ - pinMode(2, INPUT_PULLUP); - attachInterrupt(digitalPinToInterrupt(2), ulp_plus_button_press, FALLING); - - /* Call to the function which initializes the BSEC library - * Switch on ultra_low-power mode and provide no temperature offset */ - ret = bsec_iot_init(BSEC_SAMPLE_RATE_ULP, 5.0f, bus_write, bus_read, sleep, state_load, config_load); - if (ret.bme680_status) - { - /* Could not intialize BME680 */ - Serial.println("Error while initializing BME680"); - return; - } - else if (ret.bsec_status) - { - /* Could not intialize BSEC library */ - Serial.println("Error while initializing BSEC library"); - return; - } - - /* Call to endless loop function which reads and processes data based on sensor settings */ - /* State is saved every 10.000 samples, which means every 100 * 300 secs = 500 minutes */ - bsec_iot_loop(sleep, get_timestamp_us, output_ready, state_save, 100); -} - -void loop() -{ -} - -/*! @}*/ - diff --git a/lib/vendor/Bosch/BSEC/integration_guide/BST-BME680-Integration-Guide-AN008-47.pdf b/lib/vendor/Bosch/BSEC/integration_guide/BST-BME680-Integration-Guide-AN008-48.pdf similarity index 89% rename from lib/vendor/Bosch/BSEC/integration_guide/BST-BME680-Integration-Guide-AN008-47.pdf rename to lib/vendor/Bosch/BSEC/integration_guide/BST-BME680-Integration-Guide-AN008-48.pdf index 49804ef10c242e953b466a4320a167fbdfe22932..6fc319d9ff5293b85358ee7f027539b6d9415f21 100644 --- a/lib/vendor/Bosch/BSEC/integration_guide/BST-BME680-Integration-Guide-AN008-47.pdf +++ b/lib/vendor/Bosch/BSEC/integration_guide/BST-BME680-Integration-Guide-AN008-48.pdf @@ -329,9 +329,7 @@ endobj stream xڭUK��6��W�h%ͧD�'�m�h�z�䠕h[�-9��������M;V�.?8�8�M0��G�E���W�0E�(b��J��D�E� z2�����XjBc��-�c�iF���W�ڍ�-G��џ�'H�_�+0�M��ľB�'�2��ee��ջ�Gm!1�� #iI��瑮�!EL��P�Q�{X�;`\���@�"!��;�:"� ��b�������*�u)F"-����2D��[��8�D�U��zj���U��v�(�)�81W�?��Dpu+4�z��=�+� �BH㪙-F�_�D���B�%��Z�J�b�z(���&/� �����N�,>�� -�!<8r��㬬ӵw����%���+��,��h���z�����g��l~�V���u�8�� pr�L�/��ӝE��]�JYO"�#{U z~E�z�^�,c?�����ӥeυ���E�-�1t�W��bbb��H��W�������iK��_kek[=�l�������>i���O۴�M��t���6/y�.��AQ6yjOC���q�3�o�l�f��T��|1Qj�g��"Mq@iܲ���R�e|�n@���Q`3$(����/e��*��Kk�u�m��]��#���D�N4�g/�=�(p����������C�qI��Fnh0���� -�r����ޡ�p�\�Ĉٯ�Q'�h�ϴ��^μ7;�/�c�s���i��+��u����Ĉ1f$��%�,�/��-��2E�� -r1q�m;�ΤeSڒ$���<&�����(��_�0�b�� dc�/A�xn���������o��ƴ�&,��l���W���~���T�8��e�X%U�+�������M����ݦ̛vNt[��Ue�O[��fy�:�T��>�Ij�����w��Y[�a����K@�@�Gnq#���\�ɖ�v��d�.��͙����_�p؝��o��n�!C3�_���M +�!<8r��㬬ӵw����%���+��,��h���z�����g��l~�V���u�8�� pr�L�/��ӝE��]�JYO"�#{U z~E�z�^�,c?�����ӥeυ���E�-�1t�W��bbb��H��W�������iK��_kek[=�l�������>i���O۴�M��t���6/y�.��AQ6yjOC���q�3�o�l�f��T��|1Qj�g��"Mq@iܲ���R���H7��q�����p�����2�}g襵ܺW�6h�.�Ƌ�gib"a'�ό[8��syju�a�F��!X��$��FC�74����hP9w�BP�Ph8��bD �����S4�gZ|�/gޛ���1�����4�ڕF�:�mm�fb�3�P��u�����?T��"�KH���ܶ�MgҲ)mI^���{��jŀ�Z�/�H�G1�K���ӗ��t<�E]V�M�����7hqcZr� ����n6^[�uS{}?p~q�h�l�W��*ˋ��I�o^��zW�ɦuPc��nS�M;'����2ۧ��hl���P��h��i�$���b�C�;y��Ӭ�߰�n~�% l��#����BR.�dKv�M~2Y�e��̋l����U8��Vͷn��ؐ��/k��: endstream endobj 217 0 obj @@ -4884,7 +4882,8 @@ x 4,��aAx���H+3Q��5���y�E~ !�^@��!�K+0k����Ƭ��SY�Y1�D��Q��I+�2�%��D<�x��E__��n��b��ѩA���8�d�n��c�����Mm�g�"�(J�#���q��<�P3���M��5\[�^8NwM�=�`;Y�6pmA��5�N�h�8|���yJ�g ���n�3��J��T�?NÝx}!Db4�� ����R7�)V�Mg�2�`D���� F�X�Y/�,�VA��S��<8��\_�j#U��O\c&�G�Nk���o� �6��w2_��VPY���X�}t��B1dZ��E��)���Te�П���?�T�(�@���S��Ź�_n;ߕT7���������|$�~�Ҫ���bJ�NG/�ûq���2�K�Oo�iY*�E�����g��O�΄��;�EG�:�b�&]*�Ey-�9��E����2��� ��*�}MT6�9x�����,o��h��vF�Ȉ�#!9D1�9_H�Ƶ��GDh%]�n���թ�2��kU6*�6���X�S�e���xR?q�& ���ټɓ���u�4<*;]��4�RE�˳r�����"����>�<���,��j��V���v�����3�6_���8�샮��0#-~l��$���3=��fQ��s�y:ŏӯ��0�![�P�9~�~{x�t�3b��LĽ�u������*�vX�d�iZ~�q�J+�Mz�<��� ��թ�����cL�P��$Ei��I1sƍ��I�6*I������Os���>���N���)嘪%��I1uϔ�i�]Y��ʤڴ�"��N8F�ץ�y��ɉ#�p�!�o��XD��AK-gg��f1?�S՜W��ڨ�68�dJꑲ����K��^�h?�����ms�2�7U�mP.��|4F�;2R{����*�B�3T$��3�fL��qN�a�6���A(t��L���̜��Y��Z�.�a,�����52���`:�a�� �T�l�������E6�u���%���K�c��) *g��ō�Q�<^�03����jȬMt(��XlX���.��m@d��/���:L��-SM����d�`P�l\S�EK�:�;K�5���R;(��Ou�|g�_H%����A�Ԉ�_YJ��N��yI�r��[��~H��ߌ -�_ڭ���l�r}���lF��PO��A�g����1"���x8Q���Jw����b��~]5���Z\���W�W���묾,��(�L�wݪ�z����T����Np���ZV��ۣ0F~g������_��P�k.�aO"�v���ܮm�g,�P�3�t7�s�;������&�;����x�A*c�� ���{��ͷ�f-�a��'���;��w��4�8�Hh������~G�E�������P2(�|sw8�i��];�l2����[�W����]���M�U�������_�!Ӷm�#5p � P�.�mN��M�s�~\]~���M��8��Y�z��c���iyf��<�<��GLk���7�Wx�\��/���l E��P`}��ځz�iu�ܲɫ��k�B�m�F1���s�Le�K�j�M[��e�$ɫҽ�%j�.%ѷIqc��fբ���- &��E^f�����\�rڤ�G�DN3m��PE���S&i�f�e" �V6���k�۽0I�֯�ɫV�uOuH�<[jڵm�Y1m��� v!U�f�Zެ�8}�˞a���n�k��t��%��w +�_ڭ���l�r}���lF��PO��A�g����1"���x8Q���Jw����b��~]5���Z\���W�W���묾,��(�L�wݪ�z����T����Np���ZV��ۣ0F~g������_��P�k.�aO"�v��<ﳶ��� C-�2���� �l�������۶��=����7�3K6ߢ��<D��B����H�ߵ�Ҁ���" �9���R������kO�TJ@ɠ@���� �1�Bw�d�����{o�^a�SJgwٖ�7e�W��_�˯W���\;N۶-����$'@q{��9�_7�ν�qu�% +�6�h�(�d��M6������K�����4V1�Y6ޘ_�us�������ўB���kj�i�Ձp�&����ݷ��l�"��3��.���6m�?��œ$�J�b��i��D�&ō�z�U��Jȿy���>Rr��i�.�9ʹb3@��ΛN�������4$Z��7�en��$�[��[@$�Z �=�!Y,�l�ifŴ��w[l�T���ky�>��-/{�f0ֻY���9��M�d endstream endobj 470 0 obj @@ -5281,13 +5280,10 @@ endobj /Filter /FlateDecode >> stream -x��YKo�6��W�(%çH��i��.�E71�C���UؒW��]`|��dˎ��i��`� _����'�s6����i9�h�(�@1(�BE�*bCFr��B�C��O��@Q^��4�I��v��Z�i��V�H�P��1�p%w5���:)4a"F�0��J��Ƹ!�x��Br����^�_DPڼ�N�V�q��8���"S��}ލ>�p�b$6��V�.J9�DIc��^mnj�.Q�A�*|�T{|������Y������F�l�矏g�!(� Vj�F�[��A��Gt��e2b�Mt�2/*���>.Gg�Tu�kcaO����� ~D6��o��� ��M�"8Sd�� -B�H��j��������TL�f;N�\�|��UnZ��4�B��*��ڡC㩿�������n,�͡p`�rl�� s8�*X�#|�������O��y�Z�� -~t�G�X2�!��;�BZ�����KF�H���ps@ -@�wJ�)���}钻4[����98U�J���{p���� +Nx��^T���℅u�q:w�reR��}'*��t��(��,�X��0�a=�a�|UJ{ܰ`}H��N{�N��vH�W�=q�cè��d������.ɳ?��q� -�~<"����&O<vt@=�1y�7�H�*���=��<��b���^��N�wtHѧ ��0��_�),G�E}a���z�E���k[M����V2"��+A �Y�O�$���I�| [�Q�JW<��k�~��G�j����_�ӭoTy(��8�:_Wѷ���v��*2�u��hkV�{W�<Ě���f4T*��.cCq�����o��a���-���H�����pH�g0��⬓��D�u�@�+� -*����¦���p.9e�s�-u�-��D0���)%4虆z��i������J9<(��ֶ1�@,�eG��&h�wF��dܙ��[���>A�ѿ;�;[�̻F[?nj���8F��pㄚ:1�I�'��]]�$X%aEM�6�$�&��F���u�k �����m ެ�����PW -7�7��[g���J� �:�8h��jq�k��ɔ���|��t:�ʦް�OД&�˼���I�MCs�}�'i����`#��r����tnY�xUl�L�&i�PQ���3g\�a�-c�m�l�7������2m�u�̅�{�y�W�Fv���k��=y�N����F-X�tE�=���l?xvss�ܕ��-��|�n*Ax�Z��� +x��YKo�6��W�(%çH��i��.�E71�C��qTؒW��]`|��dˊ��i��`� _����'�s2����y9�h�(�A1(�BE�*bCFr��B�Cw�Ϗ�O@Q^��4�I�l�I��v-��4�_+C�e(Y� \ɾ���U'�&L�HF�^�7�7�oT�XH�u��24���*@��ݩ�J��'���`갱O�1�n�R��Fv� +�E)G�(i�~ҫ��q�%ʂ:�Q%���ꀯ�)_�S:�|>�q0�A��������=%�J���qK�1Hۀ�d���ӼL�ǘk]��̋�%�/����I�&U��X�S��_�h��M��[-���`�@t���ΔY���� 섰����ˋ}>0�Yω��_���͋i��Y�X�3W;th< �`��TC[|�����r� +,�F� �1�Ӫ��0����8z���,}�'�˪�G�xt�%3c��VHk���{�d�����C�R���SҶHy��nK�ܤ�j]�T����u��/ݝ+\��GYq�k(�<��8m',�3WMӅkϔ+�"]�;Q�d���@�Gg��zo �����ա�� ;6������{���x!�G�{k ���^Y�$y�'|=���� ԯ��o������#��9��<�ثa�^��T��\QJ\1��on/���DG�{sH�� �0��_�),G�E}a���r�E����k[M����V2"��+A �Y�O�,���I�| [�Q�JW<��k�~��Gg�j����_�ӭoTy(��i6w���oiu_�a ˫ȸ��#hl��X/o]��kӫ�X��~:� ŝ[p\_��w�Qj��f��.���"�#�^�vR�R�!��dHPt���N@E7 �Al���(�x\�_����N�_8���SLc�{�;����AӈY���RB��ihp��(�)?~�����om�#�b[v��j�F�7�{�qg�o�6���V�?W��w��~\վm�q�X�� 5ub�5���[O��y��YI0�J�0m�I�m452�HM�|�����.��8#ᗡ�n�of�)��`1l���Bu�qД�����0�cۓ)�ѻ�"����*�z�B?AS�h�(�v`>-fi6�i�=����*/��z���߫E��GZ�U�U���U��2����j@EU���ΜiȆ���i�uߜ�۟S�˴I�U�.T�C�s���5���"���ˋv�l� �6j�ڕ+��6g�����yrW +η�G~�%���� �� endstream endobj 487 0 obj @@ -5436,22 +5432,13 @@ endobj /Filter /FlateDecode >> stream -x��YK�ܶ����[�`� ��,�a�b[�6�A��Cbg�"��ޔ|h�/�h�NU*U+ �4���ss��� �^�����'��@d�d�2�$�EЩ������"��6�I"����|�6�*$�3�F��E��t�ӳ����( RɈ`�05�`�K�I#�$����Ϡ .2�tE"7�{1�Lg,���& -^i���O�qI���K0��x���RdD�2K��j|�8X�2d#*"�u^�5~J�y��_��8)���,1�_�^ݼ��d��4 n���T� ��߷e�1|���x��?���ݠ���n�z}�P���Fx*3��4�?�F�&(�vic��QP�:��3!am�r�Ab���\�z���L$��l�ć�ߢ߷�:t�P� oǪTV����S� Yp -����"$%4��d,%��(��A�<)b]��Ŵǰ�D1���D��<#Y� �Uw_�����可q�&o��q��~u$��Ib�� -0 v`R��c� {{T�W����2E��tX��{�Z����*q�����|_;��N��ةn�jN -��)qx����G������֨��oT;X=���(c��D*ЬF�_���Z")�4�m�4F�wQ,���Ӻ�EE��`�f���* -��͖կ�G��pY��"8ןTӔ�6���ө�<���Ru86�k�[����vd�{ޜj���s�Y{"�$�����ޡ=�dhP�2�H��p����(pm_����������ڪ��]��<�� ��cs2b5��3η�k�.$���\�����)�Q6�D�-a�-t�v�m�cz`@��r�P�%�Z�ā����'Ne]� t -���U]#�����Z�T��|^�ﵵ;� �i� -_�$���x��c�KYh2����TW�.��<&�9��#}�����i��*�PI��*�![P�c$��O� ľ�k4,���#�4�2�o6�$y�r,Ɛ��a̻̭�|��N`� -� U��n��W��̄�0�P �ʝ� |�'1`"�h���Y��c��5��ӝn<sW���m��Q�b��R@����� -;N���"z���u�XV����6���{q�ۃ��{hM�a}nc?y������&�� -�d�g�$0���HB�F�v��H}D�Z]�΅./�����������ڍ��j��G �d\��z�\`�&�f_�e� ���kͣ��4�G��af�2k���@h{f�IP���a��hVO`c���AA�XD��3G���\���x��� -l���I�j��M@���0ţ�Gyw���ڐaTj��p��c+�D��Q�\%�p��dyD4�O� -�t*�V�`��`�7c�I�ާ����hu\�y�5tU��ruƝ2�t��9�썘�X���rs�J0I�s� -����M�t��o��&��A̺I�Ц��TL�x[�E��[��:���Z�C N��I��W5��c�ݢn��p�p�41�*�UA�-B%[�c��ڨ�C���B�-�;�LQ��*-���@L��i��ӽc�� _�MG`��2D���QX�8Y���I%\U -�x1*��|7���/R���j�Xmc���eKH��Y��Y�b��b��xd)�4v*�߀�ۼV1'W�h��*@�>�J�(�آ����+��5��x���t���)&(����w�s���J�O����Ƽ��|�;8��� �UA�p!nӵS3J�t>�+p�-�cV�{W�I�*��w�����qU���L��-�t��do���x�H[R@y�,�\���oM?����g��اe�X���M����G��y�Ku|,�9����4�q_`k�ę��5�lQ+P�_�6�w��Ʈ�z����>9��X���X�L�:^�z����Q��v�W:51�{�"�"[]裮�{',v� �2��Ȁ��-�TO���0x�_��l���b�S@@ �^<X؇�3��g���ۢ5wJ����,S��.�e�#{�Ibj�_�bY��?�_Y{��~��˂��b@�|b�c�¢�m��D��N �W��gv���U���]����B�;����=qg�w��D��;����-����w��{oÍ� ���|��-^{S"����LO���� &�_<��[y_����$>ڠ�e;��@�WQ�{���D�3(��� ���-�x� �L -���������o��R���X�Ep����6�w�]f�_6͟[���o�����F5���`u�~{��<�p�J�+s+Ϳ�h�?g�餈�T1�����/s4�5n����Ǎ�٫5懗��fRf� ��v.^vs��%�?W0l���%�����o��w8ab�]�8��<ZM���ء�|�Ɨ9�8��Z�6_��Y� xo_P�83�I���ԩS�˱�H2TP�+��X� �{��n/�� -mlɂ�N�-W������ܰ���@w~{9r�����w3h��jQD�a"5?���U�b���?q�� +x��YK�ܶ����[�p ��,�a�b[�6�A��Cbg�"��ޔ|h�/�h�NU*U+ �4���ss�� � �^�����'��@d"�( $gQ�EЩ�������H6�m�E�ȶ�n���Y40������hP4"&��ӥOώ�iD�$H%�e��psLF�4�� Ib��mp�駫(&1p3�C�tV�n�o���Q/�����y���j��aA .��I�f�w���Ev0""F]��]�S��[���l�AH��������JGO���.`Y�J����>�/u_�w,�����Tq���W�o�P.l��2�J���o$(aQY�`�6f9�u�a�C3*$��S& 4"rBX�KS�ߞӁ�$b)�(���������]>T�E�۱*�U����'H�F ?�0�A��I �)M#F9�F�w!O�XW�y1�1�G1��1$�� Ϣ,�GD�Uw_�����可q�&o��q��~u$��I�b��#Z`@�����s� {{T���ao�"�n:,�y�ĽR-�J�W�V��`�HUm���S��~���D5'f�Ǧ*�����u��5*7��Vϭz0��B=&� +4���W"��H�$ u[?�F�K�~��qQ��8ػYm����r�e�+a��@6\�h���'U�4a�M��t�+O=��T���Z�V�4|�Y��7��uF{��d����HXK����o�ОF24�F�{��q8���|�q�����R��΅GPx���Tm�T���N�����n��9����[Ղ5k��pT.�f �y��(�e$ᖰ���h;��1=0 ��9K(�^�u��E�X�����:������|��}e�_��NwM>�������A��-c����b<�NႱǥ4��y1U@��}�wn̜_�ڑ��]I�4�w�r���b�D[P��Q&�`��X&�n� lLа�/b��ZPg��. l�I���ǐ��a̻̭�|��N`� +� U��n��W��̄�0�P �ʝ� |㰇�01d4����,�ޱo�ؚ���N6��L��<�y��9~Ժ�n��P��A�� ����=~9h]:�U�����`v�^���l�s��:��m�'O�sp�QQ"Qa������Ԑ��Ih�8������HBP�A������ t=z�,�~X���UM���d���3U��,<�D��+�,6at��l�y�A�@��V��R<�Vf�)�bm�B�,1 j��#�� l�\� ((�E��<s]���%/��ˋG�������d������ S<j{�w���� �G�����?�>Ȼ�@�Y��U2�'hN��GL2h���J�i�v<a �3����}:�Ͻ�V�e�w�QCW��!Wg�)�NgJ���ވy�u_�q!77�cE)q��Ca�`sZ� �>?�&?m�Ĭ�T�|�6�V�b��m5�n��z:j���p��O�!����u�W�#[�##��Wᘭ +�l*�"���F�z���n9�Ad��ViY==�b +�O(����m�2pn:�,�1 :gu������Ў$�pU),�YhĨ���U��J��H���b��Y�c�.- �6f�*f��Y��٧㑦�S�T��ͷy��bN�����U��}�5�dQv�E�E¹ݣs'W�j._�bs��ܕ�SL4�{9�v�8�ϕڟ��?�y=���wp��AT'���Bܦk�f$b��t��u��J�Y��q\�&��0�;ߡ����U�'g3�[����M�k������C��="mI�o�Ls����5�4|rC��W�c���cq��6M��u�>"��S]��c��i/�\�ŧ���X{&��p���ݯi�f�Z�"�·��t7vm�C<����c�Ocu2 �x�qښ�G���_��ļ�-�8�lu���vؽ�d���. �+�lS=eӣ��9~�2��O���b���>���?� ������(K���2�8q/!?��Z;"�OS�@�j�b�a>X����L���_4��{3ulo&Z=�v���9��ň>��f���^�RF�?��"�a��;�����'B���8��8�e�Q�+�g�W|Í� r|�^�� +F��i$����LO���� &�_,��[y_����$>ڠb��Iv��WQ�{��8��/�Pr'��Apua[p���`)���)3�Ed��QsK�g��b���n3��l�-v��~�4n�n濝��_�?Ո���m����ED�_!�[i�-�E�9�N'���pb�T.�ɭqKl4M?nL�^�1?�̇�6�20�m�\�s��(����B`��//q,���W�m��ᄉm@vAy��y4��*s=ڱC��$�/s8q���@m���#�.+@���<3�I���ԩS�˱�H2TP�+��X� �{��n/B� +mlɂ�N�-W������ܰ���@w~{9r�����w3h��բ��Dj~T�U�b���?73�� endstream endobj 491 0 obj @@ -5539,7 +5526,7 @@ x ������z��[�Q�Z�����'��#��Y��)�GS�>T��6 l��<��>� ����&rXmX��m���;�Н/ ��0��L�� ��5��E������*[z6z�+��V*��w���sYk;��mWI����z�]~��ҍIe'�-�4��$)-��A>��F'3�.�������0���ifu{Y����-�Z3�5o`Ͷ�_ Os��D��� �jG��2�nݽ���&(w��؉���-�y���i�\?"ď#�Q<0}��ҡ-c�j������^i�l�y����6-�ņm�亯�+���'���w�%����b�f�x���{wg���rHT���;:�p�?_�B�L�# �]ʧ��_cn��a�q�k�(��#g}�y,�餱��AR��ƒ�f��HRF�;��6*(�|>C�{X�"�1� ��:�c�y�R�2�թ�Z:2����^��>�i��I�������Yy;�J���vm���z��73��M�j�s����H;��ʖ�ƶ����$0�[̝7K���2oɘq�S�� "ǹ��__��.�L�N0?��_Q�����Lk_�F��k�ٹc"4����M���;�}W���r��z���*s���5�؛>���r���3y�7�X����9�J��4?�Kr��Z$��X7��ÌG�����wy���v���.:zA��b�Wh�"�����C��a�I���nc�3`�Y�b��`\^���/�����\< -�� Q\�*�1d;��"GV�I!�b^�]��TsH 3��WO�˔�K���*����q�!��*�a�a"{�:��zv ��`qBW���#Ӽ�뜘E�p:��h2�{�H�=G�l��N���`69���nX����`�?�<�?�B�BGǥ��� a]��P�T?�#�o�.6��گ�#�J��)�R5�|8h�c�m�����;��"DMO|�_�GV_�Aa������֛\��\�.A«�?n?��md$�sL8��)oV�Ђ����X��O�p�7��Ǜk���l!?��fB���u]v���]��65��}��5�U7v���r���[r6���"��͝v�=�݈�8}�WA\��C�S�����M_�wd�nu�%�voJ 9�0��5J�I��P��� +�� Q\�*�1d;��"G��j4I ���B�+���a�[�j�dfa��"t��� APX���09��U�8�� L�h^�N@����]C.1X��U>���4��:'&A��)�?���������q�q�� �,��`�5�MF�p��?40��?��O������qih�ABX����,T&Տ�H�����<��+���bʢT�/�d��!F��{���'c��Q�_�Wy�Q�`P��d��`���&� 9��K��*�����u ��kʛ�9���Bo(V���>�䍽�����7�,[�O���v]���.`W��M ieߥ|��tՍ� ��\�Fs� �B!��cos��mw7b��N��U�����qӗ;D��[ݸb 1�ݛH>L�x�R�c�d2��Ǣ� endstream endobj 506 0 obj @@ -5638,7 +5625,7 @@ endobj endobj 528 0 obj << -/Length 2887 +/Length 2888 /Filter /FlateDecode >> stream @@ -5653,7 +5640,10 @@ h ��*���H���\�r3���Z\�X%��%>*��A{6�"�&���`���)� �*��Y0�n����$��a�$G�Q�C�$rda��5����-®27 �spI�d!3H�f_���V_a��CjcXa��cC�=c~�v�vժ���1�Zb泞�^�yG��DS��e� � � ���=�ycXa��5�����k��ӻ{c�m�������obD`NO���{�"ʶ��!�����7�^���}�C�%�������7��՛r~�xH��(��J|�����y����g�~����^_�����e���1���7p�DPzZ��}� ��]�� X]�pG��$z�����ڷ��`���k��ջ�Eo�z=�c���o�D0rZ��E=6N��=.����{cXa��5�����k���{�|c�����0�;Z�&�@'��z�3��qr=Ρ��{�xo#,��V��z-��z�N�ch�����@�;Z�&�@��u�Iȣ>�Ñr=F�[����ư��k�������w/���j���a�w��M܁�'m���dl�@�怚��ݲ�˛�N���K�P�}�n�v�L�g���q�?��0�j;���"[m1bvj�n�G|���M��b97�M�_�d%��72�+iXA A��|�V����h;�(b��x�wy�%��G ��'tF9[�Є0��k�vW�C!gq)m���ӯ��f�Nc�Dq��)�f�����J���x��m<�)�+�'jg��O�B!U�[�fY��<���q�Ҽ\-��1'0���_q6��]};��Qb�_��ˏ�v�>8 oerdp��Ӻ�%���*�gf��� 9%�oe�T����{^�qa8[&�;�jʰ����rs�s.�����c�,e��������}j�{���c!�Gf[�g[�N������:��-0������:��o�/��$� �'�mo�Ժ�3Z����l]���֬����:c\d���]���� ��G���s@VW>m�mrݟ;����I~S���M�$��E���Ds�c���w��U����Lm����͇+s^7���ńD�l}�ӭrW��EY5�f*NU���ڙ!��0�k���I��m%gJS���� �^��u�m!R�b+X���R���x��k�B��/��[�?����������i�a��>�Ǫ�-�rσ<��ŭ:�22�C]��eTE�qYO���j��=aN벻�Z浩��J�h�/�Y���T�ө,�v���� -��\�����:��v��p�O1��b���&FT}���ü������b�P�8�x+ @�W����S�#��]��;@�C�)�5�{!�ۿ.1�t�I�b��$<����&C�� ���M�َf�N=g͋�R��S�@Rqk��z��v*�ۙs�����n����V�ϷUt�����5��q��f?�UBp��+-bj����,uU�����F?�~��F��c�胇�8�ٽ:꫰��u���ӭ���k�l1%l��"���Yc��Y��7���~����]A��R�LReE�X���{�B���C�y��.S��(�ע�q���(i��c��q�VE���l^�lP�ʗ�9LU�UO�N���d3&��6jAe���]��y�1#o����:,zke@���d%�v�����ެ7� &`|s$�c�}Nx��;� +��\�����:��v��p�O1��b���&FT}���ü��B��n�ê�9T �7^� +���,�����>lW���z�z���^���K�:�b�]�Aם�'���d��!!�����9���٩�y�! R�9�c���@*n�/�@ϴ�N%s;s���Sw����R��j�����Z���}_�R��[?���a�Jn�y�ELM�����j51Vq��#��ϱ�h2uL}�}g;�WG}�V������/s��\�w �-��ͷT��>cLt>��|�&����ѹ+�\��I���K��QsoX��qH8�2o�e��e�Z�<.Wy%M�p"��<�"�ת��0���- +W�r3�� + �*�i�i��l`����F-�L6T���A!o7f��T�_�Eo�����d�.xup6ޛ�&7����o�D{��?-<��I;� endstream endobj 527 0 obj @@ -5719,18 +5709,24 @@ endobj endobj 572 0 obj << -/Length 3284 +/Length 3255 /Filter /FlateDecode >> stream -x��[ms�8��_���W-2���r�$��WI�ǻu�l�0#����Y`�xk���c1�K�@H�"��j1�G�sl-��ZZ����,�?�űhDQ��z� -f����|T�d��(A>�ڣ�4�/l�a����ȋ���[ B�6���������QL8Q.� �H���7��z����ʬ'��q�\�j��q+�� G�k�z���O��O�ek�(F~�j��rbE�za<��Np�%Krp�PW꺻}BW�9]wC&?�V�]����_��~��.�� ���P�V���/�O�Wy���$g�,+�b��o��� e�G��asr��~s��������At]�� �k��KS�LC����i ��ZZO��x�OL}D�R�����4�ز��4�d��m�`B�������T:�)��������{ײ}�R�����,g&�'�g���$��m�E�R�,�O�b"~� +��ۂɇ8[țrK^���f�&bL�d?��BX��x/���C�X\�1��m^�$.��[�w,^U -mI\��9���C����Fi��YU<��}���!�3VT��JJ�Vy�V��)�J�iɎ�4�]k�آ�4H�q��D�O8�@~��C_ -r����*^�r?��~������;v������X<�]d�ծ9��+�eVۻ��7U��S�a�X�Y¦�Ch[J��Vbj�:_oV�b��ݖ�q��j+L�{V�d���,��o&�Z�� ؤ�r�����jM�e�/>;n�薝��;�����V�O�j�Ͳ����m��� Go�gg���w\c�PJHq0"�;�!<�]n7|��|~ệ)�!��P���U�fݜT|:��К���ĥ�lS����%�REޜ+~��T�ċez�2ٞf��T�7+&�݀e=Ro�@׀̎W+�� �g�����zeC��N�\��3]3�O@G�����I�Ui�ͷ��*Q�C���h�;�ⴴ��e+���KŊ{��q�f�{��K�(��R���u)���tr��Ap��>�;@�D��r����: z��@t�I�uړ��g.��}��� )Q!MZ��k�gN}��7�2��lඵ��97U��@���U�V] \��:�S.E�%m (Ђc������q���8I�?�<+@Q��ΰ�~d����J��=��a� 鄊��U� =�h���Yz6=��+ -�!������q�t�r���ۊ��n����l�����:_�uqğLN��*h��pӤp��A��"����|���z^���y����t����& &�'��92jj��� �n��P��>@\�]�ϯ��ǿ^�_�\^^]�4"��^v��{�]�!�y��'�ɝY�e��x�)X��q'`�<~�^�O�Vw�.��x� �w���#�q$�O����������)@/{ ױ�p�k���@H�-\����:?�p~rq<�ر��!�j����ur'k��E�,5r ��;� 5r A�#wj�6�ܱ���<}r�(�·D�C �#��Շ�7��?�т!��D�x�S��h58��u����h�B��� ��:��5Z�A�h��r -^�B��p̉�)Z��GOD�o�/�t��=۫!��ݺ��T@5X��t -� -���0�@ SC��(���Fi�� ����)P ��)H��oR��Q�`6 :V�>���8�k}L'�aj�}T��G�L5RM� �� t�5BM��1:�5F[B�X�]��_�R�B����^S�G%�X���v?*i�^�|�<��~wr<�~}��\~b��>�֚p3pZ�>;���8��I�����l�ē�lX[�5i��'o����m�G�� =TO�]��yo�0 S�WL�C��Ԏ�`�c�B�ڳ�D�YF�u-@� _��!����յ��4�� �79�'����s�ך=w䟂��%�^W2 O�J�C=��kOb��H���v$M �����~H�����ɹA�-�$�����9�r~�������g���j���=a@C�ǣ�i�N�UA������T�m0��)�k�6���hȶ%����;��^���.�o�� ������������;���:O ��^�N�Q�t�r(H'�^�t�}8D'�_C��@�r�(�(zQZ���F�t�qC0OF��C�D�\&m��]����R��.㲝��͜q�I7�SS�l[2թ��W*e4�u��CZ��!ɣz`:[�� )x&;���-<�H���"Z��>�aJ .�y�Ww��2{�#�ߪ|ayQ��F�1�3T��Fl^|f��ȳk��b �6�Ԏ�d[ĉ*k(���ٮ�}��d���p(�N�潭Ob�Mɒk��{]��c�Y��Y��(ާ "8�Nn��ʝf�j�h'��t|�'bf�W���m/D��'r��\���[�5�tx��mo=�}���v@fO�`jK&uIŸ���5�L�&!�=p��rÒ�����>�g�(C���r5$/~�-K�ʔ�7@�N��;�e�}Z�����9�t#l�SI�|臓/_����x��(���n��>��V�¦���C09�j�t�R>Ȫު��,8��r�Flu�X^�<+Ӳb"�;$-�{(eZ���7�&�g| ,�ͣ��"��*��v����P���ت5�o�t&�-}h�Z�<��W�t��Tw��~'��;<7"V�"*;��_LW��p �� 섪��B���U�|V0�%���D.���/d�&�b������%�|�����.Ζ��S�|�:��&L��KR|�'۵�$�a��aŏ�v@0X��;v�ᇎm�[�}��'ߘjO/�ޤ:���V(��� �l�"<f��^G����wSO�%��!/L��JVeI������d/�$п�!vÁ�#D|YHm<1�z�ρ�t(�@��<!��y�O�n+��F'u�Xv��l�xwݭ~������~��$�Us��B��v�̍�1B|���'�g�'k��f���¾�e�IךT�EXS]�]/v��@�1�������Yf/[ً�3�=�D�n"./l��C�k��ã7{��y'_p��N�SN�V��;Q����!�!ت���%�2Ԅ�8{��i���x%D3�e���J�K�m�|�M�p�i�T^�T�7[cL\Jg[��q��<��*���fXU�@���:�����R�-�\�����a��u�rrPo�D]�a4��եa���?՛�� +x��[ms�6��_�/7#τ0�Ɨ~�Q7q'�SKn��xh +�y�H�����R��,F�^fҒ��}�}yq6����iy�9S�sޝ�����Z<�GE;!#(`�)�s��F�3��������h���Z�Jv�g�������@��uI���8F���!F)T��;�(�����SF��_���)�� �iR�u��������9u��`�nc_���[���!�`���<�D��0 +^D�2��F��Z�y�j���X�KXW�XJ~��)E8�����'g?�Sb�"���! +�� "=�����u^&�. ��Hde^T"9�}������W��i(�����L��O��J�'�u.�� ԙ9#���Ҁpp ��Np�������m0� ������"�Ĵ��4�tûe: +PWz��M��~#p?x�%c�0����0�x>?�j� p�� �_N���jYM�����1���x�f"-���q6�7���4���,M�7e[}OP��.a�!���W ����e�}��^ijʰ-�����]�|��'����(-gx��o���r>E�f��G1˓�z�Oi61X�B-�R��i�G�\��h��I��D�O$��~�C_2�<�YOE����>pv��G�G��Aj}�^��x���}�jNrw"�t�5��o�E���^�^��,}y�e����F/���狙��6��˲q�2�-��|�`�g�<��J�f�k�4��4�n�h�OMk�,+�|�٣��[n,d��@\�w`�!}ZT��-K�X]V�e��(�M��/���q0 T��9�N]H���B.s��_��a8��R�v�[<+�U���A>��$�_A�!!t��&5��,�����OXC��'K�O����"��i������n&��;�S��d0��tK������Q + �!F�rHeg:�� �k���0(�I�Ui�̗��S�C,�?i���yZZV���K%�G�m極r�! �zZJ��IK9���ubڻ�H�`���p�� `�I�Q��_ɋ�ӣ��cK�l'�Cd�Z��nO��̞"0��a���Ԭ�.]��s�eLC�!���x �@�p(�j��Bs���&�}�_�=N!�u�0v�� �6�a��z1'@Q���1?r`�#9����A~D{� ö@�"d(���@!H�q^d�qq$�N������=N'�!�6�{0?���`�:N��4+��|b�"�s��f� L�QaO�Vpģ���C�`��Տ<�s����͠DA�@������^��t}>�\����A���[LjB�mӧxO`�C+%!�8lk��=4�E+�����f�u1��ܽ��M�>i�c[r���)&���~zsu9�C��Fmr D��"^�����hF���%!�۹4>����z8>�N���G'۬�0��Z������}/�z�jhe+�L�>ihe[r�:�I+�aa=�V4�Ԭ��K����n+���|�x{1��˔�n�J� j���D�EgC$K�>������ٕF�����2�u�i�E�EG&z4��n��k ��`ѻ���u5zϒԲ��a��B=h��Һ�B}(�j��L���2� +u�i�A ���8��;`9�s�����w0�Ч����c����V�0�� �l��۶� �zQkHdkm�h7u�P�p��w:�I��M�(L&��}a(�'���|�#Nl�._�ht~9���}>߾���ҥ���R뗪�O���-���<�g} ��?�l��%�"ʉ�b�83�������vn��v�kl���z��p�־w��E�����@���������w6j��<���Q`�%/����?�:�h�Ӿ�nK���fz��d�qݳ�lp����Ci�n[�^v��հ�Vz ��P߰���;��n/x���I"�B�R2N���(@��I�h<|}�������ե|����`�j�2��,�M�>��<ji�ǣ^�j�tF�>��,j�?�E�m� ����#IH��{I$+��]�\�^t`OW���Ƕi?{z�ڰ�ֺ�=}(5�uȞ�7��Þ�6m�$0N�*��?�؞}Zr�a��{�JǺ����'}_ĺ�����E�G�g���PWS��)QM�|b�����3�y��|�<�{���i�r!�*}���@ՊQF�S��Ant%�x4����ب1�b/����7����Wk�}˲��.�Y]�����)�� w�z�M����u�X:���*��]�ES�Ѩ����]�������;�l��jP�~�CD��c� v�������q��a�,�81�eWu�\��3]�WG����<,�;��!+Er�K�n�~�k�vlW����#$������"Kf��z}_]ɋ��q2D�o +�#�Vx�E�gu'�U�ײH�s��r�`�>���n�U/��lS*J�J�b�n5����.�$!<)���d��Gpt9�?���j��G��O�⏺e*�� lx������cZ�U��U�mh����\_~����ׯ��>��2���� ��� UVw��)�ym 5�K���ek]y�t9��8TEx _,뎱�$yV�e�����=�5�u��;ш�#>��Y_� "��*�����k��Ǿ���@֎%�ͷrVú�%�E>�`���� +c��D���pF#�/�&|K�u�Z�C��?�Ӎ��ĸ�9��|_.J�x��Q<�K^��m\��u����Y�A�C^��8� +y�%����F�-�/-�m�,�ʓT���N?����c�] �z�>\u`�^z^�~�i�:/��pk�igp��G����,q��d)@�k�u��:!Y =��0G�K��2��f��$���|���< �7�3E�+���L�d�g�N='*�0R�s�B ��Cr��'{�f��Z��m✸koݵ�]�+ٽ�ּ���]�_��}[�����8F +[s|V)�w�y�:ȉMO��}�̝o�F�uz�}h�*D�}L�M���f�[}��Օ��o��̱{��_ܕ�l1%R'>!�ba��*$���Uxd�w�����my43s4ڊt��N:P�D�W2%�lV���)�*��q��EO�r���L} ���,O����l*Ģ�'ˤi +b�ʢ`�A�t(һ��M\�`K���m�D��e;�jV �ۛl�~ש�&[J��R�+d +]��Ӄ��&@�B���x}h(\��n +? endstream endobj 571 0 obj @@ -5748,7 +5744,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [35.168 431.876 215.371 443.796] +/Rect [35.168 432.46 215.371 444.38] /A << /S /GoTo /D (group__bsec__interface_gga832388c889417ed197609d9965625bfea5f42ad42c6bb71627b5ce91d4c410985) >> >> endobj @@ -5757,7 +5753,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [35.168 415.696 237.789 427.616] +/Rect [35.168 416.553 237.789 428.472] /A << /S /GoTo /D (group__bsec__interface_gga832388c889417ed197609d9965625bfea792b0fbeffceea19513cc0bd31ce7ef7) >> >> endobj @@ -5766,7 +5762,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [35.168 399.516 208.084 411.436] +/Rect [35.168 400.956 208.084 412.876] /A << /S /GoTo /D (group__bsec__interface_gga832388c889417ed197609d9965625bfeab9d6e7e5bb1c5f99d339a649d588b3cc) >> >> endobj @@ -5775,7 +5771,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [35.168 383.336 178.4 395.256] +/Rect [35.168 385.049 178.4 396.968] /A << /S /GoTo /D (group__bsec__interface_gga832388c889417ed197609d9965625bfea64d14f069c838de2d2c1f3f436ef6108) >> >> endobj @@ -5784,7 +5780,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [35.168 367.156 142.64 379.076] +/Rect [35.168 369.452 142.64 381.372] /A << /S /GoTo /D (group__bsec__interface_gga832388c889417ed197609d9965625bfea2368e219ebbce4e1ede7209486283a6e) >> >> endobj @@ -5793,7 +5789,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [35.168 350.976 258.693 362.896] +/Rect [35.168 353.545 275.302 365.465] /A << /S /GoTo /D (group__bsec__interface_gga832388c889417ed197609d9965625bfea4e05ab48912e70486351f5199910fcb9) >> >> endobj @@ -5802,7 +5798,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [35.168 337.427 177.179 349.346] +/Rect [35.168 339.996 162.026 351.915] /A << /S /GoTo /D (group__bsec__interface_gga832388c889417ed197609d9965625bfea4e05ab48912e70486351f5199910fcb9) >> >> endobj @@ -5811,7 +5807,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [35.168 321.246 258.693 333.166] +/Rect [35.168 324.399 275.302 336.319] /A << /S /GoTo /D (group__bsec__interface_gga832388c889417ed197609d9965625bfea1c0eee38a61b05c5239c871f9cdc85a4) >> >> endobj @@ -5820,7 +5816,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [35.168 307.697 147.473 319.617] +/Rect [35.168 310.85 132.32 322.77] /A << /S /GoTo /D (group__bsec__interface_gga832388c889417ed197609d9965625bfea1c0eee38a61b05c5239c871f9cdc85a4) >> >> endobj @@ -5829,7 +5825,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [35.168 291.517 253.575 303.437] +/Rect [35.168 294.67 253.575 306.59] /A << /S /GoTo /D (group__bsec__interface_gga832388c889417ed197609d9965625bfea9fe6dbe27991e3f9f1a444c40b30af3d) >> >> endobj @@ -5838,7 +5834,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [35.168 275.337 213.549 287.257] +/Rect [35.168 278.49 213.549 290.409] /A << /S /GoTo /D (group__bsec__interface_gga832388c889417ed197609d9965625bfea1aac5358fbe12702647de81cacd6d062) >> >> endobj @@ -5847,7 +5843,7 @@ endobj /Type /Annot /Subtype /Link /Border[0 0 0]/H/I/C[1 0 0] -/Rect [186.891 201.605 307.126 215.366] +/Rect [186.891 203.604 307.126 217.365] /A << /S /GoTo /D (structbsec__output__t_ac4e7ef20f713075472bc953efb13957f) >> >> endobj @@ -5887,22 +5883,22 @@ endobj endobj 579 0 obj << -/D [571 0 R /XYZ 420.936 204.669 null] +/D [571 0 R /XYZ 420.936 206.667 null] >> endobj 33 0 obj << -/D [571 0 R /XYZ 29.788 178.402 null] +/D [571 0 R /XYZ 29.788 179.642 null] >> endobj 580 0 obj << -/D [571 0 R /XYZ 29.788 139.204 null] +/D [571 0 R /XYZ 29.788 139.98 null] >> endobj 37 0 obj << -/D [571 0 R /XYZ 29.788 139.204 null] +/D [571 0 R /XYZ 29.788 139.98 null] >> endobj 581 0 obj @@ -5920,18 +5916,19 @@ endobj endobj 595 0 obj << -/Length 2033 +/Length 2032 /Filter /FlateDecode >> stream -xڥXYs�6~ׯ`���!H"o���&��M,���\ �p�!�<tl���pg,�[�����������6�Y�m��{������RI��rF.�Vywg���%���� Fb!�\���^��l�"R�%���J�_K:���(!4��$�DP��j�XJd���"�#δ�߽�;)����Ҵ���� 0��w�������}ތSf�]��8����y����Y�f��ॐZqX�"�������l�Y���bádE��X�9��BP҈H�$�͝�$I��K�=����i�|{�$��U�5m���?o~:{w�0�ra"<I%|�j���ȟ�Neރ!�ir�y�w���D���Q�B�p艰�x�P����������~�7kÏu�6m֗MmPƠ���sOh�=J��i�!1�i�qD�b�`y D����Zeպj��zh���Yc��9�X��px@�a�@��o�ZZ�w�4��n�z�طͽ���.��+��Tg���2��W���>�؆N�n��]��˶��B;H�#i,�;#@���Y���I������(�>���?i�˫(�"��8it�@d$��菐��'\�$$��R` ]OI���:ob�ɄEV�/�O�p��m���G(B������B; �������eV��~_����o¹�u�#��|�Ce�K�}{�厶*?�C���m��R/6#nj�q����SBg��o��[gU�d�:�n�fhǨ*�N�SzR��ey�sA:E��4=D�����EM���U�.9"�T���TлlU=����w�h��I̸�� T�����m���t��^�eS�4N�8υ35�9���w���vmw:��}!B��]o���^�O�W˟Ŀ4����V����lՉ�b+�q�a�W�G}b25��{4�K��t�f� -�����7�b��~r��s���x�Yp�Wy��nd,�c����-Z�Gx�Y+O��[Ou��D�ˌ�rU��m}%�QN�[��BX(���� 9���y�&)��q�8�LS�����n. �{l�Hbt�D�і��<����`Ws��b��T�u�4>蜺;��5N�-O{W>��`g�ξ��FDŽc���J��]u_�Tک���;U�W: ���C�������b@-����z��b��p�guaQ��7e���D�z�7��L�.����+|� -pK���i���d� -��W�S��NY�גѐf�g�����m��u$�֑�2�~C�HIh�Ƅ����� <��u2�����(�oKVrj�X)�`Jq��� -J|��<A�p������.�&���a�g��z�D��ڒ��ú ����:߶M]��B��Thp�N��3��4 -�۹g�S�~U���ĝD�s�.k�_����0��"SwS�4F�ʪr�2�ʌb`v��n�1�:�/z�(݄in� -��M=�7��)�VՕ�H�������8r���k���<��އږ���ϟ1L���cr�ׇ.#������h���V:��>U�̷Y�Qz-���G{tuӗz��2���6�`��!v��E�Nf�k��Y�47��\����Ḥ� ;0-Ó����z�9f��CS�� -F�S��p������6�^��3�?���z��i�1�)!�A�v�_�����G4�$,��;��l��}t(J�Ѓ����L_>����FI�8�� r��;V�`�,�4�H6���5z�(~�MG;��mӐ�ۻD�1�� u���\�;���:�Qhűc�kT���hr4��D��-f:���h��Z3����%U��%��*�|]�������(�Ex������-B�6*��������f�wn��Ѕ��(�U�M�n��5������M�U�A������M�p�V��C>�R_���D�my;,x0��b�VRzPm�m����=il-�S���/��}z=#�u1h�jjL�����Y琯��"B �oNw5^p <�0mq +xڥXYs�6~ׯ`���!�x��^[ޤ6���T���"��9䘇�����p��ey�4"��}��7~aަ;��ƣ��3�x�/�PO����y��$�k�ww���_B +�Z�!��$���r�sދy�M��eBDʼ|�R�p)֒N=Gq"� #/N��k�Z��8��4��aE��Z��^��匄4�4-{�4Bg���]�m��ie�7�Y�h�d$J��,�.J��)�4~֪Y�qx�2++*Ck�<a�x�֙e�ɯ/6J&aHXi�77g�WJ�Tıws���I�ũ=����i�|{�8�U�5m���?o~:{w�0� i"<NR�4��?�I�ȟ< +�r����49t�ʻ^�@B�d�0��A�DXm�S����dDx�VF\�����ǺW�6�˦���CY(c�K��'4c$��k�!I�QH�b�`y D����Zeպj��zh���Yc�O��H���px@FaC��o�ZZB��I���n�z�طͽ���.��+��Tg���2��W���>�؆N�n��]��˶��B;H�#i,�;#@���Y��1��Rj�a Cx���N�4��Uz1Icj�4:H"2b&]����OL����Kp�zF(��u�D��1��a_�s�����r��*)~��HAz���l�[]Yo�2��s���| +\�7�\���� A�߂���%⾽�rG[��ա��u�6ea���c��KV�G a�3~̷��[gU�d�:�n�|3�cT�}�Ι=�g��<o�¹ �"�Y�"����ޢ����C����\*��x*�]�����E�w�;I��$��z��́O�G�6Չ�@:0�ڲ)�Q'b������y����G��;�����}��De��W����'�/M?p}�U&��>[u"���{�XZ���Q�X�����h���6��Pv�[e7FoT�P����1�F�Yg��^�>����W��ꇶ��t<�c�Zy��D��z�S}�$�\f��C�"_�vh�+�� ��j��i*\p/�)D���{�1I�Ō#�g��`?vGf u!F�S=2�r|U���Q���jn��BLߗ��ΙD�Swg��Ʃ��i��'������W��ؘp�u])����K�J;�uPv����J'A~]v��W`;?X(4ja�Ϧ.�{���5��<���'��)��-%d���]��삺!�^�W�[z%�����(�g��;z�1�AY�E- i�}�����y�6�XGh ('�7dL���1aF��Fa���xO�oݟ���@���:��ے���"V +ŘR\����b_ev�Q(\����>��˱���,wX�Y��=�-��dby�n,���ηmS����������L3�<����v��T�_/}7q'�휯������z5��p �����ݔ1�ѯ��ܠ��2c���������f�����K�0J7�@�۽B2�eSO�ͣvʪUu%"�u��a�4G���%��Zd�<�����ʼn���g���c�(�Ř����!����E�Y4��+Z�E��~�۬�(���C٣=:���K=ijY�o�|�U��[բr���5 +���,QB�� -0����?)M��K:ᘰ�"�9"9����B`=4%a/��˩�lq9E�����76���H���� ����Ms�AM��4 +���"i��q�Y챔��~���N�y'�ѡ�"�<͎?���I���7F�0�Ɍ��[��Y��+�`���G� �0���k�C�[m��6�MC +n�)���&�Q��r�����SȠ���1�Q�r����8Mӷ��h�w�yk�d0����T���`�#���� +�_4>��\|(«���n�n:�Q�%�k݈4�-7۾skW�.t�F᭺fDl2w#ԯY�dEe�o��2)�߾j��jJ}1�(�UQ��@Dߖ�Âc�)6hU���j�lM�,��Ick��j�W�x��������A+�USc �w��:�|u��!j�D~"�������q endstream endobj 594 0 obj @@ -6136,14 +6133,15 @@ endobj endobj 604 0 obj << -/Length 1942 +/Length 1941 /Filter /FlateDecode >> stream x��X��6��@�_z�[s�m[ �61p���%��U�=v�@���!)Y�ڻݤ�6!M����pF���0�kWّ�ܭ�a0~����Dф1KN#�H��v���[�B���)NC�,�n�3�g1�l��b*F��Bʕ\J�6⤈(!�bF�(�a��4�Q9����e��T��/+*�P�dj�� 0�?y[��ו}ٌkf��]��0��������*'ыV��/̊�Y����<�b�|��3��__m8(AY"�������J&h"�����'4�c%6��|���m���y{u��M�����?�ޭ'�0�£8��(��o�a�g�S9y0�$)�ǩ Tp�b�W� *AO�Վ\��pw��B�#�0��X~�:�kҮ�+�p��6�O/���$��D)��BB*cA�PP���� ���?�E����Ǿ���͋]���L_�pr�Y��24@�$d}8�"�^��1�-��9�^W�Ս�c����Ǭ���^�'���;}ün���Pt{;k���z���ڞ������G��M�����l�� I��D>Nh��ݛ�-���.���^��!�LY��u��{0WI�n$���)tebŽN���7��V����C�����+# �wH�F����Ȝ�XP�@P��p���j��GԭS�=���ۮ��v��a��3����M;�x�m�f�k���T�vvK��Y�b��`��9�q�_m�c��u��ɾ���r}_d���"��zo�����`1w��������q���j����ǣ8���Kw�;�+ۧ��ڍt����3/�c���tyWg9R2>FqxNҦ�7}Q�V�0����#�^���U<�<�^����8溄;�`��������h�P��@�����bӤ��rb��E�v��c`JwiQap ��Q�xe\^���.du��W¯秽c*D�5�a�]xs[�e�0�@�k��P��þ0Ri=Ĥ��� sg�ݴ��.%����^��4�0F/<���P��p�� H�ã*����`n������ HJ��! 0�w)*w�1<����D�� aQ���^/j,�[ �%��I �����*��F�Pb4��P�@���u�8~8~f�[�fMq���)�e��\@ Ȑ�A���Z�-M��������s���7z���w�� �C�3�X*0s��9��� &< T\��������>�� -m(����[�^���)p��C��K:��>�F�Wú{�1Y��d��f�fC"���>��WrY !����CK�x�^D8����ÓL�W�<�^y.��CDg��Y�N�S}U�^���X�4������sG)E��|0���ڸo�H���U$�Cd�l���y�W4Km(}�P����ǫ����w��~�����>p������u��J4me�i%����`C�6���Ƈ7*���R�o#�#��=��W�&7?��C�P�ؘ#���������x�I81�glF�^ħGB������y��'���K� ��bN�J]���z��E�%����Y]a#W�Y�+��ß�������솅�0N��4#+��/�� �d��%B�,��䟋ߣi�`�Gc���z���i��9J�7�g�u^O�}q 'BC��Odg49Gb�4~ �=��/u�C�5�1�c�*2��^�3`.����[�)�>� �&�������b�*Ť�CYڵ����}7s������6vi��n ��ɊƖ�n��0$�~<�uљ��}l��ƥ���]��9�5Ŧ��M6�l�Ͳ̓.�y�^T��N2�g4����m���=�Q���h{�M�j%��l˭�Eǯ�LB}�r<f,���U*�� +m(����[�^���)p��C��K:��>�F�Wú{�1Y��d��f�fC"���>��WrY !����CK�x�^D8����ÓL�W�<�^y.��CDg��Y�N�S}U�^���X�4������sG)E��|0���ڸo�H���U$�Cd�l���y�W4Km(}�P����ǫ����w��~�����>p������u��J4me�i%����`C�6���Ƈ7*���R�o#�#��=��W�&7?��C�P�ؘ#��������x�I81�glF�^ħGB������y��'���� ���S�R��^@�fa ���DVW���sV� +<���'���#(�m�� �aa5�"7���_��f �ٸ��?�_n/����hZ0����6~��^)�qĦxe��M�ف|�WǓt_\АE���M�Ƒ4�_��`�h�K��k�h�ؿ�L�|����$���oJ�OuB�ɧ:�)����G��؆�J1��P�v�)v{l���e!hy��F����]��[iu����۴4���e]t&y��F�:�q)�4~רv��DtM��'<ik� <�c�l��rޱբ������M��/�|kۿf`�{T`���uӹZ�:�>�r+x��;�P�ς����� endstream endobj 603 0 obj @@ -6198,16 +6196,10 @@ x �3�{��� a<��Drq�'�z�&$K� q�B���S;g'}�?���ܳ��tR�T���ΫD=/��j�S˳zE��2�������IY�4yR�Ip��%��tP��u��gt ��u2[���V��A�x����]�x ��K�$q����DJ'I�� �7����w��H�{��i{�_�~�����LF�LaO�����}����6U8G�u����S9�sX x$�o����B�`�u�5�}sJ�L$|�������Mݫm��eScś�,�Q�s���$�}�HK�Y((�d�(����!3o{u�6�^O���+�����7l��g�� $�\ �8��%��U����V]��Rw7�ˢ�/�н�����~���ЪNչ�����j�����f��>�*�+�w���q��CV�Eg�I� -�-�mEK�6���]Yo٥� ��އ����<"0�c� t���0�5p�Y�����f�JѳD5�S�J���5}�ϡ�Σa3����c����4uv���[�ZO�i� @s����u��3.#���f[�:�Y�{�u��ϲ.���`ýّH���7/�gk��`�,��`yp#a�d�~G�ԪV�ʮ��*���.��tD�%*�l���E�`WX��XE�U�RuÊ�d@'���.�y �&o�Z�=��S�g���2o��7Ue� ��>���/�O�ם9>h�j,X�BwCM��i�3� V[^<n��m:c���m�e�/�ɪ"�O�C%�xL���\u�j�i/�uVu�P�E�Bє8S�BE��l�S��i8�vZ�R��L&���m�`O?��.���vơ��$@��V�AڇK��Usث��:U?�mSO�d�����U ��)sE��v�ŘB�m��ݛ3����!:��oSl���_��P֍��4��� D����3N}�뺷�,��O9�<�B�����1K�'��}s������i��@E��g~�Z��/F���P(�oS{f�����X� �¡�k�.��|�#��uewJ(�K�I� B��i���̷bC��]������� -_ ���ɠ�AR{�rYw};�ڌ;�i��DC+�~8`����ͫk�%��#�|��g�p�t�-�'�2� x��Z���k�S�qҞ��x:B@��]f��.��aS�K��� -��th|D"��p�0�/S ���2;?l��б��"æ��ΛO� }�V�X ,�d�ә�٢�>��X����Q�$L��m��g S ��ߜh�Hl���n�|h��-@����d���C �I����X�H;�w����t�kbKf����g�Zfޞ,ԲN -�;ɶ���[<���J�X��~�AB|�"ܾ�z�M?_lTO����0�� �6���ΒO�CZ�)�6��l�;A@ ��8w_�t�M��)�pH\�՚�0 -ʹd��娇�����љr��)�j�n��:������B��*�#2�f��2���#ܴkȺ2���^���4�#(�g��,LɻY�?�7���s��SoHQoJ��(���;Y��,��2�VmKHA[�z��-�h�X���҃,"�tdߏm��QX�9�ݒ؇0D�¦L�3bQ�LB�Z��=E�d�b/͐�s���1ֹ#��ٽʇ��^��F�P�� -]�hk��|�2D���*}3���zU���9���8��ن�Q����d4'�m&C(Hfv��^�5�y)2�~�렱h��\����7 HȪ"�}���������x��Jm�R�`9����3qR��?��_2����bhzѩ��'��M�Ӳz{�@v�]O�Br�|�+��'�#��4�D�v���j�ȷՠ}�W�rfI ���v��J��i���7�=�}���&u�`�k��Hi>��P�Q���Fp�b1�T5�>�ep�|��d����a�bX`A��� ��<l�_X>�R�[=Zol"9�|�~�w���F�K�o�R{{�R�2�d��g;��,����ju�[A�"����n�FOw�����%�T�h.�����Sq`��M�1�dow��O]P-1���tp�ŕ��h[���.��17M����;���҃���n� -D��BO�� 0u���Z�c]�v���j�9H� ʊbݤ9��lhţ90!tt�6�7�!u_c��Ӛ��Zz!{u�)�Z4��36����v��,�D���ٛ��ÝZ�"mwC��K�?�hs�P2�K� 'M\ lyd;Ygo�����ǚ��Tm�r�l�a-M�ի�XR�/����5D�������_2>$:���o����s��As mN�>C4�[�6���;�=��-�|�j:�?����=2.���?:y�r�������@���M+��^<��'�ߞ���� -�/�,���A"���?��BǮ��>h���[?�� -���ݰ��_����|����,��j�\g膺�K�k�㌯�|�[��P��/�D�8p�/�<P�쳭g��z/����ӻ�?} -Y�9ST'<}z�o�@Q�0pD�B��>�b�M_�����<C��z:����`X���z�#4]� ���C��Gx������[Y`�"��@8g�9g�рLBGG�?�T�]�L�}�LN�>g���;ު�[ �f�tw�ml?�ћ�_7��/��i�|�ǭ�m���p̗��z��r�w�lWǕR��bQ^��1���P����a/���L��6�2Ђ�3��^� 0'DI�O.������#A�?�A��o���m��ݗ��C]�s���䅮�~�Æm�╾~��G��(�C�e��^�סj��8�j0���д�()I�`��-7�lL֡���s��6K���\ߖ����٦g��P����q����6�i��_�qs>~m�[i���($��u<_���mc� +�-�mEK�6���]Yo٥� ��އ����<"0�c� t���0�5p�Y�����f�JѳD5�S�J���5}�ϡ�Σa3����c����4uv���[�ZO�i� @s����u��3.#���f[�:�Y�{�u��ϲ.���`ýّH���7/�gk��`�,��`yp#a�d�~G�ԪV�ʮ��*���.��tD�%*�l���E�`WX��XE�U�RuÊ�d@'���.�y �&o�Z�=��S�g���2o��7Ue� ��>���/�O�ם9>h�j,X�BwCM��i�3� V[^<n��m:c���m�e�/�ɪ"�O�C%�xL���\u�j�i/�uVu�P�E�Bє8S�BE��l�S��i8�vZ�R��L&���m�`O?��.���vơ��$@��V�AڇK��Usث��:U?�mSO�d�����U ��)sE��v�ŘB�m��ݛ3����!:��oSl���_��P֍��4��� D����3N}�뺷�,���A�p!��OI��%���9KW��f��4Y[�"� �3� h���#v�j(ᷩ=3����{�F@�Pe�5k�`��B�ݺ�;���%�$d � !Cߴef��[��D��.�Si�i�}���O�͍dP� )�=B����rm��4���^��T?�Hǎ����5�l�}>m���8�d�ܖ�[�<YR�Z��5�)�8i��L� +!�U��.3�Hr�尩�h�u�db`:4>"��p8@Ǘ)���C����j��^F�aSPC�ͧ�>��G�@2��L�l�~��pZ,NTW�B&���������m�oN 4_$�G�7l>4o��K�W�a�Os�!�$��ی��H�e����;�B~C��5�%�[qZp�3o-3oOjY'͝�d[�R�v�- �ٌf�t��j?� !�Nn�t�զ�/6�'g�QR���Q�ي� `gI���!����I��k�ǝ ��N���/���&C�s8$.�j���\2@�r�CVV�h��L���Z�\�@ R�j}��@!~x��v��u�[��n�5d]���pPc/N�[����3HR��݊�ό���BI��9���)�7��7%�eEE؝��[�PCF�\��%����~��ؖh4d�A�G�AE:���6�(,��nI�C"WaS���(}&!~-�ɞ"@2f����fH��DS������^�CpB/K�#L(�I ��y�5KV>K�S�~�>�p�~�*� +tOr���A��l�ʨ�R@a2��ق6��?$3;�Br/ƚѼ�^?�u�X4Jh�@S� �$dU��F��G���f|<�Y����6a)k����L��8�O)A�C�/��NY�J14��Ԃar��zŦ�iY��� ;Ѯ��]!�F��B��OYP�~����SX�N��j�>�+v9���X�y�_w�u�kp������h��f��5{u�4��s(���i#8m��v��?�28p�]�2u�D�0G1,����t[��^�6�/,�@)�ӭ�76��qF�?��~��%q�7E��=F�nF�Rҳ�z���B�:ҭ X`f�i7D���;�[�����}4{����80c��&�r���K�.��U�@:���JGL�-]�^M��昛&�Y���Zy���Ca7u�MS�'����@�BGsP-ڱ.Y;FqK5�$��eE�n��L6����:� l�?��ʐ��1��i�� ]-���:ᔀr-vA�ssxc����]�[�h����Mm��N-y���������H�9P(��%_���&��<��������F�c�{e�6Q9f6˰����U],���}�x�"�y��N���/���7�����d�Р9�6'y�!����l�N����_P�|>q5����ݿp�V���<A���?~�d�� yf�צ�a/F��oO|Z�B���Y���z� �{�P��\!�cWl��M����}���n���/���g��j}m�x�k�3tC�����z��q�WM>ୌ�`(�ח^"t��j(o���3_l����}���՟>���Ҝ)�ʓ���f %GD,�/��/�l���:a�?~���3�ߨ���NJ �������?BӅ�����1�?��o��lE���1�¹83�9��d +::z8�����gz��g2�p2�9�D�ܹ�V��j�7���nc����4��y=~9�N��[=n�n��G8�.��`�4����S�����e�:�p�*���r��� Mԇ�4�?�{�G�xdZ������y/���M�9!Jj~r���� �h��<B��~�6hl/�x�4��Z��uT&/t���6l����kV?��E��.������US��yPU���ͅ�UEII���S�m�fc�� �~�X�����L=���6=���\�f���]ܠ�i4H{P��R����k�ܚHS��E!�x����b`��^c� endstream endobj 614 0 obj @@ -6308,32 +6300,33 @@ endobj 613 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R /F89 511 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R /F89 511 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 626 0 obj << -/Length 3653 +/Length 3654 /Filter /FlateDecode >> stream xڭks�6�?��&����n^M'i�؝����$Z�E$U>����]P$-YN��$�X`x\�|� �Us�;+�wޜ�G��W���N����*�"��:s��~z4�f�4N3FӁ�d�ui�ܯ%D��#{*��ZMg:���)yB�NO��'E]�b/��8h��T��O�t�N��'} ��܃��tπ\�-��R�{��cl��/-�0V�H\�8��U�D'�������Z����y�Wu��=�`����q 2��I���ޜ]���KT97wN�xQ;QB��Y:�f�V�b}�Q<��ʦ��lq����g�n����Gq2�q�O���:�w|j����� ��8�C<�XL�S@'���9����!�� &�_� ޖm���6�J���ef�Z{:��S,]��0?�";���t�Px -���9��4_�$�C@q/ -QKo�d�ۼjo���b��<�J����dłI��L�G K禀Y��g9C�d -5K��|��7u�< �϶��EUl�M�$�</���<���x�f]u�n��Z���F��U]g���<^�3�2py�B��]��"�`��h�m���b��:F����¼Jk�+���ɐ�8��%A^]��0$��?_�0�23|C���)`H�&��(%F���J��K�|�t&[���8;�;ݬ�K�%�x !m�vBZ&@�3Vw{���D�Q��J��1�l��F�c�.��+P�a�Ʃ�PkOD�&�9~2�*�P�Qu55��! :I�{U/��d��K�.֠4��Q��%"���>0�fC �8�W��,�#M�X�ņ����R��U�eV��2-��)�Zi*Hb*��}H|C�zM@�FQ�*�T�0��`W#�ci��sr��f��zū�/�I8}dM�+CЛ��~d�����YZ�F2k���Y����&k?�2j��:��)wW���=,�Dz����~X[��:� 1gB8��ݕ��;`l����8KyL�ߢZ�wCXb���A�x1�.�9�8�6�RW��ȇ�b��~Օe^�LԳ�'`��AҖ�u���]Te��%s�k�.-+������!�B�%����w]�ا�g�1h�m�ݹ�c�YL�� �&J�#�G�#/�|C�+���m�=��>9Z����@?b���O�v�_B|1��*]�zr�:k��S6R'ºJ�m��s���D%l�-�/�(6���_l���˼��M�P# -�ز9i��ÔA�Ic(!��z��vMK(��V;�~F�&Jc˘16���s--SY�͠��j���L���7�c���X������e� -��<S��Aޣn -C�)��^_������ǫ�W��>L��� .�{�7�]s���6���t�?�M�A�C��=&#�6m�f��� �z����O�r���_H�;����![D���� ����D�E��5zS��Jjm�)�%����>k�>f����$�c����.��Ap��l��xgV.�.h�3T�����<���a�w��)��U˱�5f'g�m �9"�c� Dg��Fcd �t $:^;�Ϭ� ��oG`�m.�Xdi�<���J�Ǣy��㊼�Z���~��>��Z@�g�3AB�m�"�+���%���m��}�Nk����tßgz��l�[�o�2�t�F:��t��#��^�T>~��H��d��*ֺi�� �Yy.fy�8f^�kj�����o�a�q�.r\lYDž=T':�f��&i"4 lm�z[5S��l�SK��Ō� �du�:aO���m4>�2�"��Vj�|��r1�=�C�9����D8]�]��S�����E��R�1!f=)S�*5�y�X������c -=��G:��G�5w�i���<t -�}>P��k�U"�/�m��6��6�:܋jJ�EW� -��*۸���!�>�"�<{+�P2��@�3���L�~岭� ��:�KE��}Ug�)�ϵB���'W���x�#��U��0�/�&���C��� �r>�J�4� w���عH�i�H��c�pT�O��w����Sy -��+���u�z����:!�V��.B_�ςo���:]��RMx�z����! +QT��@�~��UA���;00 -���.m�c��\���|��l��F!.l>#m]uδ��6�z�:k�R���Ҧ�8b�~2a6NI����<�A:|k+{��T�HB/���h�}5{��#�2j�>�I�3Ie |ɧ�7k�a-�-"����8+�N�h�g�6��94��qg�y�W��|Tc�8|H*�Y���0.�� -���c�"+��a|���D��yD<3Za�`+�����l#Yo��!��O�j�=/(��>������>�A���c�G���"��Bȫ�x"�1�Lg�! -`�*4�� �pG8��Y4�Y�j�������pĨ��`6�c+psn%��9����G" Cȁ|���+�es1Lb��M3�.Q_ �c� ��,�-��x}�s�^y8ŀ��E�g�fح��y"��vD�UdT}�A�j ��x)�8��.{����#ޥ�LE��z�U#�g�/�"�����N��Ii8�=�S}��e/@�U����Slm�c�|QCM �²1��g�<B&����y�6-�I�;��d]��,R���K~=�!�Fb��~su��*G��Y����.|��4��Y��aAM:z�2�k�l!$�CR�r�#"h�A�7K��I�9���LH�m�J `��|R�x; +���9��4_�A���Q��!�(D-�y�-n��~K��&�*I���&�0 %,��f�jPt�����)R�%��,�O�M:�dԑ�>�:sU��7ْ �L��H�.�㉚u�mxP�i*j����WXTu�-ZB�x������jv���l��㢭�]sH +Њ�^ +�a +KX +�*���Xκ&C��`��yu�!��_�|A`�@��� ���`�! �|^�H�����+;/��ҙl*���t��.AܗL�%,�0� �� Ih�@��X��I?dN!F�+E�{Ǭ�M�!��m����@q��3�vB�=i���\�����OB�F���XTh� +���$��U����/Y�X�ҔRFiȖ�؋j���� 5��d^�s��J�4c���˖WK�sWm�YM#˴���tk�� �a�(��!�AXM�5�E� �{RA,��Ã]�0���'�]�i��5k��f~��&���59�Ao�����2f��gimɬ!'�g�������˨�_���G��]U_x�����Eξ.�!D`m�v��&Ĝ �pvWn�;쀱]����,�1�?|�j��=a� r@��I��PC����`l�8K]��#��`B�UW�y�21P��u��9�'I[r�)O��wQ�m���izP���L�� +���>�� +嗄ڊG�u�b��S^�mǠy��v�ZO�u�f1�����(��@mb��$� �;ж���D��h 瓫��!P�F��?!�� �Y�8�tA��ɕ��;OL�LHM��N(����o� �����d�h��؋�1c3/�6O7�0@�P(Hc�椑SU$������]��5-�`w[�0�y�(�-c���#��-��Le�6�b������3A��\��(b��v�?����*�g��LE>X�y� +�)Y�tv{}��ûW��n^ݾ�0�*�7����wܜw�����l���%�l6Y��.�d��dڴi��n�~4��]�2�Vk<q��1Z�!��`Vk�w�lRc�f'���Ac����M��*����Ȗ����U�����MR�����κ�|������_�Y������PmO�*�G��C0���eڦlOPV-��֘��m�-$����16�����5��5��x��>�Z�\�������x�c��e�$*/+-�f��ڎ+�kQ.,�Q\�G��C�j-���L ��͋����v��k�]k|��:��K���� ���9n�����ӑ��ӥ3��P�{aS��]V#�2��E*�X��P�g幘�{�yծ�e26�>����N����q�e�|P��0��F���Ѐ����m�L��N- �w3�� ���sj� �= lj������N�.��[�1�œ��X�X ��jBJ/�t9�w�F�O�+BHVTc�'MOH=Ƅ���L}����Qb=VW`�)�D��� �ܽ�Iv��5t����@]v��V���p�)�h��s�x�p/�)qgX]�/L(��l�º�����@�쭨B�t�C��pT��3���˶�6�� .E��U����>� +�FJ�\I�W�%��LXW��p�̚�6�!������*9�Ґ6�A�oc�"ml��"��A�QE�?�f�}0V��kL!�m(�ʮ�j���I�U��oꄔ[��}�>�M7o�t�3H5�=��=|�4�DP}�IX�uWW���(�*ۻ�i쏵zs�ƺ+�ea�������u�9�RZtڰB��iKeƾK�����Ʉ}�8%A�g������Y�Sq" ��������)Z�� ʨ1�p'i�$�5�%�ެm�=����d�&�v��:y�9�ڈ���PJǝ���}^u��QE�=�l,�!�D|�f�&�¸t�+PZn� ���������h�Y��|jR�~��du��6�xC�>=����� "��|��C�[�t:�R���_O$���{!�&�(�D�3�1�,(�el��4:6 .�q��g=�gͫ%�s�.���Z��Ȏm������s<���4!��f��@���0��Z7�0�D}��#���'̧�8��DF���Υz�� +��gح��y"��vD�UdT}�A�j ��x)�8��.{����#ޥ�LE��z�U#�g�/�"�����N��Ii8�=�S}��e/@�U����Slm�c�|QCM �²1��g�<B&����y�6-�I�;��d]��,R���K~=�!�Fb��~su��*G��Y����.|��4��Y��aAM:z�2�k�l!$�CR�r�#"h�A�7K��I�9���LH�m�J `��|R�x; ��Ѣ'SmOq$ ӆcl��$���ٗ�@��:�Y�˲�:Z;�F,��h�6�� e���NgO!��h��ZC<��&Ul6�\�m���Q���X1�z�m�pi*O�`4�ݥ�M����h��ګ?(����8������7��K���B�{�f��ȣ�& ��ٕ���~������j�% -b=[�o����k�G�*_Р��L��͈mQ �͠�俺��ܹl�mb�i��碫?��p±@+�K۠q��m-y��2r���O|zA�y��g[��Yʠ*��\_�ͳUn٦J��eƾ�G�/a�'Cu����Lg�1�T������dC��=��P1���X�=�fT����^ J��9c"��w������n�����0w��]��r������j*8�(�6�I��w��e���ft�<��v�F��p}��(������<,q�~��إc:���\!Æu���i�B)H�<E�kt k"���Ú�ԡ}J�W��N��Uf}C�K��<���dL�/�����=���Iuh�!=�rΎ�9G�A��';��/L��À��/��2���`7Ι;�u'�����a}����~�i�<�Y�-׆���$��-���<�<� ۋ��sR�W��k �9�Q<|\��&�C�5���ze�����"�M������r�^ܽ� %1/�v<z�&�<r��j���Gh�xN-�G���j�6��(tAG*�V�:ViMG;�3-h�e�l�&�\Љu��vS��Tg�UYv��2��+�S�u>�8i�w�Z!F�f���~{˞��T������&���NV�E_vH�=`�j��k�\���=�DʼWXq����s�� +b=[�o����k�G�*_Р��L��͈mQ �͠�俺��ܹl�mb�i��碫?��p±@+�K۠q��m-y��2r���O|zA�y��g[��Yʠ*��\_�ͳUn٦J��eƾ�G�/a�'Cu����Lg�1�T������dC��=��P1���X�=�fT����^ J��9c"��w������n�����0w��]��r������j*8�(�6�I��w��e���ft�<��v�F��p}��(������<,q�~��إc:���\!Æ��=�Q( �������a���aM�X�:�Oi� +�Щ�ʬo�}�ۘG;��i~�~����'�� =)�M� ��Z��4��:h���a� :��Ipp���%�XƠ����9s'���`�p;��?4���?�⏧_#k������?s�d�����_�G�a{Q8N��Jv��2��"�������cx����Y���|�_��陁�[:�Q.ۋ�7��$�e��ÎG�ܤԃGn�S����mϩ���:_�ۆ��.�H��*Q�*��h��M�̛mդ�:��~�n��r8���*�nу�Y���r�`������'m�N�T+�(��2{�oo��r�j`sV���t���}�5�ɪ��� �@--�K�p�'��@���!��"��}�_�/ endstream endobj 625 0 obj @@ -6378,7 +6371,7 @@ endobj 624 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F89 511 0 R /F120 619 0 R /F44 228 0 R >> +/Font << /F45 229 0 R /F89 511 0 R /F122 619 0 R /F44 228 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -6391,20 +6384,18 @@ endobj stream x��ZYs�6~ׯ`y_F�H x��[��G�d˶T�'5�B�9䄇'�����F������l�-�8}|胘˻�o��P��փ�Zo���b��z\ˏ}'f̊wB�[�����L�*��d��|�~<]ui���b.ÿ�9"f�z;a�ᾘR:�4�:��0b��8Em�G�4��i� �(�_�����4�^��qy����%�z���b�6r�� "1���܊_DqxR��q�qВˈ�\�#Y��Y�)Y�%�M�}���d�y�\�����o��sb��ݽ�c'�"+���w��q�^o�mF�[Y�e�����wߟ]� �a�W�t!��?�V -��[.(�[{5u�Ӂ�ʭۡ�Ǚ�\/�>@��'���:6��͜����ׯH����U�deAo�,�J�/�ө'p&@1�'�Y�8"�,;��{�wĹ Y|'�$�^�iYV�UV���$Ϛ�#IhЫgHC�L��F�ˀ�n��f�Z��[��S,�I�POSҳ���f���_��9[��m�ȡa�f͆f^Ui�z�����Y�S�&�,ǻ��ⳬ��w�Ԏ�\��23SM/+��1`�vf���+䤅u�݁�WD�/�O�Q؎��'8��t�m�wߖ�h6Y}AM��-֛�x�fX7h5M(���-�ow��2g�c��6�qU��2+��ք�&��-����==���\-'vFÞ�����D�I�5G�q^%{U�&�b8� �f�>C���_l�����]��Nq�D�T���}[��G�^ʞb��dY0���Rb��M�{.?<Ʉ7��`�W�fM��5�: F`�$M��iZ��6���Y��������ᯎ1?1�/ -b}W�3 -t')��V�L�O��Ze[Q�V���I��I�?=ĝ�^��F���$�6؛�۠��=�7W��9�[��Z%��֟ƫ:v7e��}���@Q���tr�(2.3��Z([�ڸ���qY� -��3KzVr[��uO�(��3Ut��`잒ʃ��xL�+�Ňs-4�I^�ē�#��d��Ǔ�*�'l�ey�.��E|L�(l]ɤ1l�$r��9�lbOBJ�k{v�8Eg>��v�C��)�u��� - �8t�H����w��S��p�������u��G 0�c�/�����s�D�@`����*��55�[��BI�c"s�-���7Q ��O:���o�"[��������U�Yɇ�3��Vm��c��n?��y��]��z� �F@�m��0��f�]��JI��g�*��`��L8,�G�м݂G5{6�ro�ʽ�t�Ti����������RB��Vz���L�[�p�C����]^��@+h -�Ƌ� ��.%��>�����Տo�^����^��v��ŅvY�{����^��w8�~�s)w -2��x�Ӻ����n6��ك��}�2��R��\��Z/���iE��Ɯ�V��ĭۺ;���= 8!x��p�6O���.�+4�x �?���3���B^��ɔ�.m�Nv|q]Ue��\N�HV<�y15�3U��8�)���/t����n �zR>>���~ -x`�4 ���LL��s�����z��k�1�2���}�h���&M�=]��a$0��N�j=k�� t`�mT����P��%T�<�A��kf`zU_ȸ�IQ?�To�9��(��f�6+�����ǐ���'�R���=�f�d[ gq�[���mvm��ɣ '*b���ow�h�.B���,��� b@���:��Msc��D��~��I������r�C�"d���l�S��&�H������$*��R�}��Ɋ��{>QZ@,pX;�7��F�w猱���W�� }E�V�G�pȦ�Ɋ -25�":��7D�2����+Sӱѳ��R:�K|͊uަ�R3�L� -�������5_��~G=� :IU����t��)�Q����O~�dp�þ��a`9��uy�A1�� ��T��eA� �O�kUc���=5tm�Zǀ�E[��V��O*��ϱ���S��wfD���0�tE��RX������}���^�gU%�c���nVm�E�M���B�:ga��BC'�4�P�mM9��4��� A�l&)9��v8���K�F;���|t�+�ȷ�5� ,�(�`.��ZX��j̻ -b�6�k�"2o�=Vw����F��u�G�C����U�ͦ<�1���j�)�j�6v��K`>�G�k�o�>�|i���9�Il�/�3��"���r���t�1P�����'$�ᡭ ?*"?�����y���*�)k�8:��b2�)x���t�^̭�Cq8����ܷ��q����0�D^n�i.,���g8��bjY��3���7|��k�S��տ亡<�4�9 ���e�'@n�����(�.�-=�ݮd��s;���;6U�����V����?]7�[*�˕Bq�8"����V!!<�����������~��v��_hAs�ګ߇A��] -}g�:i�LхA��.�m7�y���wwe�������Ύ,���p�B{��? �!C�z3o��e�s0I7�֙=�'���*�n�u�s��tx�~L~���F�[%[�k��1��;n������������}Z�v�p%�[aa4��A�&=GOQh�~N�_���O�MH�N��5�ek��=`fX��^ʏ~��y���*o���h�� ɞ��� -�,쫲�MS��B����*U�_�0"�iV��:�/��D���ˬI�vU���]w]�B�*�� @���U;X��x0-c#os�fŤF� -�h�yf���Y�o����EM��ɪщ*)�y2���P?[b�����-|�i�� +��[.(�[{5u�Ӂ�ʭۡ�Ǚ�\/�>@��'���:6��͜����ׯH����U�deAo�,�J�/�ө'p&@1�'�Y�8"�,;��{�wĹ Y|'�$�^�iYV�UV���$Ϛ�#IhЫgHC�L��F�ˀ�n��f�Z��[��S,�I�POSҳ���f���_��9[��m�ȡa�f͆f^Ui�z�����Y�S�&�,ǻ��ⳬ��w�Ԏ�\��23SM/+��1`�vf���+䤅u�݁�WD�/�O�Q؎��'8��t�m�wߖ�h6Y}AM��-֛�x�fX7h5M(���-�o�Cc�3�1����z���Rk�Y���\p�ɀ���Zx.��;�aO� N��l��H��#��8����P�O1�džh3Z�!�}�/�IV���.�g�8f"t*}H�-��#�/ +eO1�]�,��\f)�S˦�=��d��R0d��f���u��x�#��E����4-� +YZFڬ����[NH��Wǘ�����+ՙ���Zj+|&�'ji����Q��B���Ӥ���NM��kj�Tf�~�s�M�m�Qɞ՛�w�����[��x�O�U���߾r��i�(�AQ:�V�}�s-��\m���ȸ��D�T +ƙ%=+�-�Ϻ'O�q������UA0vOI�AlsE<������9���$�K�IÑi� 2ow��IO�6�<y����">&`��d�6�G�l�]6�'!%�=�P�"�3�V�;�!�����ጺ�c�G��N�Z$HXm�;��)qPg���q��@���:Ћ���1��O�X�9X�o 0@�K� +T�⚚����$�1������tЛ�F�'�`l�ҷm��u^�]_]��sG��*��C��_R�Is����1�s����¼Jr�.�G=�b� ���d�V`����d ���ʳU�T�c��s&�#Eh�n���= y��w�^V:J�4jd�]U~�Loa��C)!Cn+=P����b8�!Ds�F�.�@]�4H�E��b��i�L�����Ƿ?\/�_�]/x;���B�,ǽ��U[/�U���;�T�ֹ��pA<�i݀SX�e7r���A���>FGY�{C��U���~B@c�j+��]��mݝ\�������p��e���ȍf����s����U@!/F�dʁi�6|';������H.'G$+�̼����wgڔ�K�:����K7�y=)�ZKF?<0��� &�|����cqR�\ֵqӘ�?E�qՇ�{ 4L\I�&ў.Q��0��Z� h����q�:0r�6*wR���j(����{ Ƞ\�530��/d�ʤ��\�����zg|3o�m�za��c���I)u`P�d�l������-[�t�6��Q��ф1P�÷;H4�!��bJ��1 zctK���1f"FR?�?��pb���i9�!T� +2x}l6�)�H�T$�x{i�DcUc�ƾx��d�\�=��- 8�D�R|��s��Bg�+Iτ�"A��#X8d��dE�O��"TAK�rÕ������e)��%�f�:oSC��L�O�P��p�|隯M|��������*M��_:��ߨd}��'�`28�a_^�0�����������Fmu��Ӳ ��'���1CD��6}�c���-@O+U��' v��XP������;3�rOjv�}���O),掏ZTEj�EDT/㳪�DZ]W�M7�6��&}OB� + +�Z�3��JE�!���UK(B����G��H�� Z6��Oj;I��%r���hx>:�b�[��t�q0��l-,���5�]�i��5X�7��;��NT#�ɺ��!n��U�*�fS�Әm�o�ٔG5f�?;��%0ˣ��7H�N������Ƀ�$6җ�BY��_G9���|:��(� _�� �Ì�������Y�aj��zch�ٔ�S�S1�����J:c +/����8���f�[���SNr`"/�ʋ4�?�i�q��3��p@1��T�{l�>���)���_r���|���_���� ����i�F_������nW���r���*W{p�h��E��-� �����J���� ����U����~��lp� +Vu���/���Q���� � �.���|�4�W��� Xp����\�!4���]��x,�����n쭳#ˬ�� c�������r��Pc����E`�L�͵ufOF��b{� +��i���D��?���ߠh���V���ځ9qp��{�g��a{��~�V��<\ �VX cУI��S������9�S�~��F�_a g�/v�Vb�����:x�?����ś��;@lC��3���4���a�Ժ���&�&ŧ���JUd�W(��t�ջ�N��9����2k}�]��b?m�]W��� +�z�h�l��@�G.L������Y1��/�q���vy��[�G*�<m��D�nw�jt�J�q���}.�ϖ�p|�}<�FK���v� endstream endobj 633 0 obj @@ -6439,7 +6430,7 @@ endobj 632 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -6450,18 +6441,14 @@ endobj /Filter /FlateDecode >> stream -xڵ�n�8��_!̓<ɢn�`�M�x�,&�y� Z��5���a����*��d����&E�u��G秿3c�8��p���0��0�A� cF�v�F#���O����� ����� ��:�{��b.ÿQ�~��`��?Ǵ���|/��Q�쀹� �`�$F����"��Fe�Ez}`{����+���G'�g������>��>�,�W��0�Gl���5;��$z���sAJ#t�s�x�u���?��n�h�O�f��=�fI��ߜ��d���Qd�_nbGqlD ��<3.�7u�n-7��3Q�uӉ����o��G�0?�� �4F�_#�������Dp��3 -�l̃��,���L���N0���o��x����g��E<�T�X7�����<����Ӿ�(�8�@XFh��gX�knL$���S� -��W�v5��Q絛R$�}�*�˾i�{�M]����.� ���N4�U����{�;��ȑL���A��y��+�:p��]��8�ӏ'2q��Yּ�����w�g��x�W�n��3N��-�2��$��~����!���Ӻ<m_��R��*�:t��Fؗ ���U[�m -A�5�H�d�?Zy��@h��� �ȣ!M��`�ƅ���1�~&���NtJ����D��GWS�v��y�Wk� ې2>��}��\$#����0O܄�d��w�[��U�"4-��{���������o�4[����营�F26�E#�{�v�Ac�)K�1�96�Ghv�H]����^�����46����&C���X�@ݔ��;�2�ׂ%�.q�h�_��4�����"��ox^��Bh��C��!�9�(����w���_jM�`j�+v��6�)_����ܡ�zI�lB9�Ў@�cY��Ѕ���A{�}�_���_�������������M�������"������! -Bj���ȄS2�̚�D^nQ�J��b;�L�Ȼ���7g!��_U���^7��ð3��Mb�AwFE�{�r���������7����z 7�ě:ϖ4"E�]����ӭ��{����F����E3�[��T��3H� ��E��h�F�ɱ �./��rK�yK���{����&`���8d`���"�fJ�/i� �9@�?��̋"o2�1���(hq�B����D�Zt2]�0�O�L�W�"3!;��2��|[ܩ$N�<T�֩S�h�d��=8�镻Ȫ�ۺ����I]�k��W�V�D��{ч��Ȝ��<n������ɷS��{��K��s������()�ЧyʧyAdV5�=Ԕ�fV�w[�������y�Q�A�%��Q�g(5�� -$'(H�J�W:�����<�;B"s��84�����̬�r���ċ�����&��P���抧�L�6Ȣ���!u��n���U)���?)y -� -�FN����P�43[t5�3s�T�Q��&g��V@أkz�Y�P���˦/�L�:i>s�]/v͓ן���^@rB�d�B��i�+R[���%��UO�Y���U�`Z���!nD5�=Y�� ]4�(x٪o^���PZ+�E���d4u�FA�۾�e���5�`���+僞�S⫢���4�^�Max�Ӵoxz���ͭ��jk}N��F�wml/It�oW�<�w���k�*t�K��A&]`��al{a2 ���WE~�@�����Z�L��w�(��SE�Ras/�I�m�X��i �I����R�O?��1�U=�-�#z�Dxoяҥʲ�P��T���i�� -�?J�6߿�Bb?J"8��nW�?NV����w?���z���ڞS���T���B0e�nh\f��k;�űw��T~ -=���JM�2��P�U*Q�� �tO �s�.���,�<׳�hB&x1^�ktT6�G�a�d8[�ț�1�E^}�|�nd4�9�˭��Z؋EӬ&�W�K�0[�)RL��l4�S]�M�W�C �P:u>��R8�1i��P��M�~��>��0����ZN�;܄�����l�|�"SP�(oխ��4=ƀ�U6�c���5��s��K��w<�H-��y�ھ�>�Y�d��U$�!����A���߰qͷ�V�鶿De��m���Z`?�����q��;y��8�Ʒu�S&��R4��"�Aj~~�E�&���Ȓ�E��;Nlѡ��Bٖgڏ���s��CB�n�R`�Dz�e��2p��X�LM�籝�}��/��.��6�K��� -7�!����N$Kl7��W�`�2c�>h�I��p9��R�c����c/��v���q`�f��bk� -�5�0�h��ϧ���7Ț��8�� O��N07�vb���$���ii|�T��<T�2j�(?�I�(z9�oÃ�'0�n�ۄ������1������)�|�e��:y���`�p ��y\^~� �m�ka���(h��כ�U}��ȏ�fVk�л~��Pgy��[^��)��u�q�v�C������0��9@���č�~�jx� @��M�ͭ(�o�]�������;�n�|���n��G��P9q�.)I8��y� \_� -���W��'K�>���� +xڵ�n�8��_!̓<�"u�`�M�x�,&�y� Z��5���a����*��d����&E�u��G秿3c�8��p���0��0�~��1cF�q;�|������{�G����t�����竎�=w{1���Џl/fFR�����1�k{t��� �0b��8"E-��GHt���8��l��^���븀 q�� +�5ptR��� +H�O��l�c����Dވ-��p#�}/��G��n1Rr�����뮻�W�1^wKF�|z6�@d�6�\�����=%s��C����F�Ƥ��Ը0�TM�9�x�g�l�������ޝ��a��,<�b�i��/�8F +���� +�@p��5r�l̃�r�G���Ӱ=��jm�:=^����C6c��ݿ������Z�YU��q��R1�\{��E��(�l/r +��#"�DFR������Z��zW]� ɯ��V\vu�ރ��b����wA���ieM_��ڋ��g����bl��C����6Z��>���f�����N7�H��J�i��>'s@��q2�Xm�1��8���dH>��B�pl{�O$�WM0����HO��T6]�?�I��Z�L�}�ji_����Z�M�5 (y��Db&+����:k%B���`��:�ԩ�m\X���g��L�D�5�_�K6 }��M+�Z�Y��� %㣉�g�.�E1"�t.� � �DŽ&�����%u�Ȥ*���h�~ޣ6�Y����������g��V%�4��A�ƺ��u'��=c�?mi#3F:Ǧ�͜��uJ���u�<�i��8���%w7:%&�r�L^(�Y�ʿ,v�"M��`�:����M��%�(%=q#�\\�W}6�A0���&7��n�D��^� ���oD����LwZ�zE�lB;��A�cY��Ѕ����|�N�Z��/�j7u��=IEc�ײ��rIIù����ӣ���(�qlX��Nw~�3+ +Y��e!Kl�\��42�<k�CϜ��B|սno�{]�p�*"�Έ2G6�0�<J/�%N<�-�ۃ��-Ǹ��y$�\���$ �TY��%�ޥ��<��h�'x ���?�hfcvK9���<��/`ѱl[-x���l��(�4�54�gG���)e�!��7?�C����� ����%���<���Y�g�C0��u!-NP�6A�Q���L�4L�S0��e�H�L��9뙀�m�;�����N�Z}�4M�����3�bY��ʻ��xRx����A�n"�Ŏ���nld��c�������L��۩A�=�遥̎��هVi�}N ����\��\?4K��j��3�軩 +�n���۬�h��$�IWk_�3�(h ���njB�«p�����:�;BBs[g�80������̬�r�qc�ċ�����&Yg"�����J$�LEo�yU}�C�xe��]��RdS��� �+�96&�C%�,�l��Z�̠SbG�RR���V[ `���If����"-�MWd��u�.<��n�͓ן����CrB�d�R��i�+R[�*�%��UG�Y��U�`Ru��!od9�=Y�� ]4,4(x��o�7�}(���"�M_2�:O���mת2�n�t0���+탞�S⫼�ɴ�^�Max%���Er���ͭ�����,�*I 't����$ѵ�]�M�@��%�G�E��a.�Nm;t�5C����$^B(_��e E�N�jq3�v�NQ�K�ͽ�{�<��b��p�X�B+ �?]�4#��W�̷�����E?J�.���A��S�3���.L?�(����]B�Q�I�8u�2�q���d ��)���(D����m���:m�)#䁙� B�i��ޭ���)�TZ��+}��?�C�V�D�6��{z��u�ey�`��r�v� ���D���Q��=���ly�n��4�Y����v�2��IUl����^,�f5���^:�t���O�`� e����ۮ�j���P�������~��� %��\g��;����Y Y��T���&D ��}g���C���@y�o�]��1�.�����ܘ6*�-��/%v��4������F`{�O�X����W��X�����]f~Æ�oU���Mw�ʢ��d#ʵľ�J/���DY��zq|#�o���"Ltť��템Aj~~���E�&����R�E��;Ndѡ�U!�l�3�E������ !p ������l�XN�˞���yl�&A_� �+zA���_x� �w�c9�Ž�*�p�/�D���=�{�{�A��#$����r8���r뿘�h�oG@���l֚-�F��������|��Ysz>�o��5��̍�N�q����q?)��갓ˀ*OE-F��5i B/G���� �[�6!nf`�~Jcei{�v�@J�^{��N�]�=\çg�hm�Z�g��s����mt_{!���"����Z�������#�i�l�F�jAlʿ�y��B���P-!p�]2E��tPi�@q����2P-cos+s}#��.fv�����]l�y6�[u�_���C���r�V_R�p���x�sO� +�l�Ӊ�:����� endstream endobj 639 0 obj @@ -6491,29 +6478,29 @@ endobj 638 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F120 619 0 R >> +/Font << /F45 229 0 R /F122 619 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 646 0 obj << -/Length 3484 +/Length 3482 /Filter /FlateDecode >> stream -xڭis�6���� a xt�;�4N�NҤ�:����(H�"UQ�����H���3N�x�M\̮�Sg՜����Wg�á��f|G$�$�:q�H������{����x�`$���s��:���DL��:����Dp�ӱ��.��<t��An�z���$��8�!���)����qF��a7�{0T��P�7�yQ�lj=��1�<˗�$��[Z\�Ϝ�� N��\� �()�To#_p��~x�����%$�>�q 2��$���gg/A))'IE�l鰄Dq�D�>�����>��l}�(vod�Tu+���g?�]���@( ��d��������A���)� � �)��!�3*b���$�:A�VαWׯ�x�"$,�L�\��yx]�rU�m^�z�U�/�b��t�)�}0D���~l�� �H�O��6@�n-k�Ąn�V�Ϋ�^蹦�nA�z~�f�ӕ�^V����Z���~��M��\�s��}W���rQ�g�]k��ͪ�0[� 1O�ʯ�f[H�1J��%KF�FplcF��P�W�Ê�Q���յ��܉H� -�1�@���7@��("��,�7��< B��r0�D�������/�۔�R`�>M�'ʃ���Eڦ8|Sei���E����a�c�lc�8\����Zj,c ��`�@K�RA.�d���ę�웎W>�L.�_����w����ͦ�c��bz,���$�*T�Lj�wG��rm>%q�m�UW�����T���sx��wf���BVzf+k���h9�-�����J5��6����L�Y�mbjf�kR8앶��i�������ƮY� �"��3.�)1б�=�#-���=�;�r+˅�~Zi�R�^ݼGu�?�(v�Ⱥ�]�]��AZ��]����*��a9�6ʌQ�{Ї>��,% <�NF���Ul}8��+��Qst8£�gVm�p�k�p��BN�n�"�DI2F4�˴ε1��m����È -�0��j�Ȍ��4`��?�Y���p���M@é��G^Z�!n��W9��cm��31���� -���al��'���Z;��S�a��$ -#p�1a��Z��4��88 -j"�Lin�E^~�����qԻ���{���O�(��d�-d�*$I�[�%$Y��T%��{ăY�b���~��F���<熳M��N)�����z�|�]��;��B֭q -�u�Ԩ��)���~4�d�'�L�^eF��'D_䭬��܃��%��ښ�yA�HA��!�� G�Sp<1�`j��� y�apr�/@==uP�a3�T�l��>E�,cH/�M��F��!�ߞz�"�N��q����A<N :Z���8u�b��tz>������O|�_BH* �C��I�İ�&1,��f�uZ��sk��J��ģ�Ȳŝ8�ȢО���s^fE�0���~?ӅB4E���MY���.L��},�/�W&��F��t� #!����z�Sh)XnB��r�!s��l��|F��qa��&��la���m^��2c%����'�0q �>��W �R��P�D� ';CQ��f/b8j�E�bBNگ�@b��O��$�"�O -�ϯ�}����j�ug�x]�c�^W���I�S+�l-��f��]�ɍ�st�8~[�yk�:���め4of�r�SȲ��5��������gC6�����������%&Iu~_ʝl���j��NM�� 7��zm� �`hU���̳YW;�b.����@��#*�^����?�]u��@pT'4.�#���k;�}��R�O=�2�47��/���\UУ�<��*��*�P�� -��b����G�|W��P�P�-G�1\QvՔ���b�ኊc�h2��>W��G���� -�PE�Q�$~�Y�`( �q�7]�ɦ��D�5df 8y�k������^�E����m���+:���6[�p=Q�����,v8�bX;���'��}γ(tG�����q���owz��'0��=3�r����l�U{i��M���;�k���鲖S��B��B��T���$���b+5K�f��=�g9��܄�A�E��>�8�m-= �+�0�0}��v_��Hh�0S�a='� ��{�Qڵ�ca39��%�6�KǨ�A���D](�\�ښQ�����Nvi��nԭQ�� ���6D1�6��0�ڳ�}�V�Ԓ���h���Kd��*�b;�ִ��>��Fu���V�t�M�m�Y�^}Z�(cH�c=�\�g�յ������P�t%��Ba7퇀�T�Ű�_T�ʃ"kc�:�mk4[h���#4�A��O݊VV�W��ygT���'�G6�K��K��V�S���dܫ�U�b��=���X�39Q~[.��>�" �U�r-NC�=�� ���Q��9M+g���ɴ�pM�{7��c����ۺi�l_��Wv�m�\@�Í=�R�;X���U{�CZ�&���0;�� -�7���V������6"�:��O�O�u���cZ��Ҧ�(V,�2Ӟ���9~��!JR��hx�%���#(��laD�$�N���\C� d��%Cy�ہ��Im�8R�PA|��liY-��r�H�/��bD,�=]&�-��qO/�>|��h��?��!���������o�n�/gW�F1�T|�.���4�y���꼕�ߵL�gSH���,ą/1��b�H����J��V��D7�BHi��q�ֲf������O�Ѡ��'��� �=z��z������n�;&�̺1�Rd*���t�K;��Z��D�d�t�e>�D&$���ƈӶI��یl���g�k|�@V���] K�^=���^J�8�7>�7��Gd�4����qxo��@��#�W�`�����c�YП�C�s8Ȁ'�?�������B�M�@���ux� �o+�8�3�k�{A��4�VMDŽS�?��}��_7�\;����O��{e�Ug�l�{��w|Qe&�+�n3�5�6b\�{��Wa�{�)����]����j9�O�(rdU�D�:���!��w��wq�����8]{牧go��E/���P�W�P���8��d>M<?���/i��_s���ȡ��C}��9;��9�U1�9��`S�eA��_P��N�>@f�9g��[�`�7X���?���?|}�~��Y�-7���fU�Ǡ�PwĨ���q�q�M�=&��,���Q<��6���a����Y�#��G��陁7��t�P��o�0�$�2ŎG��8�{q�3p_m�?���P �����\�.36^�]4�}�Jk����z�7۪I� q��mQ孽��S��D�~*v�"�Ϸ��h�|� ֤�v6�,�����N�N˾/�^ -�_�foej�am�gLʼn���s�ck�Z8����+ 6O�h ���06g# +xڭis�6���� a xt�;�4N�NҤ�:����(H�"UQ�����H���3N�x�M\̮�Sg՜����Wg�á��f|G$�$�:q�H������{����x�`$���s��:���DL��:����Dp�ӱ��.��<t��An�z���$��8�!���)����qF��a7�{0T��P�7�yQ�lj=��1�<˗�$��[Z\�Ϝ�� N��\� �()�To#_p��~x�����%$�>�q 2��$���gg/A))'IE�l鰄Dq�D�>�����>��l}�(vod�Tu+���g?�]���@( ��d��������A���)� � �)��!�3*b���$�:A�VαWׯ�x�"$,�L�\��yx]�rU�m^�z�U�/�b��t�)�}0D���~l�� �H�O��6@�n-k�Ąn�V�Ϋ�^蹦�nA�z~�f�ӕ�^V����Z���~��M��\�s��}W���rQ�g�]k��ͪ�0[� 1O�ʯ�f[H�1J��%KF�FplcF��PƆ+�a�֨�����ZCq�D$�|��[�O~� �_Dƛ�� !�X9x�Aoz��j��m�K)�������v�"mS����Ps���ˊ +�a����l�1C���vi-5���J�Z�\���d� Z��b~�Lx�M�+q&��/~{�˻��w�fSۇ1�X�D1=�]AC��vQ��r&5��O�6��8�6˪+Q�cfv*���9<��;3]Ji!+=��5��f����EQ��r���VnC��B���,�?15��5)�Jۃ]۴^���M�uc�t������X�� �AS�ŝ�����BS?��4^)v�nޣ��W�_d��.���� ��뮁M������be�(�=�C��l�P'#���*�>��ؕ��9:���3��w8�5g8� �~!'U�q�O�$#��eZ�ژ�϶yV�s�aD�C�I�U5odF��0�s���,�jc8���&��T�#/-��7Vj��S�6y�����A[U��t��06���h`�Lb�)���x�q�8�0�R�f���G5g�47��"/?�Z��Y�8�]�L��=x��'q���� +2]���-����l��@�=��,{1�}��?�v��W~ �s�٦Zx���H�ry�c�T�. +���~B!��8��:��EjT�O,���� {>)f`J�*3���?� �"oe��$.i����2E +j�>o8���㉙S�O����ۍx��s�Bs����e��)"�`Cz�m"�X�4J�y��ԋ&�u�e��/- �qJ���ҿ�hũ��|����d���S��H|⛐�BR�uLb X�$��6�a�v0���R�p�[��W�$$�F�-��F���؝�2+���hE���.4�1(�u.�h�b�upva��c�}1�2�D0j,����[O i<^����BK�r���q�S�f{��3��h�ۼ�5Ɉ,�`����h���U�+!��<������j8�*���} �M8 +Z�"�7{[��P�-�r�~m��#Jf&YxR��x~�� ]T;=�;���B������LʞZAgk�}6{���@Mnd����۪�[[ա��y3;����d��@�ݰ��)=���/��g=���,5�������,1 H���R��`5NWKevj��������kSop��C�J��`�`�ͺڙs 5��r�QI�j���i�:����Ӡ:�q�9��@��]���{��2��q���d���|}�����z�G�m<����A�T�}T!�>�j�Ux'P��>*���J��*�� +l9b�ኲ����L�{WTCE�)T��_=�h|U0�*��*&�#��X��CI����L6�?&��!3k�ɫ^�.���}�Z.���l��N^��M�٪�뉊���&`�������<���+p�E�;�e%w�<U���}���=����-d�mg{��K�`�m�E���_��MM����zjZ�z��&9}[�Y�5�.�i?���&�:�(҅���Ynk�Xٮ�����T��b�wFB���j �18Yopp�Po�+�Ү����,��^�8F���T&�B�[���m�ݤwz�K�v�u�n�jf�Lऽ�!�����ȅ��Ԟ%Ұ���6���tE[��^"��Pa�Ѡ�����&7�#ܼ�ʤ�n�m�������DyCB���R?���M\ Mo��*�+y�� +��h?,��.� ��*WY��!m[��BKU.��*}|�V��*���]��;�r�l?�<��]Z^ݴʝ����&��^��r{�������ɉ��r�X�����j�kq��!Lm�̌�6�iZ�8��GM���kr�ݻ!��n����M�g��E���m���:n�1�j���Z�6����J4�Gt%�$���FV��y��������?��֩o}zx}2���Nǽ�´�6�D��`ٕ���k���C&Q +�j��C�-�}UA�U�`#�' u�,�(��n ˷8-ʳ�|-NjkőrE8� +�KngK��0h�]��F�~�w#b!P��29GmaЏ{zav���|��@|��p�Voo.߾su{}9��5����#v!8��λ�vW���e�0?�Bʭ�`� .|�� hKF����W +���'���ABJ���������0s�LE�~VZ��>���t��Ѓ�փE����u��1�g֍ɖ"S���_�ae����$�%#�3 ,��&2!��.6F��M��fd� }��;k,(�}�@V���] K�^=���^J�8�7>�7��Gd�4����qxo��@��#�W�`�����c�YП�C�s8Ȁ'�?�������B�M�@���ux� �o+�8�3�k�{A��4�VMDŽS�?��}��_7�\;����O��{e�Ug�l�{��w|Qe&�+�n3�5�6b\�{��Wa�{�)����]����j9�O�(rdU�ē:���!��w��wq�����8]{牧go��E/���P�W�P���8��d>�=?�X�4 ��9p�i�Pp�����Y�Ń��� +�\�)�2����/�rx'c� 3̜3��w���Bpֿ�����>\?�~������[3��t�cP{�;b�@��8�8�&�zb�ƈ�(�G|z�0D{{��?�^��#������W:C(�苷W� Ru���bǣ{q����8���6���m(� �K�Rq���/��~�.�ʾX�����?��No�țmդ�Z���붨��^X��ZB� A?�r���[�[�u>�k�F;H|JG�f'u�eߗ�/��/}��2�ܰ��3���� H۹���5 a-���~ �Mxŕ���b�����Qg> endstream endobj 645 0 obj @@ -6573,24 +6560,32 @@ endobj 644 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F29 648 0 R /F120 619 0 R /F33 531 0 R /F30 532 0 R /F44 228 0 R /F32 514 0 R >> +/Font << /F45 229 0 R /F29 648 0 R /F122 619 0 R /F33 531 0 R /F30 532 0 R /F44 228 0 R /F32 514 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 671 0 obj << -/Length 3125 +/Length 3126 /Filter /FlateDecode >> stream xڭis�6���;�#gL���v����i�8Mme�;IFCS�� E*<�����}�Фٙ�E�û�.b��zC�Myb�2^���A�� z,� ]Rj#��7�'�ݙ<(�`�e.#�W͛=���!��_� �R#� �u���� 8�� �=�(q)@�&�����@�g;L���ȌI��N�m��M��5%Ў��1����9�:��ɘ"�l�r)��G�˲�� B��Tu����,��e�6��5'hu�Dk����oGH�Mh��O'�A)�MB�����`!���C��be��=��x{j2?�]�̋�ǧ?�\,z�PǕ�!�4��}���lX�Tf�ԝ�8�Fj\�i 6�n�sm����<A�6���Ջ1�����ϐ��Y�7ET%y�/�d�%A��ӗ����!��f�!q�0=�X�F������"�ũ�Ίd��b���l�Ӻ�0D���uA3�S�P"�B�80d[\F�7�Դ:������)��>U���JJ�V�I�4���ٝ�Y^V���q�6�ռ�T������`vSW�<�K��)��L�V9V ODg���Q��ɐЂc��"�H��#y��QY|��6���-W��Tc�[ ����Ӡ��l�KXP�%�c�K�2�|�Wg�e+�g9�c��T��ШE�ge��w)`i~��M�>/�D ON�0A�U%;Nc�ُy�LK@`c!�8��`�C$MJ���<Æ��P[{B|<��mͣ d�/�Z$����T��A�i�9Ʈ�X!c<�0��"�W�a�EK�[>@�����j,FQ��jB���蹠(�3��X؈^�̢]����^�����uх�.�6R�Ч�1������ZQ��o�4*p -�Q_,��ڳŖ7��=��$4t:a[HB�uK���(��J�������~)�D�/�/���k�?��vC��r��~oQ�%y�#Ԩ{Y7n+j�w+HmQշ��܆���q��� b��\����.K�6[p�'�oQ�>��aph�Q}Γ�����t��e�<���[B�x�B��RN��M@Ǡ(R������S����q$��hݔ<^����eYߔq�H��" g��+��H���1�UQ���7��y��×H�Q2MM���EPOq]�����g��4N(Ft�Sn��T�L�li�<����m/�0��I�B�!7�H)ñ%��u��1�YVc�S�O5/+�Z~N���R��|G?� �gi��pT��bq��\�������+�ҹ����0RKJ^UI�)���}��.tsyy��囟�s����������_�H���g�yc�6�; -�w���&�'�4�)����=!����hr~�e�ɣ�?��Z({��ti+�!ݟ<�`GϰyP'ZixgSd���o�Pj�N���Z�T[m�r��d���M��r[K���Tk`Gb��Zȑ�VX/ǽ�#��v���b)85&��N}[�$s�������9��]�_�yu��:_\,A�����o�../^/���^>��<��(�m,Ƙ�>;��6�g"G���2���V�m�N�ry�6*�=��O�4� qRQdF2"�{������N������_��W�&�T#�>K;�p��Tɪ�>$jZ���Z�iQ�=��(C'�~�����V7�@�ۺ�����+J�n�p�Q�Wk�w���&��@��V�z��ż�T%F=n�:EU���E��Z7{�����QY��y�(�̅��a�:�d�"h�L��{�ca+)U~���j���m��.̓)�?;O�\ͺ��a[��P�o���#˶Ba��N��%���;K�h��h�d�R�[�UYAXA�m�(��ls6��w�!ղAg���6�ћmꨈ ;�V(��s�S:KNM:��Ȫ�����/��k�bYe�d�m�m{ķ�A�\y���'��=>�nHBw��uS��[g g�w���D3U$c$Z��.�#�ջ�;,�<�,��S�M���9���C�٧�1�C���Q" `M�%g�'���K,��V�kŅ+��E)x�'8�d��X7+���,1��B��G�`��P8��t1[���+�>,p �N�:��R�Q�� -�}� �Ҡ^��W�&E-U��Z��vl�|�5��<m!�ȅ��*��4���7u��'�<nS�i�<Z�H��R�����F|���H�4��-�-�I�l��WM��3L����| �?DŪTu���:W��}lk��H�ҥ���e�;�JL�ԊL�fM*��I��ii�5xS�<��<S��/�������9�&�Q�q�ů�륀*g��"�"�5!Tf~�Ss���./n���&�%�����զ���$]�l��"ױ��O�8묬c���u��jY~�]�ڐx� q#Q�?$e�vا<�4z�ÿ x�8a$�M�ѰH2���B�Ǵ]�5�������_5�����Z�4�%�L?e ����j�!Y9,[~�T�������Gs����:� \�p�EO*4���}N����]�X����$�d��i�w_�ނ8v��!=��b�k�>�Kn�n"�@1�2_a����t<�Z9x���$�6��%l�<�"� /�-�'ن�6־�ZM��0���B|��5��zwË�OM�Q���m>�����}�7��x���e&*�E�f^�*�q�Q��]Hp�lR�K��#����#�Z�u�#��\@�X�� �H|�w�'���U�T%��Y44-��Gi�ߦp6��oP|=��b�L,3&��� -���(��h���¹@2ͳ7I5c������fo���Lk��&����p�~+H�:�%m�� J�ԍ+��d��)���xg<���N`�l�HH��%��&5GM���i���7��M��������2�������4T�aѮٶۻ������'�-J'ԙ��;���I�l++$�8`�e�6��@C�F�-�^%�>/���S��>͓J�Up0֫:n��_%�,� �|�M�[���h)լ�A��-�&�s{��I���>MZ{+z��͊$[��(m]˞��j�9�ި�e���G�:��SO[���b +�Q_,��ڳŖ7��=��$4t:a[HB�uK���(c��%Lz{i��t��\"ߗ����{˵����k;��jy��J������<t�jԽ��5�������fn�sh��E����sb.�P�E��u] �-��з(z� pŰ 84�>��J��xg���2���|�-!q<��!Ah)'��&�cP)Nwq��ɩ��w��8FY�nJ/�� +�ò�oʸH��i����Ou$ES��ʪ�� +����������K��(����r�z +�"�����N}�uy�3���'#:�)�Jv�U��WA�4|���q�ハ��Z��$~���K +������:���,�1�)����_-?'EUG�Z[��~���4�k8*�R�8[N.� ���Am��t��y�EI�%%��$۔��A�>�H���<����O��~����������W$f�of�3ɼ1L�����| ���H��QqD���EY��~49��2����Ꟈ�t-�=im�����Ok��g�<��4��)����7l(�W�_�Q�O���I��q�Nb��bk�����]�W�50 �#1}j��HF+�����b{�x�v���@��-E��K����t�K���/�X^�/.��@�ˋ��W���__/�_\��~~��6cL}��q��3���WIu�j��z't��W��}̧HrO�8�(2#�=N���^�qv'~P�s�v �/d�+�{�F��L���Q8�u�dU�F5-Y�KW-�Դ(��xA�!kƓV�����q�w��m]�B���X���V�m8��諵�;`�YZN �g�d���b�P���J��*W�r��R[���TFD��ɨ,����D�<Hm�B^�0�z�W2q4a���豰��*?��[5�K��6{n� +�ɔٟ��e�f�[�-�X~��7U��e[�0_[���x ��Tݝ�y��V4I�t��-�Ū� ���6j\}�9���;�ېj٠��ڈ�a�`���6uTD��R+��{�9�)�%�&�qhdUS�HS�_еK�����w2�6Ŷ=�ێ�� D��<�g����l7$�;`ĺ)zܭ����L�f��*�1-[ l�������� �b����&�CP����S��!q�� +�(��&Ғ����V��%��B�tе���Ȣ��x��v����m��zU! +�#m�AT(�Vp��-lf�e��R�U�]T�r�(�jƾ�JiP���+^ ���� +ao-��d;��Y����}E���Z���iWQ��zś:��u�)�e�g��c��E���v#�K�SJX$Q�� a�����$�D��ݫ�&l��M��M�q���bU���w�f�+`�>��om�a�RX���R%&}jE&l�&F�$@qҴ4������VX_���т�{\�K���AB�(���W҅�R@�3��VE��*3?�)����w|��gzt}��TD���j�|�p��d���?y��X JקE�uVֱ���:�c�,�ˊ.PmH<{������� i;�S�m�=����}�0�x�&�hX����[��c�.m�����~W���]BU��h-}�G���Al�v5R����-� F��F}����пǣ���uKw���u�Ң'�U|��'����.o,��ZM�_2���4�Ȼ�doA;d�����z1�5��%�t�d�z��0�F�rj:D�<�gqB���6{UC�������l�Ek_y�&@R���K��!>���rB��������(C~�6�^^x�e��ɛ�s�y�ڲ�"�I3/H��8��C�.$8H�����%��\F{�@��:�k. t�wad$>�;���a��W�J�,f��g2�Q���)�Ml�_/�'ˌ�}�*��BC,�?���0ZD�y�p.�L��MR��81��`��[%�7���f8<\��� +Ҭ��kI[{9��0uc� +�5�f��~;��j��2�9�R?�_��I�QS�6��oZaks�͠n��%F�/3��L�/f�0#���> wX��A������3{��� �n�� uf��-/�lE� �� +��!X`Y��� İ2��Qv��WI���(=�����O��Cu����ۮ`�WI%�r��_S��D��F ZJ5ks�E��E�ƃ�I��^'i��h�O��ފ�us�"�V�@ J[ײ�E��d�7�w�#o�Q������Ӗ�~�T� endstream endobj 670 0 obj @@ -6742,28 +6737,30 @@ endobj 669 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 683 0 obj << -/Length 3271 +/Length 3269 /Filter /FlateDecode >> stream -xڭZYs�6~ׯ`�i�)�77����TJN)ָ�`�T3� � M������"-;�U�� �������-7v�3v3ޜ������0Ë<+��]� -\Ϩ��=�� �%H�<3f�l���)ץ��47� �^h�7�b����ܩ����:���Bny�F��@��ЊB\4|�qm���Q�B;��4�=hJ�'d��u�/+X��b�WcI-S��q�݁Z�\��Fdyn�juZ��m��J���(]O�]��t=�&���E��c��G���g��!(�cEn�aGV�F)�S�����I����;Q6U݊����g��e����l����0#��F���$-����q7��rl�@���a��N���4��͜��-;�%�^�P:\����q�U��x�e�� -}m<}��rp�8�U*��@���܆�����z@<��:��E��"U��k|4=�[5������?G���������-���$\���=+۹�k�~G�=�b)P5Q���))�ߞK��2k�e�P��L�I�:�s�N����,!�a��u���?g��6b���ry�����S��8�lv��Je�������V/,&�;��mE�:��D�^>�ܪ�!�/��T���������nn>�.)�m�����=�vY�Y��F6 -!�]~�ǥ�+���h{}uss�㛿j�q�O,���������>CR&�Zp\��h&,*DZ�g�:��I=�2��72���1k��z]���}^�Cu��+���=��C�{K��(���i��n!k�=n�E��5�?(���gU{�A��@G7`<��)����� -������~u��8����Yl{�û�?�Y+﵈Szmr!2�B��i�6nد�N�r��d�0�|$�տ�́T K�9TB���z8d�H8ܷ���}�V]�j��}����0|����^ -�/�sB�C ����\"5a��]y��Wu������$u�r���~3��/��FlW�SQ���402)�����2����UuxP0x�� �� 1i���q#�1(4�(��������b3�v��Bn#qM���B���dLS��≎���f���hN��#�f�5�)��k�,���� -���K� �D{�f��H(��^sյ�����E�*�/��Ǚ<����PƑ*��d�,���@��7�u�p�ÕPU`S9��)��j��5���m��%��Ȉ}#ڣ�"�&l�b��1��ʄ����H��/���`2[c͖�����ׄz>$�X�5S|6��c�(������柔(oiȆC�7����4�c]�,��G�-��-�[�7\�7�������3�mgv^�4/(܅y!,ߙN,_�n�������f-��+���=�T��g&f�;K�n��5E� V]���c���rG���c��yஆE�L�O�v�f)EҎ���1edSuu�S��f䦊�t�� `DaD�[:ۡk�p]�����Lw��7f�Ĝ`�NS�>DA4�C%B���V����R*2�:Fզ���MJ�,��G��� �GM�yj���AV�������i�2�un:n��Z�����nA�(�:�ld�Ҿ�g�\n�R8��ԈT�Fө�H�s�9�F-r87J���@u�� I2������TFy�Hn-������.�B�����X��#�Җ�-��v��P�`_� ��� �?+S!�������d:M��n/��W/+mO�<�ᔽ��9�;��5#�;������\�:C��9\)��q�t0���ɂ�k;��)'ٯ�����Q�iY]�FFy�7^�,͢Ii�mF�Ğ�/~��V3!�x횼J@z�:% �����=���yS�Zc��x0:18��(O�������N�p�N���0&��jZ5���L�'v�9�����yE��V������Y���p�~�^g$q�h8͚C?��J���c�^vqm{���G��;6�2��T��j{;Spr�#.�P�Q�O���A,�2ud5(��<A�{�LU�8~��칫�L�Lje�Ty���+��^u�(c�z��Vb��V-��u�C�Y=�T�8�����$��ﲽа��b\*��k�҇��v�m��ĸz;�5*gp�vrW�~Cx����M�7B��F?��UUXϧ�ԫ��6����Vr -�^�`���yjB術��䦅i�U=*�T�Zt�� -mi�H]&�͵H)��DLu���'�Wi*%�۪.��w$��X�=E�����x%?z{W�Y�/ԫ� <Eor"��7K*�����XٯBZ��Ä���u� ����!��%p�P�>�V�4Y*�[GX%���b#�T�K25���dF���l%��s����W��"�R7�95�kD�5F��a+����j3�-p:��41Z�Q3�v���DmY��s�ױ�e��GTC��� -����� ن��n�����>a����ڂ=��*�9q]��u$U �j;�ك������x�@�_(wE|E�/��@~������s��k�`�gB���̅�T��{r_0�=���QV����+E=��7t�4zn]�x�z��k ��`��i�j���Y���1]����6L�X�A�}u�/L�X��YVA��-���6;QS�n`��dT�j3�����S&W'��D�1~Ȼ�����_���Ki��=�a�;$�����c���Z��!وZ^�E�cx�ث��J��:���/��L`�� l{���`����2�T_V E�$��0k(�C���5�*����SS~65�~d,T�&�l[~oDU�:n0{Y5�p5��:pޱ\�Y{��س��1��X���+��?�L�>�.]=���jn��GG6��|���)�@���X�n�l_��8[`3��P� ����? -[P�����A���5�̜��fs��䚬�#4O��S���=�ƴwR��Gj`7�b��9'J�?l'���τW��+��y:q�&�!M��$zg�h��I�6�20���Ɛʤx1O3��H^�r����'�� ~����M�y�0��=p�ž�:x�&ۄBX{�!����t�g�k\>*�x���8�P�[��!��V�u����K�.@jزA����6݀'n�ڟɫ�!��.=����{Y~#-�JY���mJ��XX-l�-��+�X��C�lW�������1(B|���h� +xڭio�6����O�I���b��t�n<A?$���83����������G�$Kq�] �(����\���Ʈ9c��`ƛ3x18<�fx�gE��k[���0�g?=�*��d�h�m�^4ź�<O���h�7�Bˍ��,�s�������w|#��q���&�١�(|�qm���Q�D;���5�=J�'���u�/+uY���XR��zy��Cw��2c�Y�F��Z�7� Vb\�����i������'����Zq2t�G>��>�| A�+r��Xo ;��04�H�{�W�WM�?7� \݉���V$翬8{�(�]OFxF`����),�`00�m%h�� �c���P˱�����傜V;ci���9��[v�'Jܽz�t�.[���6�J5��R!��x����8�U*��@���ܶ���p/���[n��Yn@�<TY:��hz��jD�>1�����o�`��)�+�/��PH�BwzV�s�k�~G�=�bIP ��T;RT.�=�h�e���~�q���6u�j�TEѕYB.éo/�r���?g��6b���R< E��I'8�=����R�;4�n��Ղ��D]wR���Yg����ˇ�[58�]�%���]� +ھ �x�a}�������q����ZK��i���8���u5Z������=�v��?Ԣih�������o���^�y>��^���+��Ï�k�2iւ�?D3AQ9��<��q�8N�y�\���ȼڣǬ�<�]���}^�Cu��+���=��C�gK��( +OW�B��B��{��E��5�?(���gU{�A���n�x�S�s:����xw����������{��q~����b������Z1x�E��k�q���Z��L۴q+�~=tR��l'g�1��#�� �6TuY��U%���/�l��������G�U��گm��* )߽�CF.��B��*ԡy9�0���j��]y��Wu�YC��b�:Y�����L���æ����w�; �L +���RBD��P���Uux��`�6O8�ĤqS�ǍH�E��M��-w��/+6hw�*�6"����x:�8�&c�8��Ot,D\63��G<���H�Q���J��]�f����o_�� �T$��h�۬P��}�e���е��<�"�*ы}��LX^��l(�H���y�H�S�DBA��7�u�p�ÕP]`S;��)����5���m��Z"9��F�G!�EnM8�Ů�c"Q� M�/p�]m_|����[cͶ�����ׄ~>$�X�5�|���8���/ʺ��`�bj�'%�[Z��䍖��~:��XA�;��#���r����|#����^_�1n;�|�_8P�|!,ߙ2��7�Y�C��a��E {I��s�@u��1[f�,1��>>�k��A��.�-Dž3�*t;��8��-;�V���] �&�<���@��I;���Ͻ�)#����J�4#7U\�S�&# +#:�ҹ�]ˇ���9oD;Wg��P�1�'������! +�1*��j�����W�@�CF��Ĩ۔��I*]��Y����D��A5N-�=�n_�uUuņ)3Z��F���Ֆ�P�����F)��}VKq�h���](�F��N�PD�<G`���"�s�4� TG,! +�$�J��n��Je���b+jA�;B3�EU89�{6�8{�U�R"�� |�.Y`j�k�2�2�O�!#��2"�P�j+�OL��,���R_������� ��U$�1��{�F�w)��% ��\�:C��9\)��q�t�P�s�d� ݵ�)'ѯ�����Q�iY]�AFy�7^�,qѠ��6�|bO���I���b�A�&����IY��d���}מ�㼩f-g�1nl<X �d�0�Sh�`���m'�T8ᤪ�0&��jZ����L�O��sZg%�5� +HU[5G�_p7�κ��`��Ň��s�:#���@�i����<�Wr&����k۫�~>z�j�c#ph쐌@M/TRmogZ�\�K9d��.��xK�L� J�2O����&S]!��ء�=wu���1B�4U=�s���a�:��c�z��VPŠ�{�[%*S �p���z�8q�c��Y1H�;��e{��~�q�@��Hփ�o��%čЛ�Q˨���3��\����8 ��o��:5=��-���z>���@� +�ئ��F��U���Z/�p�Wur�<�f�$&3�ianՌJ45�$�ɾ��X�<R��xs-Rʦ#S_���� �U�J +嶪}�ɳ2�iO�w(���x%>z{W�Y�/ԫ� <Eor�eo��T�e#�r^��t� ���Rd��C,�K��}��>�V��,xY��#HI2]QlD��t��L �}�l����k [�2��йA�U�+^cH�Ӝ��5"ߚXF��%�V�%��8�-���S����8^�{�6�����9��X�2x�#�!X�M�����clC�M�ik(��?a����ނ=eH����ф�IUC��Nh�E�������x�@�_(wE|E�/Չ-���% +��9�l%e�`�gB���̅5T��{r_0�=���QV����+=��7t�4�-7�.U�q�����.��`��i�j���Y���1]����6L�X�A�}u�/L�Y��YvA��-��mv����Ѕɨ��f �mE7.ЫaM�\�X����!��f���~��,���4��G���J�O���ch��>�d#jy�9��c�^�+I\��K�?�`N�3��r'p���Uu���,iH�OE�e�PDH� +f �b`sH�5��T��9�vj�Ϧ�Տ����d�m��T� g/�F���w]�;��>k?{6|6��?�����aCw�G��ե����]�Il|�qd3���7m��$�_k�8���[-�W?D0�ЌE>����@t�Da���~�p<�3�9��ab���Us�l�\���s���ty�?&�G��N�����C�f[,�?g�����0��U{Nx%i�����h"����J�w��qb��镁��4�P&ŋy +�Q"y������p8�7� ���7��Z�؆�qwu�{.��p���69�*����@-�I�{&���"�Ǻ���u���*ke�Z�V�vI?��l E�@���M7����g�`Xmp���O~���l�z�����mZ���,H�nK7��8�g�=ە����T�y0B���/��h� endstream endobj 682 0 obj @@ -6803,7 +6800,7 @@ endobj 681 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F120 619 0 R /F44 228 0 R >> +/Font << /F45 229 0 R /F122 619 0 R /F44 228 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -6815,15 +6812,13 @@ endobj >> stream xڭ]s�6�ݿB��6��w{��$n�N�slg:7IgG+q�J������ H����8w3�� ��"�����ζ;��9/N`�p�~���i�RΝ$,B������g�K��Bd3] -��|���y؋;���a�;�n&�a0�t�ײ��q?rℳ�d��0'�&(�Q�y��TνL?�0������A�X�����D�_؇ոO-��r%�H-2�� 'ea���Zw��+y���>�z���5xH�Ò�&o�8��>�i��^�,��>K�8v�7�HY�$N��y_λ�Ӻ�oN]'�+Yuu�������_���A�=<NR�i�����9L��x`T��j����S:Wc�/x����\� '��ֹo���1x1�W��H���^n�l��/zUH��c�髿ۨ�V�@}��,��8An���aʂ����� E�x��%A��|o$���I��(<.U��*+�'�͖�9*պ�ڻ��G�uƓ�qA�($�lW�jo��b���ܲ�u��V���Յ � -�~ ��ޠ�ҧ�����r�H8��5,�ͦ�f�wˉ�Y�����Ϻ��J��Z�z�8W{1|��#�����R������W�g�竷�.�R�[<1�0oc�u߭n[���q+���R����l/We����S���u�Q[M�'�C\�� Tп�z(E!$6�@���ŕ��%lG!�^5�u:�;������9ė�@�*�sY F! x��u����8Lʉ� �܁X���)�Gɢ� ��0 ��NuD��]��(b1P�� �!M��3��uY�|/n�zG$��r�>��o�+ÐT�bX�ItT�i>S�G� -�������k #k�Y�j:���C@�p4wͳ�~H/�[ρt��=B��[� wt%�y<��\���v& �lהZzA����E{��~o"zS��0�6k�Iy��0n��R��بR>^�6r��a��͂-*rL�`d�����VE ������@5�aVҠ���)~m���d1�Z�֍M�C�����̒�I��FuCQq<�������M������}O���g�2�I���������:������������9dԷ���b����d+Ϊ�H-sl����j,��ޏF�����d7#��{<�?����˺n�0b?����Y<X����}�0�qp�&k�*Oj�2{YY���]��g�f�ʹ���Z�����;�Ά�Z�<���v�bZ�������c�2�P��Ѐ�t��m���$�a�!&>AS�le^��5V6趠V<��(�tZ���yhF-�oH��梗����M��0&���[*�%���JlG�RG��W���X���0 /�!֍�n�B�|p��<��� ��s�Gf�7�yD� q�]4?f������,� ĸ�+b��|��eT - -&Z���˦�]��M�S@vg�B{؝�����&��?�}� ^̒0����O�L�h��`PB����Є۬3��@9�rx-1G�3��4�Ш� ��� ����گ����i�������I|��Sp./!�[����� �vO�(g��r?8k�^U5��~�Y��U���'�&��Z+0���}٣���=r�gu���z��x����A�@�N��O:�i� -wh`�Lw�D$�c��z�5�`�;��B�gL;,ih/�S@ʧ�ϣ�#����aYMӴ)L��h�@�̱3bdf�[Y�f��X1��}�[��4 3������T�b���x[�?�2�!�o1�Z,��X�vʓ"��9t5� TW��$�B��u���V&��"B���=]A�=�7Ƚ�HU_��"��� -�0�)���z�"�ɪ��n���G�p#��L�J�If z�L� Q���U��<?��������oy������%��WE�:�~Ă��|�~���4��_M�4~������� tT -/���/����{J���߭e�éAv}��"�=����=���W�o�DŽН��� ����b���Y@/���P��"TjoxA|���7Ã�C��3��7LT(�ss5�Lb�GБ��S �'O�����|;�,�I;'�,s��]1MB�.�`* <=�v�#}K'c�#"�Ή;�ug���*$�d��1B��>=_?e��yV�+����Y��� �%�e�J�����6�;a�%�*�8�����j���p�|�?lB����TΘ�5���(�~���<y���p���`�b���&з�ǃ��>ĵj{�76YH��%����6k��q�UwĺP]SwY��PU��V{�<���y}>���a�Ym ��ݏ֘��%��|�ml�NL�NtG6�4p��L���h�=��./z 3l�����}�3 -E��1�V���&������ +��|���y؋;���a�;�n&�a0�t�ײ��q?rℳ�d��0'�&(�Q�y��TνL?�0������A�X�����D�_؇ոO-��r%�H-2�� 'ea���Zw��+y���>�z���5xH�Ò�&o�8��>�i��^�,��>K�8v�7�HY�$N��y_λ�Ӻ�oN]'�+Yuu�������_���A�=<NR�i�����9L��x`T��j����S:Wc�/x����\� '��ֹo���1x1�W��H���^n�l��/zUH��c�髿ۨ�V�@}�Y�q���?�qÔ�|�ݩ�p�,+K�����H6}��:8��Qx\�J�UV�O��-!s T�u��wS�����'��pQH�ٮn���i���}��e}�6��l ��#@Vt��A�'�O%�宑pn}kXԛM'ͺ� ��$kki�N�u'��+��{/�p� �b�F�G�7ǡ1ȥVWg�/^��.Ϯ�Wo_]L�x�xb�a�ƀ�[ݶj/G�Vf�v������^��'�/�H'���j���4�?N��� ,�@����P�BHl��` ��y�+��K؎B�jJ3�t�w4�;Um Ks�/U��U.�@�B�R�뜁)q�� �0��^e�/R0��EUL)a,��B�ꈨ��N�Q&�b��tC�"�g��범�^4ܴ��H���V}���TW�!��Ű���:�>�|�6� +R{շ�}�F֨���t�/j7����h�gH��^8���d�7z�`���A��J��xx��s�4���L@vٮ)��8�`Uu1����7��D��6iaHm�ԓ(�&.a�*���ѱQ�|��/l.(�&��ś[T��ȀE��ݭ������j�ì�A%e�MS�ڈ���bf����X�L� +A��%}���.ꆢ�xjQU�vi{����5[5���@���fe�l�'��5S)u6}���������sȨo/���Bm+���V"�U��Z����i��X"S����ɿ�32�nF���x�~��d�u�<* a�~<9+���x��=..^��ba*��TM��U�Ԏe6>�����I�.��8��|�im��e!����@w� ��yl!��Ĵ�?feo���"e�Mc���Y�H����I�?��CL|��#�ʼnk�l�mA�x8qQ��؏��ЌZFߐ���E/ �����8faL���/�TK0uG�؎*���M��S�~k{a^PC�-�#���By0�=���̏̆op�t$��h~�Z��3��Y��q�'�3W�BQ��!˨(L�8;���M+���~���ΰ���;I�%M������%aL-�ϟ������/�� ��2!N� �Yg�c9�r���<Z0b�Vg4��iʡQ�A^�eA�{����_!�6=�")CKQ��p;��\^B��{]����(&Q����~p���jq���N�[9OlḾ�V`0m)��GϽ�{����*/!�@w�@c���N������t:Ӟ.�����h�Hr�Pw��kh�wD��^ϘvX��^>L���O_�G�Gȳ��ò��iS�"�Ѡ���cg������,�*��b�:��=(�i@fPUQ����6�'��(eCj%�b��X,� "���'4D¡s�j",TA��ޙI�>���#:� +LjGE��Cu{���zpo�{#���E�3Za,S&���E~�U[�ݴ=�)�;���Fj���ؓ>����? �~� �6�=x~*��G��#��c<��v��7���KL�y=?� � %t���?���/���s}��i���$��h�Z;C=��{��^V��_��y���25A�[���S7���4.E�;zFs��{���%�n�\� �;%TU�$G���7� `$ +��^8�/���D�������ӳo�Ӈ0 g��o��P���j���Џ�# Ox��"��< ����>�y�p��D�&�̹ܳwt�4 �R�~������͎8�- ������;'�l֝-vG��ܒ ������|��� ��Y=��n�{>gi +�&���mn(�w�;�۬:석�t���d��~�&CcH����aOh�1�� i3(3�S9c*���{p�#��� �����5����k>�ŋ��g�@��gX�ת� >�h�d!� +���C۬-t��aV��BuM�e�^�BUi�Z�u�0�VB�Y�������g�5��u?Zc�.� ��I��5;15;�٤���2łzc�m��ʣ�Z���Q�̰��jzc���(���4[a`nF|��?���� endstream endobj 687 0 obj @@ -6883,14 +6878,14 @@ endobj 686 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F120 619 0 R /F44 228 0 R >> +/Font << /F45 229 0 R /F122 619 0 R /F44 228 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 705 0 obj << -/Length 2432 +/Length 2433 /Filter /FlateDecode >> stream @@ -6901,8 +6896,7 @@ x �� :�)�bS�K r�;-�Rc^�n@��#���c�F�hW�ʑ��0j����k�z)͊�t�Ɇ�z<�H��/��k��w���fݕ�a0��"���C2��-�b-��u������T��-M�R�|5���ʺ�L��?1�i(F� [������f�C^|�d+3��,d��Ү�Uf)DL���W��W.�D`82�S-��f���vd��-��M\:�Z�d�c�ݪ�y]b���������1W����&m�DeTƨ�C&����� vi�m]d��A��Uk�����}��؈m�� ���O���a��mW�������( 4�j���ۺZ�R���R�l�7�E6����R~i�p�D$�|}��*�b#*ƺ��߬�k"�� (�!������ �����y��M��w�Ή�����'�����k��i�F��*�[%�_pK�͔�.K�d��0њ/�����/S�[���#��!��D7�.M���*r=T��4ʫ�Y�O �8GՖ�3�E�tr�=uC�-���M�DV��7��u �DE��c��i2a����xj&�O(�➜=��[@��]O�8�jk��%����>���4�s���s�f�#��pPȊ�8����x2��� Z���V���r���oNM�ý���3�Lsݾ�k�4�������D��ݽ���f9@ �cL�00F����3�m��?v* [K�������?��@��� ��tVu��k]c��n*=��s4���ܐXH�Ёp!B林�B!S9b:�oF�/�n���,{d����2��dz�?�bQ���\g�vr*�CD!f�R�O�(���-�(�1�~�����WR��(��Nf8���Y��r~������������usq��ݿg�]o�����s-KY�j8�-��|�[p|��F!3�h2#�yaaEe����`��>u�b>�aK:0�r�zh�ƿV�9�����O�A����� ��o2�D��� S��>�Z��Ѵ;��4<�8�XתTQ������n�ZFW}e+&8�� s�?�a���i>���}p�.��U�@�ܛ -�>�T�T.�3[�i:����{���n��!��&�kk/"T�Zuf��[0��KS�������m�~y�E��a����Wo.����yO���{�V���HB[�����aB�M�0̎��Y����DD�,�Dڇ�^�����/L����86!�Aj��!8���o��=h���P?t9'G�9G�AL��v.�KM�A��/Jb�e��`�ifΉ7�&���*�n���M�z�����1���[9n�l�GBHp7���˨���v�q����NKwx7�����\�Mf����i� -�7�h���hi�����W:�Y���w��$�]��[�����'B���f�O=����$�Jx��.�+�٨�A�:kM�Me�i���~��&� $��Z-���v]mjn��U�m]�]�3/��b&���.�`Mژ����줽�ا#[�S�{�s�t7�ꚺ���{IQ�2`S�v+����r�7Ӻ��x��KO ��d������ +�>�T�T.�3[�i:����{���n��!��&�kk/"T�Zuf��[0��KS�������m�~y�E��a����Wo.����yO���{�V���HB[����3z�|�;�c:}���f�,���?K<ф�!����`(,�S��+�!�M�b>�=?���!w�������.���2��>� �������c� � �7�EI�c���L2��9�&��d�7X��������^O:<]?&�B�|+ǭ�m�Hi@�����s53�o��6��߉c����Q<|����1S�7�_������~-�^��Jg8�3���s��D��Q|�=�t�D�½�,��з1���=W /���r�5�6(�Bg�麩��2�sU��ϴ|Ф��8]�X�ڮ��M� �j������]�s�^Y� ��Ţ�IS�R:B�����td��}J{�pn��[]S�x;z/)ʼClj�ne���R�fZ���6p� ��x�����r�Խ endstream endobj 704 0 obj @@ -7080,14 +7074,13 @@ x Œ2�T��S8TZ8h�>L��J�N��0'�iޝ�a�*`:����d �na�Wc�Z^����W���5!�X �j� �QV"Բ�����6w�*�ӵ%�,��!瘆��5=8�@I9E��G�B(����{�@�F��b~s�@�&qZdy�?L>O;�P! ��M����A�0*C�f�ZO8Z�IW�� -��I� '�j�v ]�nӁJ�����_[��2^�Q�d��8��Elz,��}��я*DLF �A��������LY��3?�*�5GK�Я�a*��&x�����&�vH��u��v8�>ھ$�Teaۛ�(�/3�6�-����l�*�w��u�g�lV��xO$�?�S�LG�[r��QieR��&J���Ѽ���n�7٦Z�EG;�(�j^X�>�X�����x�r��)��ÀX���fLZwYC�#pabh��L����9�{�WӅX�wɒe�U��0�#C�2Y�`�h�qe�m�tV{�Ûoc �ʪ��H�h���i@XI^�%j��kV����3סA��6?B�`H������<�����˛lQ\�$a�>>VU|>� �`'T娃!�a�jaǒ�v���6���}���6��^!-Ұ�MV�"^��4�kG�,]�>'�h�Udln��<Z��� Z��g7k.�S��k�1"�s��<[�Ӫ��̬���y�l4�v�B����I�4��zgηE\�I�t�Fy}9��g@j'O�W�HkvW�����\a���e=���&���4p��=� -T�+,��U�孨�5�ҥ�g_qjd[Ts��DjPK(i*��}Oq4ݍ'�D�R֕�ּ(!#2.���\��x�6�ư�>�(T���&��Q��^��c,��lL�֥ʹT�����}�B�)(�m +��I� '�j�v ]�nӁJ�����_[��2^�Q�d��8��Elz,��}��я*DLF �A��������LY��3?�*�5GK�Я�a*��&x�����&�vH��u��v8�>ھ$�Teaۛ�(�/3�6�-����l�*�w��u�g�lV��xO$�?�S�LG�[r��QieR��&J���Ѽ���n�7٦Z�EG;�(�j^X�>�X�����x�r��)c(�a@���o +3&���!ߑ�014K@&���������B,��d�2ժvh�쑈!I��c�u��8��ضF:����ͷ�^e��{$�4Q�Ǐ4 �$/��`�5����?ҙ�� �~�!p0$y���Z ^gy���_��M�(.}������>t�z��r��X��x��cIj;�zr������P�b��� iX�&�j���Y۵�u�.m�[��* 267_�d�j���CL���5��)��5��ֹ�c����i�fYfVT��<O6_�m��Y��Z�OU�3��".�$]:Y�<���U�3 ���'��T�5���Ozp�i�0f�β���Uv� +s���p����jઉ��VTҊ�G�ҍ����85�-�9�l"5�%�4}�'�8ҡ 0���u��5/JȈ��8�*�y�^� �1��= +Uc��� �{�6ø�9��;S�u�r.UtAg�e�e�ƻ�h -���Q�F�04�^$8Ƈ�7�?���t��\ʐ��6���%Q�Bmn��1����K���g�����t|1�����������t2�/� p2���"+��z�I/*����~mt�s�q^���I�/�i.�C��\y}���٢9#|�V�k�5vS�7���a�m�$�v�l�`���`���E������h�8YLz�u\��N�{T�Pg�\\Mg������xzu9�=������g��FR�`��ə�A�:E��^�vh�Ϻ��n�EL�Q�;˚����:�j�يtO������� Y���F8+u�(��.�=0�1��� -�g���j������˒u��OY>�5�s�{����`q��R>]�bx���Tk>mv�N�iҾ��&��'eD�I�q8"˯�䧫�o�d�!�%�����r<���1Ђ��ͻ��x��M�o/[]h0� g�꼅�ϻЋN�p,S�w\������ఆ����Q}��J;����o-�O�.ޜ�>��M����_[�>g �76l-!8���1Ö�˧�?��0M�T,>��ϳE�7���8 -�gq�Yo=!��?���N�2��Eu�o(s�F�~�o�����6���r��N����x�ͫu������0 -���]�{u>��:W4����!D���#PSs]Cj}�:b;4z�SB�_9��G�۳�프�io�,Is;�H��Q��%�������`��N�� =��1~X������ h� ��o�;��2�s�� t�49�S�?�`m���b�x�~v&��x�Qo@�u���zZ3�m������o�j��cbtk�)C��D�[S�f�n{�F�Y�Y�C�f��\�i��7�-��7Š���m�ݛ�/��E�6�20bSԝ�9�x-`����U�/'{7Ŝ��M1������';�� ��bt�Zپ<YޘӃn�,��~�VEV,�|��{��_,�ERl�"Z�p��YeIi�����M�-�yӥF�"�_��`Q��uա� -�l`g!����m�r;JT���6y���$�lVI�o{�$]TZ��{H�m����Xc�����@���H����>���� +h��Bu��:hT{�Q=�� �����x�<�`�!�2� e� Ŷ��*I�P��qu:f��b*��xv�v2_Lf�<~s5~sv~6����6���̷��Ȋ"�^�uҋ�,�f�_�]��i����"n���z��P�=W^�#�z�h���U�u���͆��n�v�3 Ƶ]9�?X��=X��`�fe�-;&N��q]�hz������/W��t|~1�<�^]���c�#y�3���⿑�0���Gr&q�N��!�ס�����m�t��β&��m���k�"�S�!yt�k��8HVo��J5�&n��pnq������p�c�Ze�w>.��d]"�F�rM�\➫�h>X\ǰ���OW������՚O�]��x��������I���'Q�s�x���4������l�[�(A�@ �u���O&=g�`��|��8=��*g����V}����:o!�����.�T�W}��k�(8��=&0eT��쪶x�[�����7g���cSA|����֭�Y��� [K�l�a̰������5LS�6�<��l�� }n�A������E��[O���O�`�����pQ]����Q�����A�7�M���(��yly�i9�d�j��s�~y���i�z��^��}E���gng��_Q�c���\אZ_��P[�����>�ޞuo�$O{;`I�۩G����j�/a��ptݠ��n�pr�F�a=������s�4@Q̷���`ڹ��c�E�~�)�`��[�F�� +<S?;�\s����7 �:Tzz=��6�k����}�7Z5R�11�5w��!��a�̭)u3�_�=_���ڬ�!]3�U.�4P��Mn��b��\�6������"V�F��)���^�0[D ��*���b�e�^��t}���؆�[R1:^�l_�,o��A�]za?yE�"��Q�H�=�~��/��")6Y�A8�߬��4��u��&�ռ�R�x���n�(����D�M6��J{��6^�%*v|D�?�<��Lm6��ɷ��@�.*-@�=$�6q^~q{�1��MZB��zRE����H���� endstream endobj 731 0 obj @@ -7254,7 +7247,7 @@ endobj 730 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F89 511 0 R /F120 619 0 R /F33 531 0 R /F30 532 0 R /F44 228 0 R >> +/Font << /F45 229 0 R /F89 511 0 R /F122 619 0 R /F33 531 0 R /F30 532 0 R /F44 228 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -7265,11 +7258,13 @@ endobj /Filter /FlateDecode >> stream -x��ZYo9~����BL�<��b�X�z�q<��Y ���H�Pw+}$`~��>#ţ$����C6�b}dU}�+��E�� "��>��-�$#�#JQ(�D�Bo�~�h�9H�R�N��2�:o��֢HO��2�"�h���L���ce#N��S� �XR��j=�c!�B�T|��e��2tT��3� iZv�j�v�L��M��e�W�a�`y .I��,�]�0a)�(xU��G��VԈ�kW=�U<����[䗓���!�F���dqv~FI9�D���"�! -"{ދ5z9y����#��d��2/*�z�z���t�C�4��i��|M�:F6���fh����м�sFecy�$��'���]�@��Y@G �ӧ�MV�MWI�ن�:Y+�T{z��,H�Wa�(l7<`W>!G�ϰd����A��vt�)���̬�z�KVq�,�$�ו��"��J��A������.m%.��}\�jm�U�$" �~D,�q�D/ͬ�R���|YVj_j��}X�4� ��B2w�S�y|?eq�_��_n��\�$��ŶL��dr�ө��Iڬ�7�w/�����tv�x1����aዏ�H6Y�k�0��)r<�JR{�{7�*?��Ӱʏ��+'�V�!�n�li���h�U��l��h���[M~�K4��ϼ�z_˖�A��v쿞u`�1L PO�P�.������r�_%�4nǿ$�L�AN�8��8c�����-u��\�%ok���8tJ<ā�B4�@sX�I�gy�|���͗�ϟ�X�+�gS�ۋ'������1��.ZԊ���2��9�y�_=~�%��2Uh��ʮU�*��6�ǧ%�ԍ��\l���\jas�f���P��S� g���<C1y�Um�+��!J�c�Z& ּ��v����,� �J�⃭'��w�\���6W�m�滦e�4(TU���,�[���m�J��r�gk�P�#�~���m�&٦�g[nU�̹���w�xS��_�����,���I���l�c��f�y:Ҩ�{U8�xc�v[�G&u=qd&8b��{�aB���s�rn;����=��m�IK}I�t'�G��l���鼧q\hH�ߒ�N�GcEz��"��s�~l�k� -���Iv��9���y�=�X �qP�ߓWD7��P{�0����DqI8)���u����[by;�0�x� t�#�_[����t>w\����8���-��H���C�f�.��`���{�{o�l���aY*Y�**�����[J�z҈�Q:��7�5x��t������S� �#��.�-m�m�������?�өOq�{��z����W�u� �/�7�������0��������T��*�?��݆14,�nh�}�?���Ek�m���_���D�����ń�Ù��x�=,�t�.��2�b�]�����g?�k�r�����u9y�@ī��`�d���߭��|U�*k����^<�r�=y6�C��r�Ikx����ːG0����x q�B�!�x9b�v�u�S{i��KҦuN<�&�����N�oWf}��Й�C;�g�F�=���4]���Cl��f�M��#���u�=F`B? ����������C8��� r�:�F��h�כ��7���C�N��{<(~�����`k��� -��t�5�F�F��~}�����v%NA+a.m4���Κ�7�XS��l{0FgX�E,��؟�Gy�^��`���$�Y�A��s�K�§�\����ڶ1P���ζ�f�o���Ƹ�aP�M�&.�%]��+z�����wfB4Q��wyR��� -�/�u�j��a�I���Q �Z�9qi� �tmޫ�#��l���V�;�t�^m`�ަ,m�5/�6?��k�@�W��^�G�fs�'�Z2a��p�p1� _`� �e +x��ZYo9~����BL�<��b�X�z�q<��Y ���H�Pw+}$`~��>#ţ$����C6�b}Ū�H3��E�� "��>��-�$#�#JQ(�D�Bo�~�h�9H�R�N��2�:o��֢HO��2�"�h���L���ce#N��S� �XR��j=�c!�B�T|��e��2tT��3� iZv�j�v�L��M��e�W�a�`y .I��,k.B��a<��Sܣ�D�5"���U�`a�����d�d�9����?Y��_�SR�#h��a�����b�^N���j��cA8���̋J��^�|6]��P!��a6 ���� ZC�ψ�Qzo��z8�����0gT�0�L�k`z�[mб���!T��tb>}j1�d��q��m����2�N���ςt~F����1���9�|�%-�W�*m��M��@3�.��.Yŕ�Гl_W���H��~(�wuj[K��n�p��qY���W�����P��X�m��4��K�Z��eY�}�U0K�a��X7��q�܆N�����8 +�����/7�@._���b[&�@29��T��$�V˛ۻ��b��n:�X��M���������Gz$�,�5J����9�R%�����M��O�A�4��#=>��ɧU�[#[�)C; ����C�v�_;���G�D��������l���m����������4/ +��RX��m�.G�U�Ov�K��4n�Č��3v�m^��R�.��Y�Vx0��C��C�.Es4��4!.z������|y������|6�(��x���X�m�E�軼,���S�Pq�g���g_���*S�{��Z��"�k�}|�Vr!O5�W�b�͟P��5�T�H�� �:9�<���ɻ��jc�P��(m��^h-�$x��G�qo� +:��6�*͋����/��rM�k�\�y��ӠPU]dv`���n���+���}���C���������d�6�m�U�s�~����M���cF�����'�9���j�(�?̚�t�Q���p��Ɩ�Y�G�&u=qd&8b��{�aB���s�rnݾ����=��m HK}H�t']D.�l���颧 \hH�ߒ�N�G�Ez��"���~n�k� +.���Ivz�9���y/<�\ �rPѷ�+"��Az3���a���<��0��Sn���.ݑ�:�� +,�0��� t�#�_[����t>w\����8��~C$�M�a|3���A0`��#��#�7h6dq�,�,w���fk�-�C=iD�(�|�J����O���R�V�R���D����ڑ�� �����T^�����ԧ8ҽ�Y������x�?�����bvqysu���jvq{�m_�������3��C��X�@�����]�_���&+������Y�Nt<������}��R�t�E�N~��\�Ul����ߐ��m]��q�Q�.'��x��̟����x���Te����y�`��#)'ޓgS?$^�m�3���-!��2���9�44^G��?x���#&���N�g��N�%i�uN���!����N�OWf}�|�_.i��F<�{L���4]���Cn��f�}(DgG����h����#=~@(��#Xۭ����Cؙ�� r�:�F��h�כ��7���C�N��{<(~�����`kY5���|k�����U�>Ϫ�J��V��h��6;orc��M�+f�ك1���[Ģi�@���P������*�y���Uo��ʹ�=�§�\����ڷ1P���ζ�f�O���Ƹ�bP�M�&.�!]��+z��齌wfB4Q��wyR��� +�/�u�j��a�I���Q �Z�9qi� �t�mޫ�#��l^����w&��=��ؽ}��������l]k�m���>8�5����jɄ��T�A��x6�M��K�X endstream endobj 758 0 obj @@ -7464,7 +7459,7 @@ endobj 757 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F89 511 0 R /F120 619 0 R /F44 228 0 R /F33 531 0 R /F30 532 0 R >> +/Font << /F45 229 0 R /F89 511 0 R /F122 619 0 R /F44 228 0 R /F33 531 0 R /F30 532 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -7478,11 +7473,10 @@ stream x��Z[o��~��اB��^�e���Į�"i][9yH����D*��m������q���I�ݝ����������꒢eyD�t~D��f���!�H �!Q���G�~D|R��b�l�a_�c��f�n/�4��7� ���x3R�3)ƒ�=q��r�bI���`�)*���>L�~�2�W�#� iZv���0��NsPu���7c�Y^c���W�g�u!�X ���Sܣ�D�oDrkk���V�9[;��&�l8(�8�4�5��������P��G,āR(�y����Y^ƫ��5�N�2/�$����tt6�C�4�|���7�Z��O��S�3�M:p�F�}0gT*���X��VK�o��|� T��td���sk�EV%�"��<��u�H�A���g�2��" -.#p���+ő�3,���e~�Si뎎�bBDs����\^�f��.�$��/�I�n���6[;��Ub_�l[W���6*�d�r��!����t<&�7��L��"��U�-�I�/���nSF�HT�4��m��n:��tY�URM��ň�ȃ�>���_Tb����u�l�h0���.Ҟ��ϸ�MR��E�txX���� �5�\���홫�[�~�ڹ��j<�PVEWu���A=(�}�v^�u��۾��u��`�@��PJ殒9/�0%�8�M=�ѓ���g�U�e�=7L; ��"��g�M�V�Ne�Z���A��Ԫ����l~�j��ꗟ�OOf'W'���Ur�<+�2/��f�R$Q�g�h�/ ��$K�hm�]$�?�>\�{���Ssw����wJ�rU�8�4��cT�� 1�Å�]Z��9.���4[:jSG�J����,��x����;J�O�W�Mu��>�˧{��P(҆I��sN����;wv���q^g�;l�I�����?�A�o� -�����Q�hDs����/�f��f�����QT�VUȷ��U�w_"o��^�<1�1 ��x2�����S���Kˤ� ��ffl]:M~���z�ʅ������ת� ��0!`_�f�t*>IJ��*-��>��|� 8i��ö�j�_�:��9W�w&��r�Np���xeU6!�m��Xئ�*�����a�4c���".mN�?1�+p����m��4�i��q��Ǥ���D��n7�Q�I -ȅ���X�]&O�hY9�B�*�5t�w����\���>ac,r}���ř.�/.^^̮������'��"��"�������}e�/���`�]U��S%U܂�Cw}Th�����_��3?�w@��-N�a���� -����_!�}h������勋�P������l� Y|�{_+�8��v�퇉ۃF�*�z�z���C��h\g�F��`�C�����W��1Ѝ�5��|(Wv_�T'��4>��P��eR�jdž�N��69���.��~3�M �g���e�ߥI�y���J�����J<��zcz����$�ө0 -!<�J9�<��zM��c��� Q���N�7�(B�k��#oБ���Bp�yC�~Y�%�t�(����Gx�M��E8(ݵ.PNu����Ed��#>ԙ/ -'����C��TF�|��DG{���}t<�BwH����R��(V\��4��{�ё7Z�F�^�K�7d��.B��?^�ů�i������v�)�7��2}R�(���{�A�j����0�`h��=�.��#1�Զ_�����p����5V���</^0;T M���9� s.{�a�����G��c��br�^۹"]�tɼ�,�D�*��̛�eT,���(�Ê^��6/��a����v���In�H�E���vJM�E�#8Q�M��J�҃��t�m�PQ9�T�H%�����̢��t6����}Qk���n �&�u�$�L���A���x�,Dv +.#p���+ő�3,���e~�Si뎎�bBDs����\^�f��.�$��/�I�n���6[;��Ub_�l[W���6*�d�r��!����t<&�7��L��"��U�-�I�/���nSF�HT�4��m��n:��tY�URM��ň�ȃ�>���_Tb����u�l�h0���.Ҟ��ϸ�MR��E�txX���� �5�\���홫�[�~�ڹ��j<�PVEWu���A=(�}�v^�u��۾��u��`�@��PJ殒9/�0%�8�M=�ѓ���g�U�e�=7L; ��"��g�M�V�Ne�Z���A��Ԫ����l~�j��ꗟ�OOf'W'���Ur�<+�2/��f�R$Q�g�h�/ ��$K�hm�]$�?�>\�{���Ssw����wJ�rU�8�4��cT�� 1�Å�]Z��9.���4[:jSG�J����,��x����;J�O�W�Mu��>�˧{������i�$��9��~k��;;���8���6�$sk�dr�� �7J�X����(]4��9�db�W��W���������(aM�J�*��Jת�/�7i�_�͘�d�<��?�c���)T�ƥeRUw��wV�. +�&��Ut=���E���T�k��Єoj����3S:�bYOt�if�UC����^�a[|��Ë/pT����;�B9r +'8�\n���*���6�� �i,l�XB��U�t�1�YL�6�ҟ��8���o�6�f�شS�8��cRT�vK�Fu���(�$�B�\d��.��Y���C�S�?��������]@d��1�>yy��L�//f����Ap��� �WI�Dvls�>�2��a����0䮪�U����*nAơ�>*���bt�ï�Z����;������0�����Tq��Z�>��chq�����s(������|6��,>齯V��p;�������Zy�\=���!yH4�3S#�R��!CÇq��������K���b>�+�/�E�\l�b(���2)n�cCN'���FUd��E�ܦ���3^E�2��ҤvY^�qbe�e%��q�1�CPon������M��x�^���x���g�1��τ(�~e'�k��5��3�)� .ן7����Q`I�I�~ԁG�t�:�KX���]��T�.�]�1G|��/ +'����C��TF�|��DG{���}t<�BwH����R��(V\��4��{�ё7Z�F�^�K�7d��.B��?^�ů�i������v�)�7��2}R�(���{�A�j����0�`h��=�.��#1�Զ_�����p����5V���</^0;T M���9� s.{�a�����G��c��br�^۹"]�tɼ�,�D�*��̛�eT,���(�Ê^��6/��a����v���In�H�E���vJM�E�#8Q�M��J�҃��t�m�PQ9�T�H%�����̢��t6����}Qk���n �&�u�$�L���A���x�,Wv endstream endobj 788 0 obj @@ -7669,26 +7663,24 @@ endobj 787 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F89 511 0 R /F44 228 0 R /F120 619 0 R >> +/Font << /F45 229 0 R /F89 511 0 R /F44 228 0 R /F122 619 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 817 0 obj << -/Length 2068 +/Length 2070 /Filter /FlateDecode >> stream -x��ZYo۸~ϯ����TI����<���fФۙma(�bk`K����b~�.���i�t.ڋiH���ٿðG��%E����9"����B��$���Rp�}.P���_?Y|T�Pd��Þ��]Gՙ�Y�m�/�%E�U���R��V��c�z�(�)��A�X�e����繜)ڿ��$�����j�v�����Gg+����nf?/�.��J.A���XF]�0$����?+UCh�PCzD�Fֺ�CV�9Y�-�C~�[p`2p]L�������.�����1�� @�4����ދ4�.��Q��iVD����_�0���~ A�����=A3��P*Cwz�J-\�D���eT�����������]S��m2P�a�ӎ�����,)�yq���e<��@���Cۣ��Adb��C�R�)s�#$�e1�>�Q^D��m�e���Z����x2Mˤx��p�^F%:t��MCR�([qO<��ų���h��ć֓�ئ� ����MJ�7W�˫�d��}r���lV���r��6�~��JV�����7�����",�� �^��tR�g��I^^��,^�H����S/�4gL`J��&��={��j>�`�*1��"N�V�g? -�V�G�z&@�!��z�#*qz���4ˢi�VQ�Hg��vxTB:z��� -��}��w���.��U0�0��\��h�B�Edxo������v[��j�N�[ZEVN�2���a�G������(��'�?�b�2L,��bJ��X��:�-�e���E��GP���c�5vq����g���LFW�������NF���׃a<�[3(,���e����r��0O���Ǵ��u%Q. ��hc����������z��te�ѥ��KovE���j�hގ�$-L�..��m��"z��Wپ)��ϟ]p�}��/ ��|s�FۿV�OL;�d�����:���k!f��Z�>Ԙ �����0SQk`&7��H쏙�ko�TL��L�I�� -a��V+��0�;��{��d+��M���JgIUܤY�1TY- 6� -���*��^�\�w��OPbj�4�Lf��WQV��sZV���̎�����Z˸��u"6d�-x�P~'�[��n9r -�y���b<��x0�P�����|PY�~/K�פ�;��Z˓A���E��Wi��zoީ-T�MÍwCB��"�n��rXR-\/>��]�X�Ehz7Y��� z_����i+�X���]�Z�m#�� -�s�n5ʓG�<y�� -���ȴ��SÈnu�;��1�|����ؘ�uAQ���)o���pb�4��D�Ur����'Pzu����c��d4��~�A�ׅ@}�<���~ N���*q��C���0M~E���������5KJU��*��+;| ;.�uYtj|3u���4{T�!��n��w�(3W岈�˖$�������3��c�B����G�w�����v�-�����9�zOj���a`��b�y:��Md��s@��E`�<�n�-�K{���Ntݢ��2<��ʙ��.�d��������.�424�6O�i���jA����燎�(D��P����|��i�59����_8�W�$��W�÷B롍sp?W��<6�� 7�� ���3۞&��j��C��y�GOTpm�ؖz�P�|�I��Wһ�����3��`�6���\����D�JoՈ�� �2U�Xd�St�tf��f��K-��m�-tj�����6���Tr��l�Go�f �w�@?�R�R�k��+�8�nNr)p�u�M����\{�]c�hoڼ*o��Z�^��C�4a`��$��ʱ������߉)8v�z�v]�x�!�_� ����{���|�����m�f�g���&����<�f:ݪa�|4�gq�N�p�7�^���2��<�,Zg鬜n>�h���.�E_��=an� ����m-*�|�{Qt��\�/���b�o�E���ɬTT� -p����^N�r�u�`\��ʡ��9���-���2`͚ +x��Z[o۸~ϯ����VI����>���fѤY����Pl��\]�Ӄ��;�Ⱥ�N�{�HCR�����a���K���AsD����|!HH�%�(��\�,B7�~���`�ش�Þ�]��j�z/�����sI�t��3���v�;������e��Ё9`(��y.g���(A;�~8�.q�����j�������E')��[�ϫ�K-��KP����1!I,x ��jU�PV"��ѵ��ЕNך��ɯ{+B���������KJ�b�}�o���K������H����a~�EI�fE4=|?��`0n(C���l(�o�4��_�2t����r��EK4j�]FE�k]� �AN�9�55<ݦf>�(1Β"�ga���pZƳH+�o<=�=zIC>�>8$t(�29Bb�[��C�E4���YQ��I�͝�m�'ӴL��8W�e4U�CG0���4�'���50��#��Q<�X���O|h=I�o���)�&R6���_^�'������efˈ�̀���y�I��V�z��7Mǿӵ��aQ�O��:���r=�L��:�f�Z����� ;��LK���kY2��C��W�q�ֈyTq2�*=��pض$2�3��2��A����g9N�,��)`�t�?og�G%����ln�pٷ&x�<k��M1!^�S ��Q��+`4^DF�F���;��hi�կ�﴿�Ud�(3�z�y�Y�^��O�îxR�<։+#�"-A�-��{�G=ߘ�ڊ\&1h�[|� oEe�_��]���aqF�9}���jrv�[���ɨ~�z0�]Ƣ�k����L�<�^nL�i�uŘ�1T�Qe��;�6�z���].l�/k�ʱO7F}�R@~�>Ԁ�z�ͮ�e��x5�h�>�IZ��]\,>9���:��x���M�x�|�n�C�A��4\���ml�ZS<0���.x� +bB/� �{�����k���Pc&�Q����߇��[3a��L�b���1S �3�'E�*�a�[������ND�M���'7�O>(�%Uqp�fa��Z@l�;^$�UJ��p�L�*�O7Pj��4�Lf��WQV���[V���E���� wrm�e\��:6�<E���s�[��n9r +�y���b<��x0�P�����|PY�~/K�;��Z˓A���E��Wi��Foީ-�Y���膄��EZ��䰤Z�^|��i�~�.���n�t�?���L��5u��V6�{��}�V���F*)�$�& +�j�'�By�����ȴ �>�F��,w��cr����ٱq��6E�Bxا���;�! �W ���@�ա.�V��ד��b�f�Y��^�E��b���58ϯ^��=��{B��,�A�:��}h}�_�*�Y��Tջ�×0��X�E��7S�q���f���5d���x�z��2�qU.�x�li��+J +��!1So?�\!$���q�0pW2�n��|�~��Q�I�W;|X�;Og���L�{����G٭�ti�oհމ�[�4x�/�'3P9S��E��#����v�%�F��߆�I:-WQR-(W�Q������5>��8xqoM�~fr�����C�I�����`�Ah=�q����g��3d��3dS�yf�Ӆ��Zm��(0?���:\�$��#�8�sR8����.���0���-:�A�v��QB�!E?����!X٭Q�x�j�lw��ά�!vTjy�l3�m�S��Nw���J5R�1Һm��%�����K�J��ٟ��㬺�ɥ ׅ7���SsMv�]��i�qvk�z�71�l����*�ƋS�Q�~'��A���uE����w��~e&Tlc�N(���K�-��"�}����?��X�V�0��t��a�Ѱ���:�å&���?�e:y�OY���Y9�| +z�,Ve�]�,�,�.4an� ����m-*�|�{Qt��\�/���b�o�E���ɬTT� +H����^N�q�u�`\��ʡ��9��-����͍ endstream endobj 816 0 obj @@ -7874,7 +7866,7 @@ endobj 815 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F120 619 0 R /F89 511 0 R /F44 228 0 R /F33 531 0 R /F30 532 0 R >> +/Font << /F45 229 0 R /F122 619 0 R /F89 511 0 R /F44 228 0 R /F33 531 0 R /F30 532 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -7885,9 +7877,11 @@ endobj /Filter /FlateDecode >> stream -x��YYo�H~��觅��>yd����x&q2�<yH�&;��7���S}�"i)��Y Y`��}T�W]��u4�|KѼ: h�:;�D!�%�H�R -�!Q�Ч���5>)Xj1�n�a_F�^G혛�(����@�XD%���I1��+m� `�}�KʴP��u,�Q�����s���w(G;�~>��p��e��F��)8:_qtR����}�.X^�KR쇢˚��",E��(�QV"Ԋ���b�dw`a�t� ����AɐsL#_�1=8���r� @�O�E8CDv��)z?yQT���cA8�RyU��J?N=8���P!��a6 ��� J��WD��ݙ�+�t�h���0gT�ЖL�k`z�[�Ѯ�˳m��1������y^�y�Y�ۂ�&K���?�J�F��@ �F�>!G�� �U��,U��c��E�Vχ�<�*G��Q_�wF0 ���l<V�2l������U����'��WPū�2�����*�]fU�R���WV9-@u��R?"ܸP���_|��(��C�&@�����)z��=f�������Wӳ㫫��o_�_L�x5,dž�`��|[TU����U\��;�g*We��ʦ�J�l������ |���ډ}�10 p�T�@���h�9S��!�{uȍW�r��PR� K��Q��u}S�������4��5���cWRf=�b�L���"3�uYe' F^/��њ<ﴊk[�$�>ƕn�Mq�v�pk��}?�Mlm5��FaӖ���T-뙈5�4b5;I���$Y�M�:-�[�z�ᴅ �JQᘢ^���|yz<=�|sqr}y<=s�(�b����=�V��Z�Y��X����y�[����Se�H@��wL���&I��Z�WM�V@=�?���}�g����H��H�z��N;���oo�]������5uz�w�?>�a��5�/��z���fe�-BY:�pQ}/����o��0���<.�Ս*��ފ3���-��~��������K@�M��Y�N!bgUsӹ�" ���aF���s���*�aE4a�L�l��;\��2{C�;3$!���8[��Lb4�yD5�zK���<���;��2���i�=�vRgn�����{�M^Ć���%��zt�ПZ�",��J�_���l�PB:�4����|�S��?��`U�M�nO'ӝv9����gv��όfLbJ��徂�U�mi�ք��kX���X �Zh�i��z<� 4 p�gADŽ����f���y���YK�ajy��b����[FV]6@홢%-DO --a_�2J,��<L7Q�ÐYsܨ]��|���z*�Qd���V��?�"������W�l��ĘX��s�.�0En!!�Ń�Ńt�w]voE� #�6�f�EY4��^����3���g�a�l6nU�����~��e��0���14L��l)�<�f�C}�-��ׁ�Hwa���75�%�t��Wr��[=_��?u�&'q�j�꿀j���&��2L�2���5�-a�(+�O+�H}<s ��=?��W�C)'ދק~H��]�g�ɽ�BBϞ�f���H�5p��<���b&�3F��@2�{&�$�3��S�>l�/�&J_�g��?٦�sLFh���r'�ߢ�pң�����:�� �G�cJ��� �Ad����/�C�̴i���&���z��^��n�6��5�6�����C� ��8���ю�(wc����������'+�4�v#q -Z 1�4�Oeorm\�MݫX7ك6��n3�EӁ����~+����q�-�D杋�7�����d�br��yi+�o�J*&�˥-+��Bߊ��c�g���Y�U�V��25�3οX�iV��*^��D�{�,�ڐ�+*պ,�&�`�O3��t @D]f7M�O\�K$�ZJls���L�^��۫�[�s�K��z�u|�K>u��<m��Q�]����V"c��+Ʉy}�K�vL����:�h +x��YYo�H~��觅��>�f���=�g'c˓�$h����H���Y̏��IK����b���죺�ꪯ����[���AsD��| +�g(!H���"%�De�>�~��H�R�v��2�:j�܌E���RaR�F +`&�XҮ�'x�)�Q�(��i�ZA�¡��A���`Z�;���B?`N8HӲ{Y#t���8:)@���>c,��%)������"��K���AT�=��J�Zq�#�[�����!��.�A~�8(�8�4�u�Ӄ�_�))ǡ4��X��P���&���EQŋC�jr��UQ�i|�q����� +i<<P!�Ti��?�@寈�Q�3MW�9���]�1`ΨTЖL�k`z�[�Ѯ�˳m��1������y^��2��"�gM��о��+�h��g�X(�<�AJ���EY��F�UZ/��z>T�IV9�E�}`��$p#`~��Xqʰ R��J��E�f>ٴ^��*Z��Y>�_`䴲�eV�ib�Y���*��.@�Ă�*����n������p��h ������c �C�Ӹ��tvu={}�jzv|uu�������Ƃ�ذ��[�o��ʴvUE��N�Y��e���&i��Z���}g��h~[;��4c`@�:��P@���h�9S�Պ��Zq�նܸ?��m�2�ܤ��u}S�������4��5���#WRf=�b�L���"3�uYe� F^/��њ<ﴊj[�$�>�S�\���lŰ�5����&����G��iKTvj�����LĚY���$Mov�,Ԧr�ѭk��p�O�(5����g/_�OO/�\�\_O��\<����,�x#~OD�Շ�.�NˬHv��}b�߭�� +]ܥe�H@��wL���&q��u�r@T5e����!�n�� W=s� ��E��Gz؋�w�I�/~�x�������5���ӿ���a�~�1~9��۬�7+Koʒa煋��h�%�0��x��d� �f�qѬntPqf�V�� t]h�W�cU�6�����^�o�4�5�"vV57��} �����f�̍>�x�����QD��D�F����.�7��3c@"�}���j�$FÞGT#���;��S<�c�(�F�À�1MC�g�N�̍>s��~�����pb:�{e��䟇�'��V������~'['��N8U8d����v�������������d��.'`�����ьIL�?��W�=�J�-mҚ�J����V¶��~��@M+��,�^�Lp�?�u�4k��!,]�o�����U� PA{�hI��HKKؗ������M��R̚�&݅8����BEv�M���X���4V�*ـ��\@��2wn�E���-$��xP�x�n������`���ߌ�(�f��k�p_b&�"���0l��ƭ��3�[�/�����b2v�C����-�g�l��û%��:p�._�������*@���V�W���O���ITG���/�Z���E���F%�����q `K�ũ��xRč>�����z�ʋ�顔���S_�wW�kr�����s��q�i��P[Ch�P �����g�h� ��t�{Na�0����J�(}/��O��d���1a�#����N��E��G{+�ۇ't���9���PI��� �Ad����/�W03m�k�1:�F�ި��륛�ͺ�m ���q���P�BC#-�+��{��8��&�<_Q�R���x��f�n$NA+#���T��&��51�Խ�u�=h�_�6�X4��9��x�٢Jh�~c<�q.{Ov�)&g����B�6���br�\ڲ2�/����;z���uYm�<*s�?����dպ����N���EV�pEe�.����"X�Lo6]Q��M��U� ����ܥKw&n/h��U�[�s�K��z�u|�K>u��<i��Q�]�e�ŭD�8��W0� ��N���,F���Ĝ�W endstream endobj 839 0 obj @@ -8024,7 +8018,7 @@ endobj 838 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F89 511 0 R /F44 228 0 R /F120 619 0 R >> +/Font << /F45 229 0 R /F89 511 0 R /F44 228 0 R /F122 619 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -8040,11 +8034,10 @@ x Y�_ul�l�\&��G4��l�c�F���=-9D�q�&��dЃ1�Q�%s�ÀI���9{�~9B��5I��TD[T���:p�r`u?����O,���0 9툥���ĉ�<���e����cMZ>��ms���1Y�%�M~;Xp`��q(ן���߂Q���4���Cbq�D�>�������l9�H�ݑ�ʼ��l�y���p�S�,<�1�K�?��q|P*q���k9x��3�ʀ���AD���'����7ts�K�BD"�b4|�e��*�(�*�3�q^�s�:Ԟ{g�� � ��������B�bɭd-@"��D1:������t����txv�~�����d<m�%o�����ӄ��e�NWB�Y��̳�����R��[���i\o����Nu���)P��E&�d�y��rV�yF�_؞F~�0�5��>�������� O���/Q�U�u��զ�t��������dM�;K����Ԣ��\�V�"��CU(�NK1�ԛyR�IYO��,���lS�����(w��""�ѵ�j�� -����o�3�VZ�Qx�K�Qx�o���+��pM��iڬI���"�{�;���ץmUKQ(d�����E<"ZCIa����� ,{6����3��������/�*�,k�N��������,���3*��f%&�� #������������r#�g��ҹ����E -�40MnN>L�OF��v�X5��M�2�+;�,����0��^��KK���+�a�§��J3-���� ����la���)�! ��]��A>HC 9�&GFQo��6OX�j��d�=<` ��ʐ�(6����(��zV��ߟ�^�Y�U.�ze0sjv��z�f�״Z6 ��E�n=�8�Q��A�i�����Lm��n��ΩK��T�u�0���FhŴ��0B<4�yUǭ��V�r�� -��AW���:0hd6�B[�|Z������tw�Ffx�K��MT�*MTJt"��C��6>��7k�Q)B>�l����ZH ɇ��Q��O����� d�e���ķ��˳��gs�EbL��v,S�/7�.c�P<�*f���S�|�����������_��S�<��yHs��e< �NQ@ص�3)� �"3vf��\��l�b0���o�Y�̼z�1�r]��B����M�a����T(ìԎ3��Dj+�X��Ďu�i ��+��z��ғR�!�,ў�N��4�*%�C6~F��N�m���p�C��T=�kفQŌ�F1���%��4,�4o ffS��A[C i?��E��5��Yǽ�2���}0����u!t8ys}���|���ftq}uy1�<���,}2�>I������e��Nf)_�}���/J v<�^t�h@�n��Q�g�z� -ڛ�� x*�?�|��gT@�Qo��f����v�'$~[Z�Ή�~$hS�B����J�i�{��������~���wg5?_�e�{����>T���UbӁ�ț�7`> �i[��u��r��z�2�����D���9���6XJ��/�ƞ`46���V���) b�l?�Bw�ߜ7h��K�C6G�g�V�e>O%����<4�w��N�V`�O� ��� �!_���~�5�|ΖI���?E䵙���΄��x��j�֪ ��}=�"�!�e%�^C�{��'O�:y'W��=��>"<��BsiEw��ֽ$6��Kշ��[7@�έ[)Ps�v��{�V���5�?�Qc����c���^dN ��>�, G� �=�s�g��wi�1g�)�~@����H�;a�'c��I�9s��ި�[�uV��vZ3�k������o�_J�|+�H��܁C����su��L��m������`�����<��d�)ʚ�K�氷���v-M#��_�tgy�^��`v��kc,�j�n���un�ᕺ����z@�6�tS�DB��ZeY��mP��lU�v`�s�c��$��I��r���J-�]���*O+���"�׳���b��/�f���8�;k���p�Pqv�櫰!))���&V�K�j�KT�٬�oeϭ��L�y-�9<p�Ee -+��`��U��C�FM C�����w[�b +����o�3�VZ�Qx�K�Qx�o���+��pM��iڬI���"�{�;���ץmUKQ(d�����E<"ZCIa����� ,{6����3�����Ą8���l�5D'f������d��Y���z��y����{�a`��ǁ��d9� �3w�o���?���"�S�&7'&�'��i�[�`�&{�m����r�UR����g�}Υ�����0�{�Se{����i��JQUi�����v͐��.� ���H�#��7yQ�Y�'�E���?2�0��seH QW~�J�UE=�j���C/�,�*�y�2�95�o�M�J3�kZ-� �"��z�(�РU�4�À TZqa���s7�M�Ԁ�Xo�o�����KB#�b�SM!�<�*��Vlh+i9qa�Jڠ���S42k���L>��a�}��M�;v#3�ޥ��&*y�&� %:�� ��!�t[�|�5~gM�|��ۉ%*��@�5 �ƥ��!�+mG)�4���o{1v�g�m��ҋĘ���X��_n�]�H)�x�U�sq��� s��볋���������yr������x@V�.���k�gR�A�Ef�̆չX'ټ�`����4�֙y�jcH�^߅��A�l�0�9���P�Y�7f����VL;�݉/�,��)JWЩ� �'5��C�Y�=��F�i�UJb�"l��$������I� �%�&��zfֲ�0�#=�b~�K��iX h�@�̦�o����~�'�Z;jDS��{�e�-,��`�C=�#�B�p����������������bty2~��?X�d,}� +�V �}���&�R����A�_��8x2�+��t)Ѐ��&!�nτ�,��7q��T�{����Ϩ�£�� +���;�NOH�������HЦz�(72h݉�J�L�<e/9['��o+$n+$��j~6��i�@�"� X}�|\O�Ħ��7_o�|@Ӷ��뮗�F'��de��9e��40os���m��6�_��=�hl�z����S���~(���9�n�*���l��#����|�JX�)��yhJ�ŝĭ8���A�3�1AC��p�"kX��-�l!d[��k3<1� M�OM�,��:�UT��z�EC��J�;����:WO��u�N�|�{�E}D$x���Ҋ���u�� ����F��`�� �s�A +�ܺx�����?�A8(y�E���d��ű1D���C����o� K�cDB}���Y���G�c�hJ.�%�>�z�o����gg�iΜ#�7��{�Ur�����������R4��1R�5w��#�`n�\�c3S�u۳��<�6;���c�pĻ7ϭ5�9f���撹9�9���DK�#��9�Y���5�����˫ڭ� `�px���z����� ]��=��.��VYV�iz%?�@[��X$�\�X�5ɾi����e�RbW�w���J���*Ħ�����⮘��K���$ "N�Κ�4��-T�]��*lHJ��껉����l6���[�sk/#�l^Kl�nDQ��J+=X�0B�f�P�QS�����qW�Q endstream endobj 866 0 obj @@ -8240,7 +8233,7 @@ endobj 865 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F89 511 0 R /F120 619 0 R /F33 531 0 R /F30 532 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F89 511 0 R /F122 619 0 R /F33 531 0 R /F30 532 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -8257,11 +8250,8 @@ Y! �@3���B�����[��<o`BD�t��C�#@��A�( `,C� ���̢\�E�< u�gʼn����d�E��~�A馼��da�7A��b�t_o�g9djMmj�P����;" �ў#��#�:́�ҮK��=�@ަ0�T� S� �J�B�AQg���0�y�eQb(V�,�ߌ�֛U���J]��6��)��yc�4|U1� 仾� 1��Q�n���U,Ma'T�.TkQ�hр0��W��Wg�WSg���s�<�jУ�9r!��^$L.}/�A��H�NH�6��^�A�qRjʗ�S�ؖQ��9�قo�-Nǧ_f�������f�Ax_�Vh`��w���q�ɹ[M���㪩�qE_G�j�?*���/�*�t�{X�����k,X$K�^���ĵ��PЍ��j��\��p3U�i,˖&/�,X�X�=�J�(ޞ�EV&s5�oF��h�/�>���XI]2C�ǿ�R�-� ��u���f�A:���F�=8�oE�})O���hz^�L+���K�mI3�����e1��b���@rlC�3[?�i�I�}1�:�6�xԢ�U�seVϊo4{v}=+�8�ek�,F$�m�|���������ѻ��㿟��h�%���O��+��o�dQǤ�f-�f�2�X����\�̓�=�"���%==:�ʯS�*����/�>�qV��YF�zY����6����h�͙��˾�:܅��9x�ǡ+-e!��q x&S�i�����x��P=��wpO��/��������(W�6qf��Ƌ�1v}�����Ӯ]���r�A�.VS���ӛ���h<�iz���������0i�3�T��R?��lS�� lv"5�`�3�Wi���W��#�&����[>�������ts^�� ��_�N=�s�DC8�:�OKC��E�N�?�ijt^�tEP�gQ�ա�2 -�Ji�'W#�#v�Юn��w�x��a���5�X�[�#�R�T�GLb�op�7���ܐ�X��t�!��D[�Kh��R������o���6F�oP�"8����ֆ�E����w��`�ُ£z@�~A(� ��0��~����L����V{�lw�yMִo#�[���!_�R�Fj;n+ۚ�(�}��īnT��|���զ'NA+=���^�+�M�Ɛ�#����f�{4�c��mMc���u�l���U�ꊟ�k��� -���� -�*����kݠ��a�B�u�Z�,^,�ܔM�� -�-��nXYX�W�k���E�q�I�`U1�V��f�����Te�&K�r�TyV��2 6]����f��CKi/�<D+����B�� b��93�Wg�f���|�;���T -�[�ve�9����[�LTQ��09�9=�ǿ��� +�Ji�'W#�#v�Юn��w�x��a���5�X�[�#���Ի#0��X��� )l�:7�.���!�s�;���a���#�_�{����46��Fl��L�N`m=��!u�1s��;:���v������b�_� �`7~��(��#S?;D�8G���0�.E^�5���V��y���T��ڎ�ʶ�{�}��0�{j(�_�<_��y��S�J@�.����J�E��1$�Ƞ� ����X��D[�-�7A]*���n�E����Z������ +�b=�Z7(lcؤPa�V�.��"7e����vK�<�AV�U�$�i�a�o�<XU���Y��>$2UY��Ұ�7U��q���M���Y0��R��6���-��xx�}l���Y�٬�&����$,�����DYaĵs���$ՇGT`)L�gN���o�ƴ endstream endobj 900 0 obj @@ -8480,9 +8470,7 @@ x ��Q��Rx[Ǟ�q5Y����$ ˥��"F��q�e<l�[̋�t�]���p/$���(�9N�2�;����(u�(uK� �Dwp�f���$��XE�,��G�W<��:'�6ͭ��E�w(��B��"ߵ:�Æ��Ŭ��[�Y��jѸȲ����mQɴ!EtU�֑�y7m��="kG&w{d������x2��Am|������Є���M5~�شo����w�1q���A�!92�V�9��j���oj���Q��,�g����ī�� vr����T��Yi��t�N�T�נt��ҸI_U��w[��ۢ�K�I�褾����� �X1�PѾG��{N�~�������L{a������&8�c��N�*��y��ȷm� S"m�SAj�ei���e�T�3��Jq"t^d�j��w��^$�s#� -�g7dz�����tr�ه����tru������Z��oP�zw ĦȢ����L�=:(�����k� ^�P͛�H�Q���5�67 ��(�`��H��"R�=��ݾ��^A���Pݝ�tV� �gܗ�#�i���-��,U������Q��*�����X�BV�9�y�5�8�x�"��D�~����D�9SI!�2�R�"�7��_q�~�A���*�}����gm�c,���W���O��a���,]Wx5���o�+��U�QQ���ZX�&|��t�/;�1D�Q���}��x8��w�sr[������Zq��� ��o�s^l8�v�1�篽�b�'F�����~�v�1�Q��w�!;����E*B�EBi�`{�q�ڐ��˧x�(��D�Dw^���"��Պ2����n�{ƴ����B�x��8��a�-�J�� M�`��th���b�x��z�2�3�yxiY��6�BD��>�Jq�vTt��SHPSϐ�g>��[�|.����o�ݫ���� {$êT�D�n[��0�¾i9��� -I %=��]��8���8�Af�G@�mA?����YH���ȣ�LU��jh��^�Gl����jXݿm����w����hV%Ǎ��~t��mdy����]c�eZ�g�V�`Fa�k?u7h�c�uGZ�jכ�#^ܛI�4�0У~�=��x1�lY�/ߩ�x��<�Sj���� ����U��6�0���P$��-���E���A.A�H��X�B���3H�E�C�V����UU>"�2�ʢ�&He�����E�E�ET^�㎷��*A�i�R��*� ��UT�[y;�f���¶ʭ -��+�o�,6a��`�I�x�u������2 +�g7dz�����tr�ه����tru������Z��oP�zw ĦȢ����L�=:(�����k� ^�P͛�H�Q���5�67 ��(�`��H��"R�=��ݾ��^A���Pݝ�tV� �gܗ�#�i���-��,U������Q��*�����X�BV�9�y�5�8�x�"��D�~����D�9SI!�2�R�"�7��_q�~�A���*�}����gm�c,���W���O��a���,]Wx5���o�+��U�QQ���ZX�&|��t�/;�1D�Q���}��x8��w�sr[������Zq��� ��o�s^l8�v�1�篽�b�'F�����~�v�1�Q��w�!;����E*B�EBi�`{�q�ڐ��˧x�(��D�Dw^���"��Պ2����n�{ƴ����B�x��8��a�-�J�� M�`��th���b�x��z�2�3�yxiY��6�BD��>�Jq����>�����3d��r��3��l�~��s����F�6t��ǰ*�=w��V�#��eZ�Iث��W�S���5�������d��y}�����L ���ު/�<���Tek���Ɓ��5{�f�J������ �~w����^�fUr�H��Gw,�&A�'���)~��06^��z&�aUftv��Sw�&=FQw�իv�ٝ1�Ž�DIS=�'1ڣL��̖����W�Γ;�v��>��,��[ul#Ә E�+ڲhy_亮����� O��e�-dz->��A�^D9��`% ���^�QQ�#�)㐭,ʰn�Tf��=�XY4/[4A��ak1�x� �� ߑ��/u����`�^E����SiV�/J��*l�ܪ�Y�R�f�b&��f���'�P ��?��� endstream endobj 928 0 obj @@ -8677,17 +8665,15 @@ endobj endobj 948 0 obj << -/Length 1286 +/Length 1288 /Filter /FlateDecode >> stream -x��X]o�6}���L?%�oM�f.�-M<t@R����lɕ���wIJ��� �t@�$����{�.�r<���hV �!����(��`� �%֔"%��D�A�����������2�p(u�q��v/��2�7� -MQ����}O��֝��<D��XRf����c -ke��Nr���(G�~`N8x��;]�t� �����`��qV���Jt`y�aHc)���D� <�X"Ի���c�v`Oa�.�l����!H�9�:��O&��7 JʱQ�&��i)�"��{����IQ%�Ejxm�(k�}���&0TH��Hi�TY�7 Ja�-"@*C�ti�!�躋sF�[1 ���Y�С���}�1�h����c絙�q��8_g�q����'��t�FiD�2�1�]�X(���aɔt��hoО��rʰ{�ܪ��_�QW����n{�̪��0�d&ol⬵Ζ�����4t���\�yV�D��0Z�C': �̏xgܡ�}��>�_��OG����]N��w���|6HhS�{��EUe�Epi�ȫW���Ӳy@a�����Mn�x�MM���� -� ��� 5��� 4tp!���OW�;��2� ������y�Q��,�n��^ĥ�2|g ���b [��A����,6��Z��I��ti�y���/����䫺�f3S��{��y���K�-��I��q>�nR|��/=�5C��#n���ϻ��M�uDv�+�l��&�^ifYH�U -ׅC�W���Es:�f6<���OW��? �`y�m2���P:��uc�u����xV$��3X/��|uD�B��I9N.F�"A�� ���x)�\�[��د��Gȱ1������d�S�DP�m*�g�a[�l@�$���DC?���h��o%�� �^�'�ߢ��Q�Y�kf48��� -R+ L���N��[��'�Wp2m�1j� �٠�8謲��f~�a��ߟ��u?��H���a�|oP�5ȍa�\�MK���'K�c�nv���#|�D�[�o���4&NM��~s�;6�cc��G�3�'G]���K�̞P�+ѩ-pw�68��� x����w?a���D�b�z��c���u���,�< -��U�N��2�����u�U���n��/�E��.y4C�Y�E�N6CjhҬW���d���ބ��O�n�y0�����B��c>o.�⾱]��&�ڑ��l��k@[4B�+S�_�[Ǒ��[0K&�?��/���%��G�� +x��X]o�6}���L4?%�oM�f.�-M<t@R����lɕ���wIJ��� �t@�$����{�.�2�^_Q4/�Ax@�O0B�%)EJ0� +��������2ɰ/���Q�g�Ef��H�EHQ����}O��Ɲ���G��XRf���=�c +�����P��:�4��p�f|w��i��&+��s�x�O�8�kpI�}%:�]�0b)T<�� ܣX"Թ���am�G�����K:��6pRq�i������ ��r� @��B(��Н�4A��Ӽ�'��Fge^T:>�8};O;`��V� +�Se��~$(�ɷ���m��ʘC-�M�J�<`��� ���cS��0P�c�����0�*=/�*�37p�Im=WOO�?i�F��e^c���Py>Ò)������rʰ}����_�P����U��jz�L���0�:�m�Q�X���x����5��6w��?�˽!2�fB�oEg�c����=���7g��k���x|����r�nr9������m�p��*/�t��.tT�Y�j���rZ&(� �Ӆ�t-]��.�"]�6��" �~H\��1 �z\�g��ӕk��L�GB<"?��:Q��T�:˨���o�Q���Y�*�X��P�/�F��<�����E��6��t�ȓ_��:���|U�|��q۴Z�Y��D�A���O~e��&�'�.��<dh�����yW���q�=�J(��Ψ�y�b{��u!|����lx 9~3 �GU������{0��6^8҄/-���6��*�����y<���ʊ�lV3]�:�F!�MO�z��c_�s�{���^�A�� f.���PմW�9�#&�pX��v*����]���3lj���$L�I�:@�������FR�0��c�Ez� z(9 1�]͌G����A�JSf9��S/*����b��L�v��n�^o��-�:��yc��?d��������ip�Xl�� ����0Q������1Vw;q +Q �>pխ�[5�6��UӮ�������h7qhv``��d�k��z�Z�%�%:5������bx����&��1��T_/�n���*�~��~�Gw̛߲�yT$i6w�Q�չN�r����.���z���M�P��E�l�ݐ�$��Um�.��m:k���7�h���m�zYWwQ]h?�c����?Զ��2��[3���dch�F�v���k}�Xr�wfɄ����[_�l?)�>����� endstream endobj 947 0 obj @@ -8734,28 +8720,21 @@ endobj endobj 976 0 obj << -/Length 2821 +/Length 2822 /Filter /FlateDecode >> stream -x��[Yo��~����c���[�,7r����CR�D�,$R�b7E�=�Q$MI�� @R���g?g'W7?�`U]D�*����#�p� -O��+��A���e�^��h�� �a��8A���+��ݻp���%�S8Xl ��i���1*�"�1F � a��HŚ8��2����`/��D# -h�sk@w�W�64xU����=��>�B��HĬÖW�@!�b%�r�#<��aw�����^�1^wK:/�m2�@dL)�J��/o.�ހQb��2�� �B2����o����ˢZ�]�DƳ�4���N���z����f�X���4������%�D T<��=h��:���(�<��T��� f� -� }|;���L\�����.��U��Y��o�l����ӱ+P���)�(`�3sK��@f�e�N-I��E�I��R9F���@�!.c0l�"0���E���Ay�,��)�-tR��-����߫dՇ���G�,(���j�W�����U�ʓ��ߖ̬�|e��y���.%���[��T����4G�VpK����;��X���� �ɱ�8���]s�iy���3�ڣ�߶�³ZlӮ�V��&��{˝���?χ��Ī�o�!��t����\z�����d��Y����p�ܲ��8�@n�BL�шaH�*nC -� -a�ud���18�?���A @`:� �>�!ɵ�����Q -�E�$�CBr�lmc]ϴ1eu)�p� -����t[=�&�\�3r�e�@��hO�2�/���x��6��aBB���`d�,��Qv�]�?N�D��F4)��w��^��y*U� -LF�BE6l�us���ϫt�%>G<���?�U:��� -[ꞦQC q&�r�v�����eR���(��Pj��~��k�).�h�[=��[ �k{*���v�3�m��ˀ� ʟ��"��*��3)*���>�U]�� �Uuk{S�Tc���9���ik�� &0����+vb���@ΰ��rnCǠ���Jn_�{�Ӵ������:]:c.�5͓���M�m�n����ܭZ�:��;g�\�[%���}}����h�)�)�,����u㠆E����LLcH��Y*K�%X���֘L(, A��J�9VXB �dB#R2dB���J�.�L�+�BL>����~� -9n��V!^�s.<��b/�X�t���ծ�Sm�E�����v��0��Sҏ�q�?�~Sj}��y�(��koSY1����\~��JD��6�i��'�zg��T�x�/m��I�|O��(�#�AEP�����Z+�#b?��&M��� -����yA!���C���*�A8���֪g�A#��l�V̸���̌!���؟x��j�Fل�����D�Qtb�����:�������{�+1���=����m��~�O���\���c�mE47zkZ���xhU>����#C�I��<�!�����G��V�`�U�nҤ���������V�]��SG����E��� (N��{��ˢ����z*��5B��a�a��h�S��>�8��iլ}ew[����������R�=T9��Ǫd�������+?Y�TBM��!-o�rs��~5N%�Q�K�����K�k� �w*ݏU -P��T�� ��U��L"�� ���o��lb�������֦b��1��Eg��!��mY��o`���埲٢)K�W,���l��G�0<Y$q�vY�q>4��H�KKL�b lJ�<�x�3�E����i��|��ő�4��I�.:DW����B$F�Pc;�3a���,�(@d�h�K��|z/J��v���|u��"��LhD�!` -`�S�q�^�@���(J!�>G#F�����n��؋EF�#_2�~����� -_�t� �6~� +&���T�O��4����Մ!^�S Q;@�N(?�'�,��>C6��t"q[B�Ldoj��fF|���HQ�n�ǒ�2�-����E�jJ>�'�3LY��w��Zf��������w�*�f[��=��x~C�WM=�郟��(c�>��J�;�ٌ��2*��"z������������X�{�$�Ғl���t>5�������]z�j���_��أ_��Q�O���EC�!�x����'�Z��O�fgU0b+���O�\G�c@������l7g��O|��b��'�š�u��<;f6i��1���GW>���T�d�\���A�f�b�}���H�zۜ���T���2{�ԉ���_颶?����.�W���F�E�&��g:h�-�?��&4�yZ�|J�A�7���B�A;�VCsd5|��(�C-� �9TH�k�i�{s?�0�dG�)�g�{�k$�Q{dw� -}��ɟ� (��~C�a������%aFTv�9�;o�� -B�=\�Y�}υ�c$�����|����ɍƠ�Lr���"����ag���c��px���Y�<׆���=FJ��Az�g*����v���yRmߤ�B�biJt�����qS�5�'�w���}z~��M���?yН:{ w3B�2� -�7����w���O6{����hۆ��1��X���2[��~��wQ��e��U�VI�45�����,�2��E���5K�ޮ��'w��R�Y���Y�����M����&�l��<a܋6�ڵ��ʗ4�"�z_���*�n�Yo{���|�h:]�mZ֮��A�:N���0�!��q������b� +x��[Y��F~�_�G ��������cOv���$��I�yx� ?~�/��P�9�a�6)v�Ǻ��ؾ�}��D�� +G�G���GD����Hh�4!Q�)R\De�]��h� � a`��ER�����Hd���H�$Zl *���5�q�a2R A�Pj�a�&H'�8���qj��m�������v�ւ��n�lX���R{��ClŁ/A�Lx�-'.�i����V'�� +R������=�+?��~I�%�Of�LCDK������+0J�JE�w�H%I�����2�0{^T��똪d�>�VEYg��?o�zy�a�pa-\%d���h ��F�J�;uc� ,ZG�< F�H`.ST�i t�Y��CC�^��@�DT��_��xx���U��y�u^7�2�M��SW��G�Pa(QK0@B8J�#�_�` �ߊe��I/�E�ɶ��r�4 ���#�0l�0��E�!�y�K�h��:�AJ�6��q,�U��C:Հ�1D$E%J0sP���w�'��W�t��we3�|�r����L˯���|�V&�]���`��Tk�e`}n���_xW���CK��ɳ�z���]<s_��K�=�_���V���j�˺Ze��l�h�[�����i>t�*�]~c�p��2���T�C�ғ��v/���u�w��������1r�*��FC +�IRӈ(�#T.�!��y�9��� +� )a�d.��J�.��X" �c���u=�&�C�e�# +x_g��4&�]�����v� A�f.��BE��W�vц�#\*�{� ���`p�ϴ�� !��h�ֈ&�FL���s�kZ=O� +���Vp���1|�#�R?��ŧX�����?�U:���JWꞧQ�@ q!� +�v����eZ���(���\5�X_אS|1�+vf4]���T�/��.gV�@��[�?���V�*�Q�������^Dﲪ.�l��������q�1L�����5���J�� @�I4?�Z�A ��k9���PX}N%w��i���}܂Jv�-�1�m�y��M�k�n���_��L��%�Uo�nv���e�;7���Xfh���&1m���q:��ap��(W�,a��]@[XZ:���I�2���Ta i�^� ��� �bЂL�+���0q��Tq�>F�0ĉ*�U��[�EJ�����㊽�����C^��O�������ƭ��T��I?A�]�l�il���j�բ�w�X��� �S����@�W"b���KD!��{#^fF���}i�M�ot��b7�4FD�����$� �Z���0@% 5e[0�T�����i"�=�jp�#�)"XOĨZ^�����Ds��ߞ`f���� ����ydo7���� |f����&&�����̳/aWb[�c{�P���*d��ڟJ�9���ǖߊn�ִ.���4Ъ|*��5�`K�Y���2��!X�����G��V�`�U�n��������_��V�]��g��翽� v��P��e�m��4�;�TZk�:S�<æѰ`Hh|:�2)��Y���,6=�V�kU٥�{�r*��U����3U�h�V~�*�����mV����w��j�J�%�p�z��ŧ�� +��T���;���A߫7_�$�� ��&l��l������ݹ֦�꾱���f��a랻�U_�6?�:<�ES�&�8��ٶ+ +��gax�H=��/-}��t�.|H7����ز�ؔ�y��g�h��t��Y��|� ő�4�m� ]t�%)��J�3G�*���vz Ch$�EzQ��i�>W`���(��������^�'�LD��!` +`�S�q�^�@��#�(� �>E#F��3���n��ًEb��/�n���_BfE�R�{�v��Æ���`*�g}��rg��j������� (�g�rē|�ڜ!�c:��-!�&r0��v3����s�(]7�cI_�27-�*���v�6�B�O�g��-PО�I�^k���B�0',��ͪ,�]���8����Y5��6?��Q%(1}������s��eT�T��m�߮ok�g�cE�1�LKK ����Ԕ0�?7`�o���1�M��|!�b�~ŷ�;E�9�jrH ]�L��Op�%����~r4{��W���<���E +D�8뛇��us���4�.6��~X;�P�mͳ�a�`�ֿXy�n�p�}��MEZa����[���Kǐe���Ki��Yi�J���s��i��᪙�/[��1"s]ܧ�Ufb�� `⹉��Nz� �f��?_NJ������m��ι��Y����$6b�Q��c���f2���l�m��qw���D�}�QH����D�d����AP������(��kKScS~�9�{o��B�;]X|ϕ�c$e����|��[�ɍ%��p�L��*�ƃ�qg�����c�=�px��oXÁ������=AZ��Azwg*��i�v���iRm�d�B�eJt������S�5�'�����sz~��M���?ۨ;+��� f�m��n�;>Ϙ����|�z3��0� �_>{�^�ge��7�:{�d�! ��"��rik�3�~u�˼�U���,�k�.rw��?*3H��f�>Jf�27�v? zϛΚ�r��&�m��oG�U(iE<����U�ۭ�6��7��ec�t�vYY�r� ������D(ǩ���I�� endstream endobj 975 0 obj @@ -8896,31 +8875,22 @@ endobj endobj 993 0 obj << -/Length 3445 +/Length 3444 /Filter /FlateDecode >> stream -x���n�6��_��60�ERG�f2G A2c�>$�@�Ͷ��:�ڎ���b%JV��#���!ţXw�y}��g\�gQpD��3��@K�\��A��0U:hL�=������%�f<M�a����n�a-�4�7�Y�r���X�)�S��d -�i&B-b�.�/��<C䠒$R���A���Y(# ��W�@l����2xW���}��Sd-]Z�I�<��]Qy�U��R5 �1p)j��D�P=A�z��a���/�&�̤E����g�?�R -�*M��m�a�eA���/6����u��:_�i��l��n:�>��⇳�1Bi��i�O3����Q�����7v��2��}B��X��T#T�'��ep����9�N�8">���h����eSte]Q��c�1����Ӄ�Hz�!�,����Ы$T��I�8#�~��tib�0]���l�q(H�ڮ -.���_�\��iLV��<3��h:�x��ٜ/���cSV�X���^���oy -�8V��F`�� �x�7��i�.��ں+s���0-l;@���l����$�:!�Fx��"Y|.��J�(� �Ԙ���1�*,���_���,�l"!�C8صYu�Z�-�rQ�o��RsWS�/ʪ�}s]��vwK���rO��֚2O�7f�Rݒ��WEkveex�j[7{g5�psUZ��U���������H�Y��[��� -����4v�jm�ي�e+V.��*=%8���]�-BV��x����_ -\[�Oug�ʚPV9�~F�q��YfP����Ů\5$"�X�U[�]K_�(�Mq��k�_�KP��jϣ���(��P!@�g�x���� *��>g�G���YI��ZV;<RP�roB���+��)w;���eW�pŢ�rK�"��Z�eUve�+�k5Fo���9��mۙ=u��W�������H��.\w�Vj��H}��:&Ho){�̙��^Dt�Dco�!٢�S��s]�`�W�@k��D�庨�+��b�V(��aK��9&��MT��ֱ 2c�/13�R� -�0�E6j6��Y�c�Fε��f�#>��6x՚��M��=��E:���@���(�2�# -��67EഓDͬjb�}iLwl�/�h��ץ���sۄx�� ���k �V9F�v��S���5A(��z�R*%��P�"I;�WYwM��Q��FAT�A:<̮�n2�|�X���M�ev��h�F�ꋷ̓Źd�#t,��?��1JG���� �`2ϝT��H M���V���Q�WLW;+��5�#�����АG@��X+F���9���� -vX^�f��l�����:����<�~'\[���M��uRh�w�xb�?�O,�Q��\�����hg=�l8�*^"����Y�� ��9E�Jr�ey�yG��(�!�A/)u�6VC͆�=mkym7��P�X�y좪�ݎM�`s���V��B��Vc{}��mS�P�s���m[�Qw�N8j������N9�6�luKeG� -s�c� �XY���U �^4��������w������W0*M��=\�yU\3<�H� *#0s-�N��J�e�Y���b�h��� 7��6Q�< �Dn���a�)6@�Rz�g����[�� -�d�^��u_^^ur{�q���b? s�T'��jcP��ި 0��W�� -�-��LQL�o��Щo���ݗb�����%�څ�0�r���j�B}j�д��ǡ�6�]yˈ%�=7�|��NlY{��..M�H�K!��ey��ߜ��f�Ņ>Y��>���е�v�{���6������TtNz:�m��@�`iuD��y��cnu-N���np��49�����ǖ��<��ט��Lt��8����!��fl�ݮ����M��?�7ع��}�*|3}1�s���Yi��D8�?���� �s Ĉ���v�O�������Q�얳�^'�#�g˒�{Q搽1s�|�)��Tw>�5�{�{%0����8��c����'�9Շ���#VQ�3e߂��c��HP���$�ٜ0K�/ʬ����I���RK!o�T�x��?�W���)5Tɧ2̲�*%�����<â|��̓ �a3*y�!�����M�q����k�n��RW��:M� �5�<�S��9��t�C��?��}��C�C�2��Xy��<���}�'�[���9_1aY�g�q&(�a'7���ZZ�1-���Z����[wm}�� -��Uu�K�{Gm�274ru.�<�a�'�=��j���m+ެP얋��.:���-���4|�Kz ��S:e�"�ۺZ��L� ���+�*�Dx����[S�|�Ν_�"6��%��Gq'����"Y�������C1Vr�s;P� �In8~�>B&�W" -6���ʸ)��V�"�� ��X���n��43������L�u&kk� ��"hU� ->m��h�4;ܶ�nrt��p�쯒�%�̳��YK�D��k���#ث���Fdsa��,�c4�"�5o��T9' ��C���<HHʧ"���Rijkc�*w9���q�!<q�ցX�F+�i��s��K,7EW�C�����B1�7;�7U�T�w �(�eX��6�����tˉ�%�#��L�?�1N�t������ �8{�E<ZD.�D��S"@�A�4�< 5�=���Ҭ9��[�����C����?�a������I�����j�ѽ�@�Aß����*�ش�~[J�T��50�"�6�A �0:��OBiVG �C� -��e�ݱ��7�oi���K��m�����\���� ��_���[a�9.�{���K=8sbO�<����T��5�7��j�2{�$�aAs�~'�b��❕?v���̺�ܚb��*�K<5Lh{Vy��[JLm�_�]�>�z���}s�Lc�x���|���$��ޫ��}з|�SeK�K�8c,�9�A�?q)�R���A���D�:�B�`����G -�.�5t���ٟ�����(�D����Mm��߿�����\�a�����Ĵ��:gV�5p -���E��;��/f2ɸ���up���.'���,���s��i�t���9:>[����"�sP7�/���#������i\�W��R�b�4����cx��pޯ�h�-!jzb������d}Y -3�Jn_� -|�:z\��{\�j�q���:P��L�xc�V����Ɩ����UAh���)�,� ����[�)�C��Wt�b�<��n!� #Q�9��&�T���y���ru��-9���#oCw+6n��{����\�a��q�î\')��P��6GD�{�q0M�A��s���8s��7�?�`��>^Fӝ������i +x���n�F��_�Gq����d�$@�d��}H�%�l.$R!);^�㷪��lҔ=>� `M7������y}��g\�gQpD��3��@K�y�B��a��1���;�_�0F0�i��8��z���N��8u.��~�@(c=�t�t�JC�� �D�@�%��,�3D*I��D����$�?�B)�����:`^�W��P=���d�"k��E�d�#��E2��Xgy� U�K!�K� pP�bE����h�x���h��L�P� �{q��(�Pa��4��2�,Ҝ�}� ~]������R��⳩ں��������_x�[ O�x�!�_�� t�D�T�ء{8�`|�i�qcU*cP�P��V����O�hq�TL����[����3�MѕuE ���X��O�O"���,�,3z@��Pg*X&2�eF�&�tib�0]���l�2�kmW{���T-��Ѵ &��d���a4�y<l��lΗJe�ͱ)�K��CS�M��7�<������l�#{�_��bQo���2�� < #Ђ��4 �˦>@J��*�ϗ�H��k�R,�jC85��jG�dT�E�6��۾�š�M$$�PvmV�X/�K���hn�����e������.�c���I�e�'�awkM�'��k�n���5��2�t�����h��*�W��*�pE��rxBa$�,K�ELqHR�`�`�6Ԁl�Ҳ+�EK��u�Ǯ ǖ��X|<C{ +��/���駺3_eM(��I?�S$`����2�ؕ��D�j˶k���e�)]ym�kw j�]�y��0T{e��b�Tz�'�8�����-�s�~Kp����"���e��#E/�&$���2���r��ڊ[v5 W,�-��,��EXVeW��VSa������C���S'��x��+ꯛM�$O)���uWn��쎤���c���7��Μy��UADgL4�� �-J8��<�����P�wu�v�^�A�\��j�®.6n�b����I�c����AE�DZ�Ab��%fFYJV�CJ�|Qd�f�-�5~8Vk�\{�hF�9��Hy`CA�W�Y��_��C�[G��u�P&yD�s�f㦐2���$zfU�K�Kc�cS}�F�.c�1:�M� jH���n�:'�h���a�/TV�&��%�X�@J�z��Q�Hc��j� R0*Q�(�j�������9p�&e(�Yb-�G�6ٗ�EȢ��s�/�2O璁�б,$����(y<!�N�n�y�q(EJ��4~̐��`UI�=j���jge�B��xd2S�1�m1�I�h�X8GԖ�U��K����-|}1�YGb�;П'��k����)߰N +M��bO,����e;��\�>�����M�Y�K$�6>#��*�=�uAIB�,�8����22�%#�����j��0���m-�������#��]TՕ���4�1�=�l� +-�n5Ʊ���6��*����8'>\ݶ�uW� '@-}�\���SN���3[�R�Q�����l�+VV<u}Ux�ͪ�,� {�-��]}c0'�<��JS�n�f^�3����<L'dp� �*�,��v�N�EV�JW�(k��Y"�� ����� C�x�g����[�� +�d�^��u_^^ur{�q���b?�r�T'��jcP��ި 0��7��+��O2E1ٿ��"N}[L��4�7Ͷ/��]��! IL�� +��[!ԧVM�y�j�ޕ��Xn��f����-k/=�ťI�E{)���l ����3v�l����'�31ç7�y�V�`�6�ߦ#Q����V:�S���t?�!XZ�R9�b�x̍�Ρʼn҂s��� �s��f������ ���2�����3W�0��w�R3��ӌm���7}�`�}�i����;�Ӵ��A�o�/�u��L��V�0M�C�C����߀?�P�@�(�MmW�moJ�X~��n9��u�;�yq�,��e�3�Gn���L�w�_����W3n��-��s9־?h�y"��S}�0��>���8�P�-x^>�~����N�8�� �4��� +*} �����.�bp�v@M��y�#|�ڞRC�|*�,�R��[n�3,���< ��ͨ����2 +�7���K��1�o���J]�3�4�o6T��w�O��'s0]�"G�RO�,+�CG<d:�/�Ȏ�'����?��㉦�����@|ΗELX�Y��6�⦰{]KK>�%�Q��t1c�m����^�|����x�u�-V�F����'1���Gz^�B�y r�m͛��j�1�eA��t��v���A}I��z*��!]$}[Wkӟ x�|�6@�yE_�7�yk +�oܹ�SĦb���(�dV���$+�_�s�:�rh�J�rng���0� ǯ�G���JDæ��Y7�q��U���a���;k�C���Q��0�L�I�A�$[g���6���/b��V����柋L��m��&G�����*�^2�<�/�c�Rh�t���0r�{up����z2g����<F�*"�^�&)_H�s�P�Xݽ� )�T���_*������GN���cO\x�u ;���o����\p��M��r���{�P����M�9��H;J�{�� ��R�6�n9��d|$=����#��x(-�wW�D$��Y�3a�E�"L�������A�I�A�3��i(͚�����8mO[��9����ӑF���Ϟ4��9�����>�; +40�9:�L���M�4L�~XS�!�n��@ +�s*�$�f5p��p?4��OZv����xc������n�������˵;:�$���Z���qa7�3�^���{�i$�g����ܭa���Uk���$��k�;������wV���W�1�>pk�����.��0��Y}��o)1�E�w��H�aX����2�b����q����I-�W}K��o��(ʖV+��qJ,�9�A�fOF +�5l�U c{�?g,��)g���B���:AT��O��wʼnJ|$#-��ɡ��p���t*T���<� =� �NLN�sf�>N�t��h`��7�%�Le Wz���Ζ���d�қ��ݰ�n�r�?����B�"G�gK[��X�y��v!x$���z<���JJ�VVLC�f���A�x�W���������"DMO��_����/�AafP��\��YG���z���S/>�W�Q�}��o��*�5x��r��j ;|=E�E�ᗙx�tK�7e{��b��N_̟�]]�-7a$�7�u��jS�56�]S��ޜ�%g�3b�m�n�ƭv|�џQ��>�1�pؕ��$%J���x�7��8�s�<�g.����' 4l]�ǫh���?;�h endstream endobj 992 0 obj @@ -9015,24 +8985,24 @@ endobj 991 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F89 511 0 R /F44 228 0 R /F120 619 0 R /F159 996 0 R /F163 997 0 R /F97 510 0 R >> +/Font << /F45 229 0 R /F89 511 0 R /F44 228 0 R /F122 619 0 R /F159 996 0 R /F163 997 0 R /F97 510 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 1022 0 obj << -/Length 2319 +/Length 2318 /Filter /FlateDecode >> stream -x��Z�o�8���B�6bė����M��tS��b/�LۺZ��G�����7|H�9��.P��Ԣ���o�O'�Z������^,���űx�Q���3�<ƭ\X�������Mw'��A�q-s+[r�����X��(�@��>�]Ϛ��Ե<#��d*��G|�4\�2"y�j��N��u(p��[M�t���p<N��6���>��.��Z/��볖Z�\�C��q�ޣZm�ۘ����A��T�m�Е=��vHKȇ��>���fzp�%�(`�gM ����hO����MVD�C�x��R�E��":���|p:m)�W���ԗ���k�?[�Xw�4�䀁Zk벭�sh�G8�b��ji�ꚜ 逹���{J\��C�0NK���2�R�ᬊ�B)�o<�|�\�M�83��LK�q�"�S�v�@��0�ȋ���k�`y.뛘~cbN]D)��6�w�#�<����jB�3,��1q�&)�xG�w�AciǾ�!F đ�H�������o-q�s���Jg uS����q��ϔ�US��v�_�鵎��Ur#r�����Y�bn>+��]�y�ő~��.�'�S+�^rQVy -<��]H��=C���,��,���1<��aD��1s���D��<��2�r�c��/�gڦw+a�WQE�(�E�6��ʕ���B�:���R��Jw�+=U���ə�l -<G��x�TЎ�mN���K�l�B��ǎ�A���B6v - -tٝ���oq��Q6�t�u��v"�,��S �3栃��ѫI��Da@���M!��9+;<��-�+z�JvʕU�ezl��?3��Y�k���˧»Mk>�M�]���a�;M:zM���v�´�o�0�:�s~[Q�eUa���E���MH@�ߋ�m�R�RU����y��ۚU���l���`���_|��(�:���IN���"Ai$��&Z�"�����[�A�+�l�_�d�;Ig�n�xެ��Y �e��0�%�n��?z~8�h���2�����y�'75H������������r|9�e�c?�+�W"^��zX��tĽ�f2xg:z{Zqe�[=���hzz~q:9�~��>�#�R%�����l_u�#ߙ��}<�O{�$"���w��bO��c��j��T:No�O&�'a���&�d�֬Oz�*[�*����4�����;U-�������\SZK�Q��9j�`��ou=ѬI��K����`���Y�\����R�a<�7"�M�Y�e�,�b�[}� TP��^�X��b�d�<�����XE�����v$�����`e�;�P��\�������~�IL瓞7PPVȝ��yu����:�����~hTt���E�k�W��e��Д��5j��%{�QX��mE��q*����C_��Tm8��6�y,n�峔P�պ4��ȳ�=�������Jʺx�gff�(WM��'���{���V)��E�a.�S\:ઓ�7������*Lnb��;� -�?��lJ�zkǟ&;�R��x�{��g���O���n��t�� �9�^=���EY���e���e�����)@��V����&!.�ɞ;�6�E\#�n�A\�� )�̘�^�Q�:I�.ma�gw��R�ȡG����6�1]�<h�SO]{�`V:� @��-]���Y!�±��\xkLɰ�x���x6 s��_���J.�+,p��f7�b!������5��O�n3�s1�N@[�����dž�o,p��c9k"������&�[yP<�C>���!���n�-�R���~F�0] -��H쫎4+cy�"y��9�͢*QT���m�`���C�G���S�w��U��n������:�@DT&5֙�<W�z3ӝZ�#�o��g͜�֑7d*��%�Ӊ���:�U���[Y]?_��b���v\�ϼ(�@�Z{H�{�G���ì�rԡ<K���L $kI��o����-"ӌ���k�ۭQ��&k���-�~w|��J���z\*ݚ;k��S�9���ņR�k���z�UI*��J����m4C��h}��8�C#/��B�6�2У�R�Me�x��3�%PX^�vn�)�kxe����� �c&o��<^�d���&�>�2y5Vdu�2��ޑ�a�U����&+µ�ė�:�K�<̧\�v^E�'$�\7����j� S��k1�d�;!q�Ks���Uy�[�[��:w|��:n����/��t^I��ah������O�k���*a�?�`�����/��W<) +x��Z�o�8���B�6bė����M��tS��b/�LۺZ��G�����7|H�9��.P��Ԣ���o�O'�Z������^,���űx�Q���3�<ƭ\X�������Mw'��A�q-s+[r�����X��(�@��>�]Ϛ��Ե<#��d*��G|�4\�2"y�j��N��u(p��[M�t���p<N��6���>��.��Z/��볖Z�\�C��q�ޣZm�ۘ����A��T�m�Е=��vHKȇ��>���fzp�%�(`�gM ����hO����MVD�C�x��R�E��":���|p:m)�W���ԗ���k�?[�Xw�4�䀁Zk벭�sh�G8�b��ji�ꚜ 逹���{J\��C�0NK���2�R�ᬊ�B)�o<�|�\�M�83��LK�q�"�S�v�@��0�ȋ���k�`y.뛘~cbN]D)��6�w�#�<����jB�3,��1!m��@<�#�ڠ��c����HS�GYUޏd�������8χ��uq�3����b`Q�8��g���E�¯��ZG��*��ng���, +K17�N�.ʼ���H�]A���T/�(�<����.$[���P� ^������0"\И�X�b�SfR�\�l��1����3mӻ�0ɫ��HŢZ�d�J�wq!�K ����x)�v�;ĕ�*�����L6���W <Z*h�LJ6'|t�%L6k�_�cG� {Xu!�; ��NL@�8U�(�a::Fe;I���ܙs�An��դ�M�0 p�Q��L��������~%;��*�2=���ҟX���~�W��S�݇�5Ʀ�����Ý&�&�Cj�LaZ�7y���9?��(ò*���C�"�T�&$ ����6U�H)�*��e���<W�m�*N`K6��w0NY�/>zJwT�]���� +'��E��4[I-H�F@�R�-�i�� �h6�˯[����3d�a�o�b�����߲�m�ǒi7o �=?�k�_X][���P��ޓ�$�����������rrz9���2� ͕�+/�p=��zL:�^j3�3�=����ح��|4==�8��L?NN����h�Mm���:���G�>��ߎ��=}���A��oj��z�u��P5�n*���'�Г0Nuk�g�|k�'�M��E�Fj��H�������yz�M��[�)�%�S��K0�h�$��~\�e�Y��Z�z���^m�� �x��&Ǭɲts1ﭏ�o*��[�J�c{1d��S�?�~���s�"��ȅ�];�k���~�2���J�|�YQ_�i`c��$��I�((+�N��:l�{J�qu�?4*:{k�"��+��2Z ihJ��5y��(,��"���8��v|�M�6�^E +��<���YJ���j]��]�YҞ]�Z�s�~%e]��33 �D��&����\N�=�hw������"�0�).p�������N �]&7�H�{���Y6��y���O�[��w{<Ľn�����'��G7�O:�����aD�G��KQ,��qȲ�G�2���d���\@+WB\H��dϝv�"��m7�� .F҄qfLԅ ���@��b��0ɳ;��G�Z��#C��o⎘.o�詧��o0+B �yMTؖ������e �XCa. +��5�dXe<�qsz<�9K�/�r�`%�����O��j�y�ĂрX݇�w�'C�Ϲ�Q'��SC�@Q��cC�78�汜5��L�Z�ue +��<�(�!d�V��]T7�Q�_�L?�U�.�l�$�UG���<h�<���fQ���������G0d��!�#�����;v��V�D��{��m�I�"�������v���N-�ӷx��fNp��2��ܒ����z���*y����䭬�����I1q�c;�M؋ +�����M�g��}q��:�1��)�@�s����@�v��[��!o�����"2��:�{�vo��%�k�������w��wٯ�jN�ǥҭ���(�=�M���[l(�v;J��Y��D1�bj�Ğ߾)�F��1$:��7<��;4��z+Dk�(=�/��T��{0Pu͋�j�ƚR��W6:Kn���r>f�A���J�N�m��#)�WcEVw,�|����_5�y\l�"\��H|٬��T��|�l��U�|�Gb�u��(�n�֘�0e��N�����1Wm���Q�����Uy�sǷ٬�&��/��b(N����Ky����qP�V�^���� f���Oq�B�v5<" endstream endobj 1021 0 obj @@ -9234,28 +9204,29 @@ endobj 1020 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F120 619 0 R /F97 510 0 R /F44 228 0 R /F163 997 0 R /F159 996 0 R >> +/Font << /F45 229 0 R /F122 619 0 R /F97 510 0 R /F44 228 0 R /F163 997 0 R /F159 996 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 1045 0 obj << -/Length 2771 +/Length 2770 /Filter /FlateDecode >> stream x��Z�o�F���2`�����!n�\��M�kEK��H��8)��wfw�iY��NH-wg3�ۙ�����;f��3j�,j�>���g(��8$`��%'�t�<���~ݩ| R��b��N\'����l�b6��=�'2`V�� ܑCIS�Z�aµ<��q��m��}�^\WH���RkR��3"��i(� -���7[a����4��jL�e�z9���쨥�E)��H?��j��+Q���u�ֵ}��U�ӵm���׃���.���=��H� ��Y�w������]ZfWY��m����qZdyG�n<���(ä�����G�>Qk �(�[���am��]������ p�V�ԧ��c:0�%�c%�_�ux���*�$Ku��*Y�J�C�4����qj�q]��l�!����EYZ��ÝY�����A@[Wt�z��hc�&�?d�����.�/L�~W�� �pLG�0e��������?R*�0D0��P�yn�?�%��e���1(���G�0] �A�K!b�\�J�}�k���e��_b=D�ڼDU��i�l�E��̗,�|U�%c]����a��Mp�Ͷ%�/g�f�=����L��-$,U������FU�����ң<݀jrˀ���pQ��|��X0%��ِ�s[8.ڮ���h��$զ��M�ХqeKnh,60������cWy(��p�q^����`H{���V�~�e�6l�o�A�bc�=$��`�B;e����\�Q|�|���.�5k��qObqWE�.��ڷ� �4R;V��sD[ٌE��<^���saPUE��A�,�E�Z!a��V�}V��Ȧ�o瞜MN=i���_v�C��kF�DB��7C��#�"�M9�z+�\F��rrV�#ҟ�Z�쨅 ]��uh��za��������j&�hGG���5hT�`$'X��_�&xk� ($ �� j��L��`��p���˒�;\A=���D2-���m��6q�>B��w�8,ځ>�y���/�3w�˻���ί~��j�����=�M9c����7LC�B��[�)�co�g^��|�UϷw�+���1��9�͇Y��&�q�K�����g����J�Ƞ�?*!�@ܱ8�� &;����H�( +���7[a����4��jL�e�z9���쨥�E)��H?��j��+Q���u�ֵ}��U�ӵm���׃���.���=��H� ��Y�w������]ZfWY��m����qZdyG�n<���(ä�����G�>Qk �(�[���am��]������ p�V�ԧ��c:0�%�c%�_�ux���*�$Ku��*Y�J�C�4����qn�q]��l�!����EYZ��ÝY�����A@[Wt�z��hc�&�?d�����.�/L�~W�� �pLG�0e��������?R*�0D0��P�yn�?�%��e���1(���G�0] �A�K!b�\�J�}�k���e��_b=D�ڼDU��i�l�E��̗,�|U�%c]����a��Mp�Ͷ%�/g�f�=����L��-$,U������FU�����ң<݀jrˀ���pQ��|��X0%��ِ�s[8.ڮ���h��$զ��M�ХqeKnh,60������cWy(��p�q^����`H{���V�~�e�6l�o�A�bc�=$��`�B;e����\�Q|�|���.�5k��qObqWE�.��ڷ� �4R;V��sD[ٌE��<^���saPUE��A�,�E�Z!a��V�}V��Ȧ�o瞜MN=i���_v�C��kF�DB��7C��#�"�M9�z+�\F��rrV�#ҟ�Z�쨅 ]��uh��za��������j&�hGG���5hT�`$'X��_�&xk� ($ �� j��L��`��p���˒�;\A=���D2-���m��6q�>B��w�8,ځ>�y���/�3w�˻���ί~��j�����=�M9c����7LC�B��[�)�co�g^��|�UϷw�+���1��9�͇Y��&�q�K�����g����J�Ƞ�?*!�@ܱ8�� &;����H�( )��@���y�.�cAA2����!����j6O��}sHi8����;�F0�7P�@A"�Y��IM����M�}� ����7��i���*r�����������H��+����Y����T���@��H8�����؝# B0y�<;Q��g���\�S�f�<�>�q:��yV���8T��j"���pǡ�k�0�㪍�����r��[�}ƚك��4K���0��4��(Y*}+�yX*�-vr48�(I{�F��m�u��Gb�j���k����s~ �MجDLڍ�̝�n5_�a�k(��Ӽ�2_=�(�<|��J��|�Ȧ���9��e�g�[���q�y ����~;g���Ezƞ�mt����y1�biv �z�õ�e�p�i��T���$L<�gu+��=�q��Y���l#���q&�i�Oq�*�[B����"�w��{�{�j��s �'��e(� �����+9��3$�G�go�����ñ�a*X�˨���0�as��{<��-��P�`�vi"�8��.c|u�D�~s$����ﯚ3�ߛ��:���U�EqWm.�p�8�ICS/��ڻD���q���J��ԇ? <j�7jh:\+h������k��G�?����<&��K�}�Ľ�l�(,��/!P �e�d�i���� �?7�Q#��ÁۃO����^` n�#�ᑕB4�P��u��%6:�a���:gr��:X�^����z�f�`���wI�;��o��~7�,O��V�LL�E���dUf7�����%;�̌U����z`P<���s�bϜ��� �F��(]�pƔ�cT<'�n���Y������ y���$S�ڠ(�O�R=����f�\��]k�3������{���!i 0e7�A<1��2=����1XS^�IJ�:vL����~������=_��:��)��!]]�w���� -l���R_�s��;L�� ��ޛ�=1�O��iw4F�}���w�- E�$>�쿡A9��p@��S/h�Jq��)r�|RA�n�*��ߌܾ9��R��֨��<�0�m��g<�UC��� =����@�ٟ��Wa��E��_����3Z��*�wGf����fe�ZƟZ�,��ʈ�B�]��?�m�3j��3���^�>�;w�lu��~�3���\�M��|TU�bo4���2�O+0`H}ͬ��#�5,Chs���ѫ����x\ +l���R_�s��;L�� ��ޛ�=1�O��iw4F�}���w�- E�$>�쿡A9��p@��S/h�Jq��)r�|RA�n�*��ߌܾ9��R��֨��<�0�m��g<�UC��� =����@�ٟ��Wa��E��_����3Z��*�wGf����fe�ZƟZ�,��ʈ�B�]��?�m�3j��3���^�>�;w�lu��~�3���\�M��|TU�b4���2�O+0`H}ͬ��#�5,Chs���ѫ����x\ c����W��} -}��S����@�Z{!`���ꋁ��D3k��3� -r�R��@(��D ڭ�ň/|��٩d^#��|���N+�^Wk��U�[�����}�kT��z�W�5�*�|�'�W���������:ΪMO�l������UƖM�����y��n�WoT��hme���K�n-���n 3%P�aE.�ޕJXw�T�O9{�]�[@n>L�N���j��9Ի�B�BG�)���*�խ.�3L�i�ˤ�ϊp�����&KJ�<LQ��ٲ��"X/��L^Quڄ�v6/(ƴ��y����_�j��tpl�W]�������tY!�:����8/MH��!��=q�T�����k|���� Ս�� +}��Im��\��$п�^�E����b�u6�̚��L���6�?�a.Q�v�1�F�~v*���:�_�Ac�� +��՚�c�V���}_�U���nͥJ!�� ���Bfj��{����jӓ�;[�=�<�{��e��c�hw^/�������m'Z�F���R�[�6|�[@ �=DX�K�w��Ɲ+��S�^o���������ey�Z�}�n�Ѕ��n���� +su�K��oZ�2)�"ܨ�,�z�ɒR9S���y�������s?SD��_T�6a�� ��1��m���9,��p$��U���}�$]V��(��>�KR�qȣwO.��h&!�/��:�_b�� endstream endobj 1044 0 obj @@ -9381,7 +9352,7 @@ endobj 1043 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F120 619 0 R /F163 997 0 R /F159 996 0 R /F97 510 0 R /F44 228 0 R >> +/Font << /F45 229 0 R /F122 619 0 R /F163 997 0 R /F159 996 0 R /F97 510 0 R /F44 228 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -9396,8 +9367,9 @@ xڽZ �L{���aw�e9g=q�0��/�C���� ޥ4�,�q�#�<��*��A�����b��8U��p6�(�/g�a��FS��/.߮��:VǙ}Z�1��R.A���XF]S'D����T5�.��%L9ha���usDV������$�,800�H���wg�?( C!�}��ޡ!���Ccﻹ�qr����ܥ~0���<� ������!�B#�B�i�����9|����T�<�k�x`�ʹmʀ%"��̧��8� �Z8c�>���Q�t�����������,*�tc^��%s�:OcO����#h�VM����p�n]��I�Z���j�I��w�,�D>H�X�F��2�)L� -���}E�4�d��V��6Kc���fa����nU��6��$����h�;=�(L�}����1V�X�����rO��˟s|�X�Đ������� sl���aS뺦C[�����d�̡麐�T���H���������2� >*���ydHd���O�5h����2댟�����[^ȵiϾ�gL�tEB)=Z�@�PM���*�A�ǁQ�i1�/�+Z�z����|xRbL{��D'�i�?�����L+K�O����z������[0j+��L~�%����L'��~/�i&�o0�������z��u���6D�k������\��z��9�B�0!x��*�e�D��{�<˻jl��o���'�E o�JfY�}�L��4�kL�����r;p������0}w�����������߮��o����I��O�A�t��C�̨C�ZQT�S�Dú�C���m���� z!{��,ZKp���d+{ٰ�(x/y�0���`bL@ۤ�� 0��%#疄�⦢a�q����"2$n��t�O�>n�� J��T~�ŋ�bI�%���@Y��̏����R�X��Ê���s0�'(�JgW6�Ɲ��u����E3��F&���l#�l�e����e���V��#�����_�VC[9���U+<�u)?B�=�+����T�o<��q�_n�|�o�S���'gW�z�q\ zN��2yȹI�{��8��V8k�p]�l�S�\��y�����%M�Q�d#�l���@�`����<d���#�4�Ú��@��urd?��a|6y�L�����{Pz##(mr�.���w����d�V��&L�D�}���}�K�G�`��Xz" U�z"/KY�<��pzc�pm��!�j 2������u���zP/�THlEV�������\v��D=��>���OO�i$46�k�� -��"�_ ���0.�<m��E�q���&��͢X�lX<�@�g�誀�_�=݃E��Hzb`=��/�8|�R���V����q5��&S�"`��c�`�m.��b�� ��r�6���������$; ����R���������Za��v�S��`�ae��i��*l,�݁�w��0�߭.�]� �cR�����YVƐ8۳GB˩� L���>��q�Q� v�����TLn�F뭊Z��l��w\u$��6iH�6���*�����05[ɶ�;>D�ڸj�)�iaFu]��{w�ݷ�|~�ި_Ŋ�Ya��e�����y螢�\�Z��.k<l�f�Ā�l������j�1��������qH��X��#�6U;��U�w����y�Ѕ��`�L!ni ��S�C����x_���>��Aʅ�'�`�eԾ-��'P>�Z�Bh筳�r �,�8"�"d1��~�P���������Մc���ĹWx�@`�б=٘��<-�'J�.SF��ð�HP�6�l�v&�E���J���>a�LF<���9 ���[��4z�pRB`�iϡ\4Sr����~$��#��O��s%�OOZ��8��M��X�����Б�%�iT N8P�-o ½�Kp��)=�����c�j��C<��Uo��G��j�=���=��}��:o7��� ��:R��)�����)��t^d��(�Ϥ��R���f�1~�ݭ z��ߞF?˩z�@rc�>���it8�CW Pj���$�_%x�UBr��Q��R�ېu+ˑ�<����G]ٓ"jmqR�������7����MR{�ɮ~`�ûtn�05V���ԍ�=(���L�R:y����f���w��(�/��B���ޡ�l��MZ$�44�2_��n��o���Lf?��>%�t�΅����n�����Y����^��q�K�T��0�YW���������L�Q�p% ����մ�WzC�z�F�~^���h�����C1 ]�4�,<��/�g� Q�����蜍sF�9��A���p�D)x<FJo�/�6��2���6c���|u;���(ս�V}����������J4\�q�e�.�By�Ņ�hIlO��l�k�8�V31��7]�����5�l�E����Y��G��'1�T���o�4{�/n �VB}������5Q�D�(��7�ٿ��mE:�jWļ˒�R]W�m�.�}%���(��Mc�3�|3��I�M�h���u�J�B�*��,������y���@�Ȓٮ1&�M����no5�ͣ,�UDy��;U�|0��u��ɕT��l�;�@�9 �neV�{F9��vkW�P��߄C�ec<c�:��d��z +���}E�4�d��V��6Kc���fa����nU��6��$����h�;=�(L�}����1V�X�����rO��˟s|�X�Đ������� sl���aS뺦C[�����d�̡麐�T���H���������2� >*���ydHd���O�5h����2댟�����[^ȵiϾ�gL�tEB)=Z�@�PM���*�A�ǁQ�i1�/�+Z�z����|xRbL{��D'�i�?�����L+K�O����z������[0j+��L~�%����L'��~/�i&�o0�������z��u���6D�k������\��z��9�B�0!x��*�e�D��{�<˻jl��o���'�E o�JfY�}�L��4�kL�����r;p������0}w�����������߮��o����I��O�A�t��C�̨C�ZQT�S�Dú�C���m���� z!{��,ZKp���d+{ٰ�(x/y�0���`bL@ۤ�� 0��%#疄�Ҧ�a�q����"2$n��t�O�>n�� J��T~�ŋ�bI�%���@Y��̏����R�X��Ê���s0�'(�JgW6�Ɲ��u����E3��F&���l#�l�e����e���V��#�����_�VC[9���U+<�u)?B�=�+����T�o<��q�_n�|�o�S���'gW�z�q\ zN��2yȹI�{��8��V8k�p]�l�S�\��y�����%M�Q�d#�l���@�`����<d���#�4�Ú��@��urd?��a|6y�L�����{Pz##(mr�.���w����d�V��&L�D�}���}�K�G�`��Xz" U�z"/KY�<��pzc�pm��!�j 2������u���zP/�THlEV�������\v��D=��>���OO�i$46�k�� +��"�_ ���0.�<m��E�q���&��͢X�lX<�@�g�誀�_�=݃E��Hzb`=��/�8|�R���V����q5��&S�"`��c�`�m.��b�� ��r�6���������$; ����R���������Za��v�S��`�ae��i��*l,�݁�w��0�߭.�]� �cR�����YVƐ8۳GB˩� L���>��q�Q� v�����TLn�F뭊Z��l��w\u$��6iH�6���*�����05[ɶ�;>D�ڸj�)�iaFu]��{w�ݷ�|~�ި_Ŋ�Ya��e�����y螢�\�Z��.k<l�f�Ā�l������j�1��������qH��X��#�6U;��U�w����y�Ѕ��`�L!ni ��S�C����x_���>��Aʅ�'�`�eԾ-��'P>�Z�Bh筳�r �,�8"�"d1��~�P���������Մc���ĹWx�@`�б=٘��<-�'J�.SF��ð�HP�6�l�v&�E���J���>a�LF<���9 ���[��4z�pRB`�iϡ\4Sr����~$��#��O��s%�OOZ��8��M��X�����Б�%�iT N8P�-o ½�Kp��)=�����c�j��C<��Uo��G��j�=���=��}��:o7��� ��:R��)�����)��t^d��(�Ϥ��R���f�1~�ݭ z��ߞF?˩z�@rc�>���it8�CW Pj���$�_%x�UBr��Q��R�ېu+ˑ�<����G]ٓ"jmqR�������7����MR{�ɮ~`�ûtn�05V���ԍ�=(���L�R:y����f���w��(�/��B���ޡ�l��MZ$�44�2_��n��o���Lf?��>%�t�΅����n�����Y����^��q�K�T��0�YW���������L�Q�p% ����մ�WzC�z�F�~^���h�����C1�.� �v�����3���IQ�\vt�F�9���� @Sj8��<#���Q��`����d��s�v����nc��^v��utk�����m�K%.�ղUE�����B� t�$���k��s�V�������`����M�����T�Ĭ���n�֓i*a����q��\����+��[I��A�(c�qM~�ɛ�����6�"�p�+b�e�b��+鶍B꾒���E������m���$ߦy����]�I���}��m��wq� +R�<QW�l Qd�l��&�@VS�����Q��*������@>�kj��Z��J�x��O6�b�ܜn�2+�?��]���K(�Սo¡�1��n��e�{ endstream endobj 1061 0 obj @@ -9555,7 +9527,7 @@ endobj 1060 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F33 531 0 R /F30 532 0 R /F120 619 0 R /F97 510 0 R /F44 228 0 R /F159 996 0 R /F163 997 0 R >> +/Font << /F45 229 0 R /F33 531 0 R /F30 532 0 R /F122 619 0 R /F97 510 0 R /F44 228 0 R /F159 996 0 R /F163 997 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -9566,15 +9538,15 @@ endobj /Filter /FlateDecode >> stream -x��Y�o�6��Bp�T����S�<.z�8��[Z-w�bW��a'E���$Jޭ�n��(r8���fH],.��`Ӟ��&��7g�`x�=q�3�2���$����#��.�+6�i���g�Yn�q-�i��)b��L�D8�s:�t��$)F�T �IQ�*᠑$���� -�2��ј7��kj������/k����qL����1JR�e��$�gi&�j<��c�Z1�FױyDW����o��'+B��"�%j�����kpJLQƄ�dH�i 2�ߋUp�����<"" ?Ȫ��N�-�?{����ki6M����`��1�w�t��Al����S���pp �@Np�Mpl���!0Ox�ćW��V��4yW֕�xӗ+�:՟���V�kULD�x� �+�l'� �� �� �b� -~qqq��W��~+�tN��0x&Yll6������V�i��݄cp�ǡ��������-5[(��ʎA��f��֊r��$���bx��\��Wֲ��1o�Z!�{6�kK�N��*����=n��O�YV��'���ds����~�.?~ ����yLj�0�E��hp²p�i rű�*;���b�D!$�D�d���0����r��ͧ�Fv}s T��i�ќ� F�;��,3Lo�run��m@�S��"�l��e�-����۰��Cܠ�Z��ϓqHo���סb��y�2�F��3�zm�L�U�湗ͺnv��Y~2�"�n�js���� 4:�(�wv =��q���� l�w��tI -�m}�w�wnA�@��9G1K�A��`J6U��h��W�V�H����5�M_E]���x%��Zɪ3�nO�X�坛�wFO�F/E��Q��јlz����0E�1}j35;���3m�cf��i[n����o�B���x��[W��s%�y��Z�H# -�N��|LK�@�O���нQ/<�[�m-�=�oF���3���d�2.�)nP��n��&�3�V3��ck`�mt6�"湒jk*��G<�ǧ氩�Rmg�L]Bj�vn}m m���U�ܘdi�5�L�d.5ȵ���Q���p�~����\[��%˺�~m:j�Ewe+�l�)�ƩQ��j���N�` OK'6��XΡܺ�j^ōW}�rKg��� 1�����0�R��������I��))ї����M ;#��pfK�!���(r]�X�J��s�Gs,f�-�N���w�Omh�MW�6��z[6]�P��a�\kyڰ�m0H!��&� ����%���Ύ�{Y� -@ -3��<1���2�@5�w�:wư���ɼ��a��|�I��N��,O']��{�=�lD��Ebw&yT�Z0�R��Y����{��_�qϔ*%�`�p��\��a��Fg`���e9��l����Ɖ��M��P -Lqtrbv�0 ���L!�2����{̉�s����@��X;�p�v}�Va��4�x�$<Fqj�<� 2�ru�6��Q�T�����J`�S�l�h����DB 4��Ŗ��6�.\8��L(�LƧ�f�jvoB<yf��S`ى�?�cH�G �E�R��tOJ�J@�ӥ�������9��<?lh��Y���D|^������*��ʗ�P�+�I�?P�z��������x���Z���7 �p���_8 �p�� |����^:Z0���i*״x�<�ьӇv�����&�r���ft4S! -�8?�+S ���D#Ks�n2�ÿԃ�/�pb��~��,:�PI=����H���]��Խ%�j�Ȥ�����.��Nך��-e��y$Z�sF/~x��q���G��7z��8N5� �ʭ���c����$c�Tݰ1s9��'G�x<\~��{�F��3�J������:���+�*��Y'I��'��N{J!�B�I����ȴ��:g�9XJM�0%��n� ����3���f�E��h69�f)rG6�"�F�����)��Z����u>Ea�e�n��(�-�����.x�U�� gR��#���+�%��4|�6{B��C��me`��������D��%�_o��&2�����Q���7��̀�m8Mp�������rs���Tۢ��&b�s�m�6y����j��l�u�o��,��ۺ�4xخF�z�C�puT�6��XtM��9yk��T���6wrk�ܞc�jvJ��ñ����~[x�z֮�(�U����������1�g�i�G�M3(f-�S6?���Z� +x��Y��6����Z���)J�OI��]�q[�r�B�i� +[r��M���7|I��n�m�]Q�p83��͐�Z\�!Ѷ���6�ѫx�<��\���(�I.�FE��������t��(�|֕_s\�Dz��/E�xN��~&����9�zzv�IDXɌ A�f�L`�f(ϴp�HSƩ��sTE'��v�f�M���騀�z�g��D=-��8�V���Բ�F9<��'�O+ab�Afu�'t��u�,��l�AȌ1D�T����z NIʹ��b��,�dn�{������vu{�P���T��M�V��,��x��!\�Y6�4����h ��G�J�{C��� �vѻP�(�2I�� '��6:5t��D��J2S����Nm��+��v��˵2 +��O����֪UlD�zI(�$�%l'� ��"��(9�� ~uu�*���a��tN��p�%<�[���`E���:���U��;մ`��n�1z�,p�F���[��lU痚-����61��D=4e�m4� �`I�5/��~m�>�;���xk���F��d.�7�����x_�Z7�M�?�gY}a�T �����o��vS~��`=���^r� +��h���p�Yi9"�"ral����N��f����Q�,�&�h��0�0�wW.���xӨ�o����� �5�w�(%�C|'�P���]]�/m�y�-���2D������,v���"Ww�N�K�ct��2���E�!�m��zTL�ֶѨVu�Yo�Ӂ)���>����^�9ˏ��*v��ڞ�9�ş�.�.�e��[�L�n�@��Z�ʀ��?xJm�4�v���ڊ;� A �ԂB �3kAġ4�RMU�7��u�S-c".��k-q�WIW�%^���֪���S3�vE�g��1ӕ�K}t�J�(��ާ8=:L1|l��L�D?��L[��;m�dږ[��n�z���n�;坫���V���u-�L#S��ܲ +|�H�A�����н�/"�[el-�=xhF�������d �s/�inP��~��p3�V3��=cg`lt6�"��Vzk*���08�'�Vs��u�����.!5L;��1��x�h +�:Knm���@&ř�kr�т(h�sB!n�̈́����Pn�W�+-˦�}c;j�E�e��l���ƫ��O�`�W; ���1-�B���ce08�Ap�^�=x��^���-�!�@�N�إB��4H�n�;�_'%�Ǥ�P��H�=�hfف)Ā3[���5G�����Tb.�ܓ�̱���06M��.�i?u�U4]��w��ջ��z�zV��F�S�Fl�A�nA�J&.�4���n�=�U�de�1x sb�Y�<�n���N��ν**�61��'���������u~~ ڧ���3�L���d �T�G�z3�t^?}���K3�Vš���L�+��9���1�l�~Y/#;0}���#I�u�7ES��S����9 h>?/3ȵ��L x��{b��,r͂ ��Ǖ��nN�:삝fO�T`�3O�1�H�!���� ����Jum�V +� +���H�0&F�dو;"��iK0]3a�3��b��ٽ PH�� �EL�e'��tI 5��,KF�)) *�ϗ�N������8^���[��)�L�[�yMt������+_�B)�& �H�s�5���n����͏���g�$�� �Bfa�$��ɕ��]S�x�h��cJ��\��)��rM�-��_��|̵� ���l�(=��P�m5P�3OS�,͝�!����?�Én��j���J���-���mߗ�m�;����LYX���U�7�����j��L$%�B�K!���/�'� pb.����83@%��i�֪Z�Ɏ�� 9_`�������%<J$�p�}��y�MHυ.��F������T����P��%O����A���#���)�ʼni��u.����?`J!�!����A�`g�3 r�Ut��F���$���=�0~�0�χ���o�j�����6|�"(���(�k�Q�8J��W��qVV���($H�Df�����4��x��g�� ��5.b�������*q���sD��|�!����C��J?D�+�_���ڷ�4!�����k����'�m�B���C�ݵ�������_��=�m�3�X}8��3��uh�u�� ��B�u��k�e�)Z6��0Ԧ!�ܫ��� +w�)��)E� �@*�]9����"��ֽ ��;��s�C�8h�A��:m�7e¡�u���d�?ܺZ� endstream endobj 1085 0 obj @@ -9747,26 +9719,28 @@ endobj 1084 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F120 619 0 R /F44 228 0 R /F163 997 0 R /F97 510 0 R /F33 531 0 R /F30 532 0 R >> +/Font << /F45 229 0 R /F122 619 0 R /F44 228 0 R /F163 997 0 R /F97 510 0 R /F33 531 0 R /F30 532 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 1110 0 obj << -/Length 3240 +/Length 3241 /Filter /FlateDecode >> stream -x��ks�6�?�3&L���7�K�Ҧ�o�IFCQ��+E�|�q�?�v�H��#9��B�b��X�����@�u}�9k�sޞ����w��S�D������������D3�& D<�ui�ܯE����""<�N�@��cL���CB�� #Je� ta�E$��8h�����S8��~F|�l���TH����w[�yU���}��Cl��/AI�[Z\�ǜ���\� w))yT���'|��y�W���)�E~9�q 2�}B���_ݞ]���>�y:�+��$�"'��~�.�����N7�.�ٍ,�jdz���dz=f(J��(�F���g�Y����BeΝ�"8��;�s�����`�� P NP��sh���T��t����4�F�����Bw�m��T�O���o(�8 A��"7ċ�㊘Ğ�)Jˢn�]��,+�����~o*̌A==�ɶr^7�vwaQ��� -k�w=M� 6!4�E-���˦Ɋu� �3�}�#���R����)�c�Sa�j�>�~@Y(`B��*���--���!��{�\� ײ�2�E�]�z���ׯ������^�)nM�pC+�J ��~A��na�ۍ<J��G�ELK��;�Te�y��N� -��F�j�����j�M���o�^�^ɤi+T��(����7�F%y^�Y\��ʤ�ףw�E���f#�P���$ם��Le]�N����FzhL� �>%�<[TI����)��fF���F������+ ܍���]�g��5�-By�Fn�mw`���13�"�b��,�����KV��ŶM�"�G����p�:�ͥ���f�\�����Ž�n�;l��Ɍ5���QY��Z�|�x�5��X�<:�=�^4+�8P������W�j%IGI�6�����'.ff����ۋc���c����]��b@��j�Ck���RPi���m6����[�=Б,ʶ�O�F�V�,Lo��8��[c8`$�X���j6�:r�9�tVH<4J����U��Zy��́�iŮ5*�{�Ur�\KYe_Pc������v�a/0��=.Y7z.�}ɒ㍙����-AU�Z:��$=m�`8��d>y�3s�ޜ�x"�fߝ��"�8�N�nuZe;ܧj4SV^�g=g��8�]��/H����F[��2�jDm$�Vm�z������LI,`���ahqR�s�&��7d�����qf��\�H����|����n���� -#��� R�v��/���Ex���E6�b>EpFb #}6��ڞj�_C��3i�O����vBfκ���6t�Pg�����=Ia,Db�LY�r�n˥!g��F��5 ���$A�&��hm��zI�VVI�& -w�������NKz� (����:v���jl �;��9���>���]��|PA�����N�*]���e��bs!5�]R�v2x��ҕǵ���Jj��%dErW?f���E��5�����\�l���Ӎ��R���cf�z������s)w��M���}���E!�6�t�e�����d����O� ��j -ag�&Z�1aE�e�!��-F��`�Ai�h<�HD��2��QW��4��|U�&�;���C�@��p�t@(D��*r`���� e�2l�F6e� Y�P7"D�T���Z�O ���YL�b����lF�x��](<�s&��Xԟ��#_��i{�5����y��LJ�d�x��ƿA� ��((1�Oj^�V��ȚV�>U���w��O]{��l�`}d��w�]�KYI3�MP��e�#��z}4�u�HגO���q��q�=L�Y�c�wUB��Ly[��>�e��<���و���Y_��S��ݸ��fu�٬11p���f�����aM�,�աqo�P�Ht� -ϳAm3(&��SKÞ"$�Uj�����u��0��v��U��N������\���y���fEuu�A�yX�U��sx��ш'j�#/�/JWY�g�eg(.�p�qDB�%�g�U��M;<��%�������I ��*�we��|ѮV����$�5��x�4����բ�p��,�3�e�A�/U�2�/_�U�l��� �y��ڸ�|[�{�����ҩ ,պ��'�-�*i�F�=X;W���R��A���L����V� fVM���B�dE�dI��&WK�X��t˥>��Ӷn�-��wHſ�j�|���0E�~j`�j��}6Yüo�� �]+C��姲��\��6P DyL�QJ:/�m�.�,�O�:��hUq�~�f�T����c�uL���\t��6��FW������ ��~t[�+Q���)��-%V�Z�g�r���>���ر�\ņvܭ�.��}Y�hb����� ��Kn6����C.��W�=Zcul��_�g������o�;����W�w�����Cbe�Y�V]0��:������������m��#�X'8:����(�G�Ğ�FDI��O�J^� �mQ���؆��I�aD�S�� >�^��ى4�t0f$���O�0�ؓ4�c���;k��\Ld�CAFt<�T 0��Y��<�������*�2,`����H���>E��am<��im�q����Ҭ�Z�����M�����ه�ۘ3����D����g�a�߆��5ا��˥�ǧ���ˀ ��;�n�c������J�D���K��C]��7�$�_B)�b�R_�"�?5�We��+�n�zq�_�ܞ1s�"����rՃ*��O���\��T������§��C����}� �4��S0�S�E����M|(~��U��q}E��@�h�\������F��q����{PQ��я��'��فi��uΔ��N�?@��yA��_�D�?���2��9sG��h�ۛ����t������C�dͳ|�(��bP7He"UX������9M��J>��&F�G�{m20D����u�=�����E4730�� -��}q� -3AJ�^D�����q����N��go����m�峗���l��8]���Ёz�ץX'�R���)�ˬ��#�Մx&���2k��0]��g����r�5�~�ESe��7'���7�Q:�6w�>Ұ�3l��sQ�KwM`��0Ygo�����EzW�;Y5&���!���q�N�rp����b�� L$ +x��ks�6�?�3&L���7�K�Ҧ�o�IFCQ��+E�|�q�?�v�H��#9��B�b��X�����@�u}�9k�sޞ����w��S�D������������D3�& D<�ui�ܯE����""<�N�@��cL���CB�� #Je� ta�E$��8h�����S8��~F|�l���TH����w[�yU���}��Cl��/AI�[Z\�ǜ���\� w))yT���'|��y�W���)�E~9�q 2�}B���_ݞ]���>�y:�+��$�"'��~�.�����N7�.�ٍ,�jdz���dz=f(J��(�F���g�Y����BeΝ�"8��;�s�����`�� P NP��sh���T��t����4�F�����Bw�m��T�O���o(c� �H��E�qELb���eQ7�`b�M�� ��S�7fƠ����d[9��d��0�(x�� �5&�\�����|��e�dź����Ӿ�sBy`)��y��1�@�R�n?�,0!�cTC��y`ِ~�=`.�ㆁk�T��"��^����W����vR����&S��[�����Z� vn����F%z��"��k���o�2�<�`'eNQ#d�JRdfg��&�j�7y��dҴ�*WzU����yY���</�,�BeR��ѻĢUF��z���E���]U���a��G�RW#=4&Aa��^�-���e|@ڔ�e3#ӉKb��I{J�ϕ��a�u���3r����|#7ɶ;0[IјY�J �N��^�M�%+[��b�&Y��#�S\ +N8X��R��m�B.�]����^7�6��d�Y� 쨬�X��A>p��vz ,F�ݞS/��z(WJ�spW�w����$��$q@�DR����3���}���ű���1�g��.�Q1�j� ������f)�4�K�6�� +P���He���B#m�J���~��10�H@,��k5�D9�]:+$��؍���q�<�P����b�����*�Z ����/�1 +CUn N{Z;ΰT���=�ξd�����{��s-�wB��6F0qH�P2�<�9^oNH<Z��N�|�K��U��:����5�)+�Ⳟ�xg���J���ih B��MCU5�6Z��H��C�I��Asa�$�T���0�8)ʹ|��2��d���83�w.�����G>�pe�~��l�XI�V�Or�ڏ)L�x�H��"<M�Њ"�Z1�"8#1���>WImO�ү�A�4�@�'���q;!3g]�bd�X��M���螤0"1F��R�t��Ґ��j��ᚊF�B� |IA��^K�$f+�${�;~�����o�%=�k���\��g���l5�ۃ�����it�N��.���]� ��_�x +�d'���A�.Ƌj�2mm����.�k;��q���Z�SM%����"���C��Ň�N���w�� 6����F߀�\�PqH�ň13b�U���`չ�;��&���]~�_�y��2��TVe������'��\5�0�������"�2��T���z�Ƞ4a4x$�|\��㨫Lp��a��k���!S��c8�: "L�B90O�i���2s6E #�2����K������T��Wo��'����,��F1 N]|t6#^<Z��.��9�},��i㑯���=�@�h�<�{&�y2�X<� +l �ߠy�{p���'5�m��idM�^���z��;����'�Ʈ=�A6U�>�?��ûa�.�ȇ����&���2W���a�>��: qI�kɧ���8����&v�,���1�*��A����u�2pt��Ϳ��l��Fڬ�MѩB�n�m ~���l֘8YUv��rTdb���i���и7N(a$:w��٠��� +�Qϩ�aO�*�Z�T��:{�ra �O�*�j'j TIx@A�Tg�<~Po����:���<������9 ���h�5i�����,ɳ?�3S��8"�����*~���z�`�Gd�$�Q����m�hW+YMS��Ú�i<�V�����jQL8d�O�Ų� ����F�ӗ��*k6[{��<cym�H��� �=H��wu�ԏ�j�J�̖r��y��,��+]fl)[� ok���z�v��3�&X�u �`�"k�$�@����i,�c ���f��i[7���;���f�T>��\�"~?5�F�T�>��a�7N�Y����]P��S��o.�p���L�QJ:/�m�.�,�O�:��hUq�~�f�T����c�uL���\t��6��FW������ ��~t[�+Q���)��-%V�Z�g�r���>���ر�\ņvܭ�.��}Y�hb����� ��Kn6����C.��W�=Zcul��_�g������o�;����W�w�����Cbe�Y�V]0��:������������m��#�X'8:����(�G�Ğ�FDI��O�J^� �mQ���؆��I�aD�S�� >�^��ى4�t0f$���O�0�ؓ4�c���;k��\Ld�CAFt<�T 0��Y��<�������*�2,`����H���>E��am<��im�q����Ҭ�Z�����M�����ه�ۘ3����D����g�a�߆��5ا��˥�ǧ���ˀ ��;�n�c������J�D���K��C]��7�$�_B)�b�R_�"�?5�We��+�n�zq�_�ܞ1s�"����rՃ*��O���\��T������£� l���0����v +F{ +¡�����/`� +\2���}�M����z���(=���r*�S8�1�0�D�9;0�9�Ι�{����H>o"(7�����}{@��:g�h�Mv{�܂u�S���xx<�~��y���[���W��L� +K�@�~;�:�I�[ɧ@�BBè��r�Mƀ�ښ�n�0��s���cF�_���\�/�^a&H�ՋH0�<<��}�{� ?���v�=�� A��|�R��A_��7����B:PO��Z����"�z�Ր{$�����]^f�2�����,�3=�V.�F�o!��h�l���$�66�<J��N�G�q���w.J~� ���&��~�ѽ"\�H@��p'�ƄWZ8�ќB0��iSN��x_����E�+ endstream endobj 1109 0 obj @@ -9924,24 +9898,23 @@ endobj 1108 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F120 619 0 R /F163 997 0 R /F159 996 0 R /F33 531 0 R /F30 532 0 R /F89 511 0 R /F97 510 0 R /F44 228 0 R >> +/Font << /F45 229 0 R /F122 619 0 R /F163 997 0 R /F159 996 0 R /F33 531 0 R /F30 532 0 R /F89 511 0 R /F97 510 0 R /F44 228 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 1129 0 obj << -/Length 2721 +/Length 2722 /Filter /FlateDecode >> stream x��Zms�6��_��� �y���\|n:M�ڞ�]���� �w����t��o�)��lK�]o� !`�x�x�X,y~{}żyyB��G����1x~��q@bƼHr�d�ڛ���%|ZH�j��N� ��:��܌�<��� "2f�d�@x ��v=kuR(�D詈��qT��}h��#�0���_��۩�� T�6��*�� ����K���n��Oc״�z^#a$[Ӳ梔{1 d�gg��3V�̪� ��릸c��n���e��H�����=9�;�� K��ۙ�c���S�]�۩�q�6/'��>W��Fge^Tzr��������d��U�M#���3�����G���{4�K�[x7�9�Y��P<�j 8�VsoW����X�Xo7�sx�Uz^$U�g��r�N��о|�����E|\:|` -��OB"#���$J��UR$K]��@�ظ^ʾ�E5&���Z���RG�:(t��t�t�UN�Yq�iۤ����Qh �����r������u��dʼn��_��T{Uuq=�ſ�w�O�]�(���;]s�i���)�F�²�Ab~�K=��*��UR��Uݻ��"��F.C����F��,P���8v��Fv�xv�W$!ּ����y �Afv0e�7�e���M�alT����G��+w���w07yH�Er�pb����7��{1x��m�U�8�z���h����8��~��u���G�g�J>�×:O�.��x���4-ד�.��zq�V�^<��I��.�z�&���bb�� l����/EbE�y�@�a��v~~�<]|M�+$����0��!���10 ����,�$�����H�r]�y�Ld�ЬӬ�ƕ�Uj赀�5������G��zJے�f�6���!BΌ?������立������������.�X>�>�5�! �$x�(`/�����{�3��@�8d1�f3]��ja�Z��~������.��ȓ�-%��*��]�$�f��ѵ*���2�"�I��-�c[�V�o�h\���E�]��B[ooĻRO�x�v��D:0��gv��[��x@��6�:<���w�e��P��w���:$a���t3����@����WX���p���FT�L�H�6.̑1�z4v�B��A`�&!�cn��/���t۬��&FbA�B�p� ���Iu0K�&����T(ZR<"��ګ��φ�1�@ -p"7�b`86fMx7~�x�Sg�'�# �h�: 1,���t�B C8j�k̸5T\���`��x3K�;4�@��x.�:~)���_V��.�d������ґ�T�JQ7B�C�c�I1�oQ%�zW���Y�^T�����6JE9t�XS�s����1���+-��za5�GMm��5��� 9��G����QnetV���@*_U�K�f�d����@�P�&OcB�����JO���ƹRθam�p4OJ�R������ :`��]��l}ZYٴ��=ɗK�M��T��)6�����kVY�Z���<�Q�q_�'=��T�;=C� 3���8 R9��3<����f�Y�ۼh���1w��\{�mv�Q�g�C��s��-�2��T2Kc�� ѡT/9��d�{7"1k�B��ew�.��&tne����;�M.\���8���j��2�)������㒛$���`D���F�}����\���z9IuV�&�6M��PS�/�0j�ZB�}���V�!�����L�7'u���[�VO`GרjES܌��ԛ�;��{&�U�3A}�5��<B�p�j� �K7K�f0�����W����j��� +��OB"#���$J��UR$K]��@�ظ^ʾ�E5&���Z���RG�:(t��t�t�UN�Yq�yۤ����Qh �����r������u��dʼn��_��T{Uuq=�ſ�w�O�]�(���;]s�i���)�F�²�Ab~�K=��*��UR��Uݻ��"��F.C����F��,P���8v��Fv�xv�W$!ּ����y �Afv0e�7�e���M�alT����G��+w���w07yH�Er�pb����7��{1x��m�U�8�z���h����8��~��u���G�g�J>�×:O�.��x���4-ד�.��zq�V�^<��I��.�z�&���bb�� l����/EbE�y�@�a��v~~�<]|M�+$����0��!���10 ����,�$�����H�r]�y�Ld�ЬӬ�ƕ�Uj赀�5������G��zJے�f�6���!BΌ?������立������������.�X>�>�5�! �$x�(`/�����{�3��@�8d1�f3]��ja�Z��~������.��ȓ�-%��*��]�$�f��ѵ*���2�"�I��-�c[�V�o�h\���E�]��B[ooĻRO�x�v��D:0��gv��[��x@��6�:<���w�e��P��w���:$a���t3����@����WX���p���FT�L�H�6.̑1�z4v�B��A`�&!�cn��/���t۬��&FbA�B�p� ���Iu0K�&����T(ZR<"��ګ��φ�1�@ -p"7�b`86fMx7~�x�Sg�'�# �h�: 1,���t�B C8j�k̸5T\���`��x3K�;4�@��x.�:~)���_V��.�d������ґ�T�JQ7B�C�c�I1�oQ%�zW���Y�^T�����6JE9t�XS�s����1���+-��za5�GMm��5��� 9��G����QnetV���@*_U�K�f�d����@�P�&OcB�����JO���ƹRθam�p4OJ�R������ :`��]��l}ZYٴ��=ɗK�M��T��)6�����kVY�Z���<�Q�q_�'=��T�;=C� 3���8 R9��3<����f�Y�ۼh���1w��\{�mv�Q�g�C��s��-�2��T2Kc�� ѡT/9��d�{7"1k�B��ew�.��&tne����;�M.\���8���j��2�)������㒛$���`D���F�}����\���z9IuV�&�6M��PS�/�0j�ZB�}���V�!�����L�7'u���[�VO`GרjES܌��ԛ�;��{&�U�3A}�5��<B�p�j� �K7K�f0�����W����j��� �y6�/��w1��H�܉�$)��yk�5<m�-nsX{G�.M77`ET}9�#��TD�x2c'A�x"Wq� -L�1� ��?�u���6����\ہ�smmH��o(�� ���H�9;�;np\�[6p����e�Ҭ�j;2g@�����n3 T��8��ǩ0d��z��/(aQp<5��6�����<�B�Q�سm��n���pot��4<���߫+�J�4q�*���5���g_�9�6�6�(��_{)V�ro�ۤR��Saxɸ�ޯ�K��Wp���&e�K_�9rc�kl���^����{j��c�����*6;)�>�y���@���'�|��yYU�N�6@��~ȧ�'J��\� "�!&6�D~@�6�|�.��\����'���^ ���$�k,� -�^�4dy�N�����.����Vi��;]���W��M��4F��aD���2��T����oҸ>\A���6�ئ�����* �,��qi?ej�f�Y�S -6e�О��m~7$,~�S���%;.�.9�)�}�]��)�̿�=;����!R��y';�y;�91��R��@)B ڭ��E`<^?[B�8�N�^����z�x-ִ ����~���{���qc��|���%��E�6�$�_�<Yz�Y�I0@�y~E��8�lr2N�&�k�,vG���bg�LZ�_浥|�C�(��֍�e����Z���O9�\�}o������7۶�H���E1e��l%Y�y�0O -��ğI�ͪ���*/�������"O+�<\U�WE>]O��h��)�>������n�ꓔ���)I�x�G�p��������M?��Y���S�����f�5�_�ڕ.*w���!Of|.��L��~5!�~�?�R� +L�1� ��?�u���6����\ہ�smmH��o(�� ���H�9;�S� ��v�N7���lY�5[mG��Cp�?�m&��0G��8��2 <T���e%, +�g�a����ƴ}y�����A�6�{� ح���n�=����y��T�{u�_���&�_���9��k1ǾÆ�fe���k/�j^�{�T�B���q*/7��ux �q� +��0Pälcz�+1G��`�p�m�+���{Om�|bu�_�[��b'�G:������㘯S6/��� ��[��4�D)���Dd2�����wb�F����%Ub���ݿ���?�+�sr�ds���\!ы��,�҉�:�������*��zy������3��ܞ����"����^�7���o~�4�Mׇ+���۴t4xE�J�5K`b\�O�ګp�│M�|*��"n�� K���i�wɎK�KNpʩOC��^�`?,0�z�p��&�H�~|��������>�Kaw��<%h��l��x�l ���;�{�~�����X�>$�o��������qj��Ǎ�[���t_�Oؘ����d�f�f$����a��l���8��]h���jo3��M3h��ז�_� a���[7�_�u>�"h}�?��ry��m@n�S?`�lۺ"��cŔ�:�i�dQ�u�<)l�&�7�z����L�C<�_W�<���pU�^�t=i�������p��*һu�ORZg�$e��m��e������6�`�g��Li�o;�c�M��~a�hW������<�� �4_�2I��Մ�I���P5S endstream endobj 1128 0 obj @@ -10058,7 +10031,7 @@ endobj 1127 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F120 619 0 R /F97 510 0 R /F44 228 0 R /F159 996 0 R /F163 997 0 R >> +/Font << /F45 229 0 R /F122 619 0 R /F97 510 0 R /F44 228 0 R /F159 996 0 R /F163 997 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -10069,7 +10042,7 @@ endobj /Filter /FlateDecode >> stream -x���r�6��_�Gy&� ���}�7n�NҦ�v�۴��%��.E����N?~p(��[��t� q=8������ݶ'�w�ޛ�x���H��Yd�y2�A�^���ɏO�� �`��b$q6�uf�ܝ�<�M���2�2�-7GSH��\$Ҁ��K%b�5P��s\���A#ID�5쟼�;���@��i�N���`��n���T#�y2��[�b$2r�Bv�!�� �d�~���>����!8h��@Zw��F��u��9��HJ!�%z�����PJ&�,JSo��x�Rzi�����]ޝ�<��kU�uө����N.�1,����2�J �㯡�����ʽ�t���+�k��@pKX+R�j� ju���z��'Oل��˿# o�N�6yW��鋕2�T�>���M�yCx+B0O��% ")<?a�|��^��o�v/>l���s�@����US#!w�Hj��R���/_�@�ݩ�hvsZ���n���1����6�41��� �4Db�Dr����ԏy<��=�lK��<�"��1p3<�;/�z�w�>o���Tc�y�?�$��}Qur��V�����Z-�`}�ݰ-J��I��M�4z�P����\|�������_��w?\,���|9F���ׯ��6>�M��Fp��pV-�!�{!^f�p���Qu��M�^��©J���#��Q�oUC(>�oQ��*�|����r'��k����ތ�mu_�}����=��t��9f"�bb`�m��M��t�����e�4��D���V�ܱ�y��k&��i�l�#c��Д�A�B<�Zګ�>l�*@g_������ +x���r�6��_�Gy&� ���}�7n�NҦ�v�۴��%��.E����N?~p(��[��t� q=8������ݶ'�w�ޛ�x���H��Yd�y2�A�^���ɏO�� �`��b$q6�uf�ܝ�<�M���2�2�-7GSH��\$Ҁ��K%b�5P��s\���A#ID�5쟼�;���@��i�N���`��n���T#�y2��[�b$2r�Bv�!�� �d�~���>����!8h��@Zw��F��u��9��HJ!�%z�����PJ&�,JSo��x�Rzi�����]ޝ�<��kU�uө����N.�1,����2�J �㯡�����ʽ�t���+�k��@pKX+R�j� ju���z��'Oل��˿# o�N�6yW��鋕2�T�>���M�yCx+B0O��% ")<?a�|��^��o�v/>l���s�@����US#!w�Hj��R���/_�@�ݩ�hvsZ���n���1����6�41�s/ �4Db�Dr����ԏy<��=�lK��<�"��1p3<�;/�z�w�>o���Tc�y�?�$��}Qur��V�����Z-�`}�ݰ-J��I��M�4z�P����\|�������_��w?\,���|9F���ׯ��6>�M��Fp��pV-�!�{!^f�p���Qu��M�^��©J���#��Q�oUC(>�oQ��*�|����r'��k����ތ�mu_�}����=��t��9f"�bb`�m��M��t�����e�4��D���V�ܱ�y��k&��i�l�#c��Д�A�B<�Zګ�>l�*@g_������ �0L(�Dx�B���z�]����i�M���H#�A�"t� �Ds�`�.Y��aWY�4y�hL��s�P{9�Fј(��<�q7�H�u�v�X!�R���.n{��FH8w4�$B8=�� C��OYI(��IX�g��H��[��T�h�>/ ��վ|�q�=�#vOB�$����N`[->}�����9#��w�@��=|����.C�F���ہ{;�ψl�혉#� �Ob�"|���0ڇ�if� h�OR:.� J��<"E�F3��䫣t��;$lJ�P┺�ݶ��`�yЂpJ�!3 7����h�K푧���A��YJ�����iw�i�UDf���r���mj��������U^+�6F�ݼs���'6�Q��S�QK��>��_�}�P��;����SG��m���E�3�=j�)��� �.!�$G�.r�P���J��z���O� ʧg�|��"�$M�3�dw��'3\T@Նj+=���Z�z��O��ۻǶX���)�HN�J� �L5�"8�T&rU&�D�IF(I��!Q�+0���(���P����I�R��E������h-���Ml�FA:v�?S��Kb�]K4�ۣY�T�l&l��+D�'����@�9��Vi�,WF[��=zx�W�jN�hf���,�ŵ���v��1�,�Dn^DȽ=.�4�g����8�L>q$coo*�����].��痋�o��/�]�~�mÜ��$�b67�t�4�zm��[�~/���R�����{�m�t�ĢEOv��6�M^ߘ�^TW�H���]��@�'��–�6�N��g�f[7]^Qw�WKM�`6{K�yY�-����*� =vG��jI�������<��v{��MQ):ˆFh~�N�=d :f�=��vf%�� �Y�Z���)w1Zo��mRfIA^ѭ���#�;��N�>�8�k��r)Q@�y�C�@�u�kM?u��\� ���d�x=��ݚ�Bw���L9[�b$�-n6�ԣ �Үh{�����s��W��!!����j*���ʻ�kZ9xO '/�!�`Z��lT�z$ksOr�����7}�/GS�Y��xo�Ü��&r���)'�B�F�nj/��D��m�o�©ۦ��`�jU�P)�� @@ -10077,8 +10050,8 @@ x ��B���MmA6ꦮW=r� ��Np�� ��u�ܑ���'=��ֹ�������o 5do n��[�婓FC1�mYNL}n�XqB}������I�D.�V��wy;��>^��v����T�f�2�j&DH���.�W�s!�@���j����Jt� �N��9�@��'�^{���E"�4?6E6��a�yse�N��N�3�����4`�u�0�ɜ���pؕ�Ҫ�^m��58t��kL�Q�>�������+@\�t���b<0�1!�.q��j�2�v�����]9<�҇�ݤ]8C��6g���k���}y��Ș�l`�Է��ؠ�����-X)�~p�7�B dTk a+ -������+L���ܹ�^-a�l� �t�b�`�0m��4�Y����8AƂ4a���ʦ6P<�էJ�ֺ���-� v7��/N�O� ��8q�m<�Ã��"�]�2�����0� �Ik�Ӑn��ģH@11�&����d�8>��c�(`��e c� �}�2�biR 3JrP��kz2�f���λ�!����wɺ������C;ޥ�z�D��= ����^���͂�b�թ�r6��������e"C�y�!���a(}S���hs��ʱ��J3zEZ��c�[��ELڽ�I�8^ļP�� �N�1Lƺ�2�c������e~�����>��z!�R�eO���wr`�w������Sz;�P��o��)$���:����N�ɬ?��;��r�l�߷����NO����i�BKǵ�mx�Ƃj9��4/������r����$��+�p! X*�Wa;m�5�۴�a����i�C�������sW��/�Na����']L'ݣ�iB���4�F�7��oqB�6� 1���!k��;s����� P�CY[ۉۼ�K|�ͫG nx[�y� -����۲.:�<h�QxG6Aʢo,�[Z� :��{g��@����!����r��$mR�Cf;\7l�e1��Iں�56٤z��2'�>q����~hʢ ��T��"����X��� +������+L���ܹ�^-a�l� �t�b�`�0m��4�Y����8AƂ4a���ʦ6P<�էJ�ֺ���-� v7��/N�O� ��8q�m<�Ã��"�]�2�����0� �Ik�Ӑn��ģH@11�&����d�8>��c�(`��e c� �}�2�biR 3JrP��kz2�f���λ�!����wɺ������C;ޥ�z�D��= ����^���͂�b�թ�r6��������e"C�y�!���a(}S���hs��ʱ#�WiFob�B��xl~+�����A�1i�Ë��о�� ��X�[�|�����V��ݟ�'��R/D X�,� ���Nl���2�1pJo�?����@���X �U�_g5�މ?��'�}g�^n� ���;�����1�;MZh�6� ��X�A-�� �������^n��:�$`�.�K��*l�M����o��� ���8mwR33�Wy�*����)�T2��{�:M��y��h�fs�-Nh݆$f�~;�cMq{gnst�����t(kk;q�7x���y���� o�6/_�=��}[�Eg� 5 +�Ȇ!HY�EuK�D�r����y`���1�6�<TY������M�~�l����,;I[W�F�&�ToQ�A��'�p���MY�6��q$��܅�� endstream endobj 1149 0 obj @@ -10244,14 +10217,14 @@ endobj 1148 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F120 619 0 R /F44 228 0 R /F159 996 0 R /F163 997 0 R /F89 511 0 R >> +/Font << /F45 229 0 R /F122 619 0 R /F44 228 0 R /F159 996 0 R /F163 997 0 R /F89 511 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 1179 0 obj << -/Length 2744 +/Length 2745 /Filter /FlateDecode >> stream @@ -10262,10 +10235,12 @@ x S�.\f�.����S�/"���$�P�S��̰�S������O�cݫΓLLdzd��b�}r�?ܐ�@��C<1".m Xd���iO��R����9+ֳ0㬘d�4ZK1w0Y*q����<�#�����(�?��AE� �GU�+�5qE*�.�┈FUR� ta4/�4d�G����OR��"�J<�y���))�C��w�97��.�x.�N5* ŬX��7���@��V�qJ�w�5� L���ZA�J����e$洗�/�Ȕ��+��j7��J=�6��I*�]���z B����&�k�0��Yy�P�,��1���d).���e7�C2 �UKvX.9�W�^��^����#ʣ�08 J�4�PV� y���'�R��Mzj���9Ƥ���fQ&�.E -�bs����P�ͥ��-�����L[9�����{3E���������kMĬ�[�a��(7lN̻a�{ZD����0-~�LE83�N��7f�ĉ�J���ALD��zM���i�����V�%����� S�`.����� s�s� ڱ��*Va�ΙAYG+ߜF iP���#��H`(���n+{�bh�X�"�2*�i��+F����S�H� `���sU�&K�?Fi^�˱X�mF�4+�~+���t]x�@��K��6� 0��'f�p�i���I���B�T���T�39��TF�:��t�\n��{�Pĉ�r��h����m�12BW�6���Yr" 5K0F.#�h�@CO���'u���13�8n��W����XM�`OMxn��J;�<-���_��e|�D!U%�.$���>�����ncH`��O���4$�)��A��5 B�M����u����\u���4v��1<���gP}$+ݨn�q��h�t�5��<D/�fѴ���OI����>�plU�p h:��P`�4���O���ܥ�_��/�g�~c�x�����?����ssߥ%���U�ᢀ�M/����F(�P�7�|�;���f�a���詧�dV�N]��j�B�p�l6�=n�9�^�P���P�FbE;P1�}��W�o`���ŋ���̆�~'U���x��A��A����I^�p���]SF�b�$,wJ1���d�%R��<-D\nuM�"��e��kA�e�f�i'�tc���t+�-dž �P3�P�ww���_�K�ͬ�j��̼��yk��Z��[u�:���r�p{�^g�j�I��\�|���c*E]��ٶ��<�a���j-���T6��E�~U{V ��^��T]v�� -��K6��E����F�_�?�B�t! �t!���;�!n�]?��b]?�)�x����ֆ�ˍ�� ��A�퀘u��ؕ<ܻ�,�-Iޘ����)���,K5��(��T7����3 c�q4��CO8d'� 9~�qt�q4��o��4��� -���`<�me�on��w��`�������}����Tw��ƣ������x78�l���l�{4���`8<�f�;���������S�c�����Ͳd�0�y��*sV��4��T�U��f�+˵��(u�)���0�!���e���?Ʒ��sx���v<���kŬ}v�k��"������.���ku�&K{��5��ԇh��q]\������T<��:�n+HJ��S\� bTlu``�� ɿ�F��鏭@����eˎ���8���^yۨ�!!����&���/�2ӥ��g"}�F\��S>H�*�C���o!�|���ϩ �Aꒌ��Շ8ɣ��4����i�q�@%�?��>�0-F��W7�;v�*��n!��w��m=s!�#�4�X�C���:��?W��:[�-��Z��#�T���a�<o�i9K�;M�\���2��4����x6�'� �/��\�ž�D<}��:����9Ι�M`�)���( `$�V�a�]�)��F�8����W��ٮ����f������~�s���B��r�l՝H����F���6-�^����Z��b�J�ua��o"n�dژ& -Mե��؍6�B�f-M%|��Uoe���t��k�X^�k܈t]V� ���f5�E��F�L1�a��K��B����B�GyO���L]���a�U��%k�d�Ru��$ʕ�0U�X�ɬ�VU�'f�tڦ���hR����v6L�q��<�岼f�촯�G���G%�Z���<���Y!(ON�۵Hss֢�Ӽ���O��܌)b�}���y�2U�h +�bs����P�ͥ��-�����L[9�����{3E���������kMĬ�[�a��(7lN̻a�{ZD����0-~�LE83�N��7f�ĉ�J���ALD��zM���i�����V�%����� S�`.����� s�s� ڱ��*Va�ΙAYG+ߜF iP���#��H`(���ZY��=j14]�uu�4��#ގ�|Щ{$O0�F�9��~��ʏ��4/��X,�6#D�x?��m��J�.���*�$�o�C��qb����_��4�0�!�KzA{9A�<0��Oet�y���L������WqKE�hn+w��&i�~�V� �!�p�m#(�O�%'�P�c�2� 4�{�49���yR�)3S��)x�:;�դ��T�����#��bZ����XƧORU��B��*X,�6&����$\�HC�r��~\��"߄:�^\�.`�U'�LIcG@�#�!(|�G�ҍ�/�_�FJ�_CzɳA��kM��������������W�P% ��S�~* vH���� ���]:��N�"y��1֍�:_ڑ���ف�:7�]Z���_�. +��R9_�l���~���Q� i�F�1��z*�J�a���ԥn��.d�f3�C��#�U���m�k��k$�P�à�ǭ^q��f�k_�H8��lX�wRe��:���9Hn����ѽ�5e�n�!�L�r���|O�_"5+��B��V�t*��X�;o��OQVnƚv"M7fj�J�r�rl��5cE}w�{O���� ��z��L��k�h���{�0��P�P.��P����ތ/����uƨ��tQ�1���G���=�RQ�E�m���s�����r[H�@eӞ]�-[�gQ�g��I��I�eW?� \��a�zQ[DOQ.o��u��.��L��Ir�Z�c�����S��(��c���=<lm���HZ��Q�d��Y�Z�]�ý���2ܒ�i +�8�R��˲T����+Ju�����<�0�G�.!:�Cv�ې��G�Gci�֩KC9쯐Ha��V�a����`|� ���>+�'��Lu��m<��@��w��̆�_�F�G��� �ÓmF�S�]]����:�;f9���,Kf S�G��2g�@-L�*L��Q��oV��\˱�7�RW�r�!C����PV���c|��?�ׯ�o��������Q��g�I�� +�!Bx.?=;/��h�Vh���_(�O}�vY�U����N��ᩃ붂�;=��� F��Vv�ܐ��nTH��� +d���P�쨿늳�;땷�ja��q�)o����2-3]�y z&�Gi��Ž?����<ԟ���� ������.�ȼ_}��<� +M�OM�*�+� T��ù��bt� p~u3�c"�����8��3=�J�I��8�w�+�l�R��+MN���Fp-W�s�[XڰL�7������&j ��]w��u��v<�Г���C.�b��"���g���f��L�&0Д�@�0�z+�0�.˔�Z#S�Zgv���l�z��e��{WC{C���ݿI~!EsJ9�J��N$FA�p#��j����W/OW�qZ�Fr1p%������77h2mL����ae�Fy!r3�����ت�� ^� `:X �5B,/�5nD�.�݈�W�{����?Hl#p���0Gץ�|!��T�x�yͣ���?��t�����0��IÒ�N�p�:�vD��y��T��dVL�*��H:m��H�i4)j}�L;�Ÿ�m��rY^3Wv�Wţ�s���p-omtD��''��Z��9k��i����'T]n���>����<����_ endstream endobj 1178 0 obj @@ -10489,7 +10464,7 @@ endobj 1177 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F89 511 0 R /F120 619 0 R /F97 510 0 R >> +/Font << /F45 229 0 R /F89 511 0 R /F122 619 0 R /F97 510 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -10500,19 +10475,19 @@ endobj /Filter /FlateDecode >> stream -x��[[o�6~ϯ�cT���>x&N�6qRۙi1-�Vb-l�#�sY���!u�|�F�b��э�x��E_��z�ΰ�ba��.,Ǐp[B ��$���� -=����Z�K@ABÔ_9BUߺL���"�~M�� -��"�tY�Q��H��)g."̱\I� T�jmxF%RR'��8��ﭕ���b���.��\s㲷d�U������ԲS�A�����Z - .�{T�\p�P%Lb88Âź�{t��t�_)t�kc�AH�"����]^) C���5z��B������ͬ�o�h:���+χ�* -7��s��YwTP�pa�Jc*5��?�5��?[�Z�Mӥn20ka �: F��Ж�T�59�V/־G��]:� ꒊ���X��j㽄����7[������$�!H A�d�q�,�a(�#� 9﮶K/�,�)O�������%f(Db��ț��S8 ��Co� W�M ��Pl�;߁�4I{o�b����T��TXlAū:�VR�HD��0�=ar�]M��1v|> f^��^������Z��e��E�JTN����N��LɌȂ9�1�1�O �4v�� ����L�2��Ǘr`�C(��`��_�L��uN�1�@I��_�&���M��e��N�(z�.� |3��� -�I��lK=�Z!G�Úp��b�ǘ`�c��\nj�fr�����0���:���^��q��O"N:�%qz��vO�X���k�O'8'ɴ��������D���o���H�e<�,Go�M�E�7��A�W��~�� -q������|�,R���%��ʞ�Wh�y�����@��� R���'?�l'�Ҙ�5���U#����!�B[cL �ê���:`z$uN'8�Ű_00���m�7��SH&�\�ߒ4�.\~>YlS�<�$k`���J)��D@!�̾W�KlW�`%�Y�x����v,n�aX��������P�1$�2�E�LJ���Ψ{̟�B�̟�ڮ�Ѝ� ��gQ�������c�1��������'�����dK�I���h�U�:\�K^��e����?����Aw�8�w��v��$B��,I�b-�e~M��X����4�y����O�;'d|��n�P�H��<�����vv������w���F6 Ap�j�-�!,�r��!���;@ ��5VN��a����� iP��dT-��O��� -�/���v��l��W'χ�M/��p�M2D����h���T�8�2m��|��:��8r�[���'/,'Ty��6�*I���):``�iP7�pq�,�-�10���Vu=���I�*����Ѳnj�a�?t�z��`o�׃N��Pt8���ťb��Z6�82Y������M�� -�y��v�j���������A�á�r�5�$>����7W�Qg��~�DSĩ�(��ȉ�;of�J�OV5�C�s�課w+f�'"�v=����)���Z��������d���I���H�ÐX�U����Z��HA��\f�Y������mW3��b�I�Iy\��o����,؝ek��&������+#`��_��k�P�$��W]���';��cKz�'�n�(��m1�Q���N�P�0��yH�+[Q�rs0�D�4�(�R�(^�gV�A����u�yh���m%;��|�jT�mWV��0t� ud�\8��<��E�xǃD$�����W�ܷ��)�I�zI�Xvrԭ?��νzm��e<���Kej�ر�fi\�+P\j��p��l>�u;��v����#�R��{X #��~�:aA- -�,Q�_;�����^��9 ������t�R_�T�4��|�ۮ�9�x�1�����|^op�՞]F7�.���8� X��� �"���^�Mu���$�!�]���O�!S������x�kΨ��� �d+�m�aL�(~lq��g}�A0$q���fz��;�_��;�{��{���I�J`Q�hu�����a�M7��R�y�s h�/m14ϥ��<�DK�C�H�'��Bt���3����&�wQ��B�Ґ���+1���O��ĹG�*�x�X�Y�����4�J��I�KUv��4e���K�>yYv�������m �'�Fb@��F�|�+g�Z������`�~�V[g��.&�ݿ �� f��t�lK����"/��y�9�K����M�cp^��^�\����<�.�aR�`�4�v�S/��+F� -�ۥ�J�/<���]J�G�a����#�]��k�}�v�����-VH��Iwۺ;7֖�9xh��B퓏^�(d�H�ls�I����0Uz�0Ov�]i��8��ecǦ�ܪ�,��=c��" -Q'�o��y���ϙὀ�ү��Rpj�``��+�m���I��F���:�+O���v�-�<m�=�������Z5��14�e�* Hi��4��$-����ti}ۨf=A�¨��.�e���?gS�&i����&��F�� �$�&S��+���N�b��!�2���^�M8��o -����,�~�hn�[~��E���/s�1'^� ������$�߯/'��1�̏�A4Y�Թ�e���qɭ�[��l;�nA̚���I��&����w&Q�u������쥋��J��>?W�ߓu�����²��m����P�MR�ƃ������6��LU��^!5' +x��[[o�F~��� �㹒���A�eW�-����HA�h�ITH*�E���/��P)(����7��|�6]NF�x ϰ�b`��.Ǐp��!Đ�"�#p��_k�/ S~MPd ���e�g�1�k�[H�b�������qf#�,Ö B�ЄgT"G*��IJ� +���1��~<C3@SS �+�o\�̸�A���Wc�Zf�� Ȓ��V<\S�A�K�>�U.�I(�&1�a�b]��=��c��:���� �d�R�]^) C�mc�lP�R���da|8���Imy>v7�D������g�IA f�-S��?���<���0������Us��+c\�1J���̦��8� �z1�=�4�@���M*J��oc��} f��o�7;o�j�����$�!��*ɀ!���P"G�(r����n,Y�(O�������%f(Db��НOW�S0�N7��iTB��&�`Ɩ��\�&i��ml��rp<#�{0�SP�Մ�� Q��;.C<A�~���6��v�������pt�#u���V�{-�dQ��#�(C�U%2sdFd�,Ę��ʧ�p��� ����L�2��Ǘr`�E(��`��_�Lk��c�����;�.M��ŝ���p7��a��[��f�[V�� �t�َjj�B�tk� ��?�;*���e���'�?��O���`��w;�'�'�$�S^g���x���o�_Co>[�9I�]Ǖ��[���,��<��z"���DF�6T��f�]�H�Ăza���O��^FK7>�4[���Kr7�={��,�^��q�,%$�X��O^�f�Ҙ�5���U#����!�BWmL a�ê���s��H��Np��a�``�����`2>`��L�0�%i�]��|�ڥ�yNI��<B�e�R����BV�}�0�خ��J����`�̢�X�C��%����C�jC�ǐ�ʤ��W�����I��??�<�?/ +t�ۮ���� ��a�������c�1������W�@Pƻq�#��$���Xt�����R�K^�d���?N���Q�8������$B��,I5�c�ݵ|M��Z������ǥ�Z��O�;'d|��n�P�H��\��n��.;H�������;��Z#�� �[��C�A������~�rC +�-�T� ++'���������ㄴ�z +q2����������ix��9۳����a�B��k \1E����Z��m�i@�6YϾx�x�r8��]���'7('Ty����*I���)<``�iP7��q�,�+�60���Nu=���I�*����ɺnj��`8����`o�ף���Pt8���ťb5d-��������7���V�:/��P֍[1�8^0Ҏu��3H{8TPV�&�����������7� �Ϣ����8�"�$-rB��ʝ�R���A-����0�Nٻ3�t�]���p��o���^S��� ����p��$G�#:��+�&�:�#�@U/9=�A�6��g�{w�}��c�'�&�qI���������9=��0ֳ(���ً���c�m^�5�t�T��٭��E�Yc{lI��d�-@E�³+��"�8HR�c(` +I��<�>([�9 +N"J�Q�D�d��3+� �e���2������F:����E���]149E�9�X.,PW��"P��A"��PN��+K��P��^�$�?,;9�֟�C�^��P��������ѵf��7�4.�(.�ZL8PA����D7�� A��)}X #��~�ZaA +�,qj �r�o���D�s�z������$R��$֩Vi����Y��s|�lc�͋��|^op�՞&��*���b �(i^b6�Xy1���T'�L�JiR��~�>���2���?ߏ������� ���d�]1��Bŏ-��o[�� `��jf0��S��o����[e��M�D�4����V�*�5X��w�K���Q���t�P<�$���-�#I��Dj� +сד��8��~��B���Ei��HC���Ġ�K/-��VS���mb Bd���O���d+ � +&�.�����.�w^���Ͳ3�6��5V�%����A�Va9�(��׆��������amL +�AJ��$�����<ٖjr�&�n�I��a��/u��W:7Q��y�Gy}�&Z��x���N��]��������ʟ���&m�����´)c�(��o����fa3����!��̶XQ �+�m+7֖�9xh��B퓏Z�(d�H�ls�I����0Uj�0Ov�])�7I���)6�eR^n�R�?՞1ĈmQ+�o��y���ϙ潀�R���Rpj�``��+�m���I��F���83+O���f�-�<m�=ojh��������K�N�kݲ_�(��ԡ�$-տ��|m|ۨf=A�¨��6�e���?gS�&i����&��F�� �$�&S�����L�b�i�����^�M8��o +���߬�~�(n�S~�SE��x/K�1B�'^� �����,Xh߯.g��1���~8[��s��v�{�vɭ���b7�nA�Zx��I�DxO��;�0�: SKH��|v�Ň|�S%�����+���6^U��mia��,vJ�l`�[�Ԣ�ࠃ{����A�C�M|<s������5 endstream endobj 1232 0 obj @@ -10749,14 +10724,14 @@ endobj 1231 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R /F29 648 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R /F29 648 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 1240 0 obj << -/Length 3173 +/Length 3172 /Filter /FlateDecode >> stream @@ -10768,11 +10743,8 @@ x ���� ��U�� ���7L�Sp����ȵ�6�|��0�3�T'g�+/L���$��߉Zq�D�� }�0�q�|��=�v���/Ԏ��_�$�����uO1�5����B� �:#�[���t� �>39�������ޖ��G��U��G]G� �_�ߗ�D@��i�=&�5宗ބ�������8: �Jl����2W�x~X~�TZ�m��b��D���~9}_1И@X��C�i���h��x2{��ǣ�<I�S쓰����:��-���W�7���3��E�2f^�ͪ��UF��?�� }�����^�ӑ�����Ґ�"<E��@G�Fh}܌/g��xr=��cK�$�*�4KԚ�8_�i��MUADi�P���S��V���V����~�-�K�|�@�`d�V��wfk:L\i�x�K�!_K��=e�� ��Ϳ�Qy؈��z�i�7�I�v��9r�RcA�A8���,I�/D�K#6�D�� ���a�5���IX�^�h*�-��������u<�i��e�X;��u@B���4bLɝ`�g��k�`�f�E�h�h�y����d2��j|5��)��aUdK���۾�m�IO�ꀲc;2�i�b��0[9np>�(���B�2pci�~^샻E�/�1x�������F��/��r�Y�=7��U�b`D���zޑ����yE^:�ס���Hn���g{��Z��> gF��[ H�j ��j����b>��8v�i|ws��I�U]d��I�įv6��7�v뱠�fʖ�í�k�T١� 7RGm�?�_y`�o�{���[k߆��x.�n���{�Z`:^�5 J��S֗F�f�}N������%�"����p���L6�n���9o��8����%�� Ւ�L�)ڗVd�O����T-m���5����^73�o�&�7��[�������x���$t�/V�K#��6�o�&Ϻ- -�0WZj��z�;O9�L�C]���9ζq���D8���X���h�������~��w���l`�$J���hx?m���G�R���#�����V���K+I�U��� �ޫԝI����A�/�O~��_�e����|._�cY��r���8�Խ��gB��[F�}�+�gy��N�̙���ۑnhj�ډ�8QM3�l?���0���X�WRJ���S�P[��P%@����#�X?���*y��e�M��S�8� -2UMW�Q�u$/0�|� -�_,l�+�f�r��Li��,�=I���D � I�e���0@3ٳP)-.�3��U�4V�d��Z������_�\m_&�"��e��c��ad��iI~�Ӛ�_���*�'ռ'��+= -��� u4�u�*��wfDse����o�N��䃁/ɟ�k�)^�=`X1�+cX^�*�~cX��?�����c�Ab�S9f���w��~ ���Z���I�xه����,��rOH��`��&n`����m<'��O_����V�2y�ʑ��i ��SThc%��*�W 㒵y���� -Z.aد����>�$"���W��%�*�d�p���0=Đ�,A��ˣGr�3pĩ�O����S�G +�0WZj��z�;O9�L�C]���9ζq���D8���X���h�������~��w���l`�$J���hx?m���G�R���#�����V���K+I�U��� �ޫԝI����A�/�O~��_�e����|._�cY��r���8�Խ��gB��[F�}�+�gy��N�̙���ۑnhj�ډ�8QM3�l?���0���X3���p%�208H���� .�J���7G*�.~AU���t��q%�h�����k��?_�����ʀ�Y���4SZ�9�q�AR�9�Q�GCRn�/�'�L�,TJ�K�L�|U+��B+Y=��o����W?Wۗɿȡi�8f����o���AZ��ᴦ�W,/���I5�b��A���xCMi��J����\٥:��۾�d4�`�K��*�Zj�u�V�����J���n��Ov~�}��|��F�T���@F!��_� -�V�=�d�5^�am��x1K�����+'�y�������w�Iv��W���U��_Ar�"lZH����X�� +�Uødm��,z���K�k�'��k�Hno���n���$Y2��l?L1$�A%KP������qj㓃�Ec���4 endstream endobj 1239 0 obj @@ -10922,20 +10894,21 @@ endobj endobj 1268 0 obj << -/Length 2150 +/Length 2149 /Filter /FlateDecode >> stream x��YYo�8~����m ��K����$�;;xC��n-���'��oQ��:��/�M�G],~U$OfW�͋#͑�Ώ�(@��D p@��b��+t��h� P�B��O{"�:ixnx�������E���� >���l�q�c�<�K����Ё>*q �pP�<Ʃ��'J�N�?�0sPӴ;՚�F����b��i������r�������\���.��V�B�J.1�� ft�Tw��麙�a�dz!%c����qvt�8%a8ྏf��ؗ��Y�Y��'�"Z;ԗ��J�,/Ut|3���l�Q�pQ{�/�����o\C����R�����A��h��3J���̧\s��j�vu]�oӁS����}2:\����a�d�i8��X� -=ן� G�waC�d�!�!ǣ��V4� f�;�&��BE���c�D���}[��;��P���<��¢Y�rCN��ʎ;q�����Xr�&D��i���7�h���Bc��8��e��T�t]����+܆ԉi5� -�� �r'���yK�� -�~/T|�0�O�L��d���eX��ZAӨ�P�{[�o���=3�S�幓��pL -#A�,�U+U��X�>�ҿ�敱�>�j�E�WQYl����`��C檬�T�m�̔�B��:�Õ*�]�\���\ō��*�$��7���zV�t��a�n�ꮈ�d�5�>S��hz�"�����s$0�9UV�z����' -�MG �B�k}�z �=��V�a�e`s��N+��}w�3a?v���ܺ�����Y [��Ì �s���` �a`c(�����uI -B�u8�D�ۋ���g��Wg�����q4��a���"����Iq����rՅ?�u��K�Fu���ٯ_�L��2��c�`b@��%�P �)��W���$d��;� �����:�@) ��<:��߿\�^����o#G�]9>W�$N��x��n���o��kVnOq��>�])�Ƀu�E_�2����~�j�Ҹ�N��^�+�j�1�uz��U1�$V*Ի�Ơ�Ԩ�uu������d�v9r�5��ʋ6� B/��d�:��}�OC=VI��a0��[��"Q�x^'P<$yY�J����|��5 N�W!�kih�.���.>$�>ۃڪ�ḣ6��cv������lo�yQ\}�n)�C�֊�s��1!l��fI7��Pt�ޔP��$R��]o����|I�g�p�R�0�?�e�T{ST!�@ F��9�ZY�lo־=�3C�xĮG�'¨݉�f�Ξt�HwF��Y(+�d�R�o�b/�`�9� ��;���6�a�UY̝�ʇpY�>ͰC��-38�m��W*-G���bZоk�褚U*���p�U��()06�K��I�Uy����~���V� ��������xMx�=F��"����cWD �?���SH�/��oW���M$i��'�yX��*�������}[�n:{s��Iv�V�ӹ�b�Mk�=��#��ǿ�}ڑPE�k�ؤq-�,����!h{���A�WE��f怡�>C��x7 ��~�X�naD�h-.��'w�������I��$��aF�����sK�Ֆk�Wݠ�8�]ҹ)���,N��FԬ<�<mt�?h4���:9 ��t��TT��e�4>��b�3)Ye�YY/���x�E� ��ju���ǎO ��ٱ��6�s���·��+�ƭ(��i�]�ߊ�=���!*� -���t<���m�����c��vJ+4�Z��pW�a.ΨK�� �D����7�C�d����S�<�����N>G�����? J#]���|,���i�� [�Б3�u���,=���o�l������Z5��cZ��>.:�C4��SĎ��z�B/�jˉ��4�_v�t6�d��!��l�7F�,m�mZe���R��Xq6�E��~�!� ���`�yZ�O>9_�}6ڷ�u;�˥i�!̔��[z�âl���y��uHӟa�hH�I�ΊpYO _\/�����6�j�g��&9Qq����� )�]ՙl p ��O���h��.��C�7�1\��Iԍ��甸�4I.H�ysCc�����H��+1�k-�s2�:���2 +=ן� G�waC�d�!�!ǣ��V4� f�;�&��BE���c�D���}[��;��P�`�y�TaQ��t�!��jeǃ����Pz�k,9l�kGP�4���}��KL���|�Uײ�Yn*I��JS��n��Ĵv��\9��Y��<�%��l\�*>v�'e�Ko����2,�s��i�V�Ž-߿�VH��)�����Ei8&�� \V���*I_,�ee���I���v�`5�̫�,��r`H0��!sUVy��6Kf�r�Le��J��.i�~TI��F�B�e��ӛ�?Wi=�V�Zǰv�EuWDy��k��}e� +�]NWu��9�*�G�F�w���ݦ��C�ϵ��w���F+���2���Om���Ǿ;ؙ��S{�n]Bx�d��,�-~�a�� ��9�@Ӏx�X����0�1�H��vȺ$!�:�l"�������˫������8�QɰG�F + +Q�J����UQT���:Uق%l������ׯ_�~}���01����W(��{�+ih`�_�҄Br����X�@���x����_.N/f�����������U'����_7�Џj���5+��8�X̮����:�/d�g�|i�b�Vi܀~'d����j���:�F�Ī�X+�]acPXj��:��:��C��^�C�����A�E�����F2��� ��>Ч���$R�0�uu�-�G��Y<�(���v�q[q�^>���'����44rPp~@�H��AmUX4�CF�1;�ryv�a�7���(�>k���!gk�ҹ��6�y��@�z(�~oJ({�D� )�̮����} �$��b8u)UΟԲH��)�p����b-��a�7k�ݙ![�f\b�#��a���Y3`gO�}��#H�,��y�Z��]�7U�yF�Ջ����`�q�0�t֪,��v�C��T�f�!]ז��D�+��#baj�? +-h�5ltR�*�FMx�۪��g���BˤȪ<R��^��XFX�ip����kih�&<�#�u@��}pͱ+ "������)���ٷ��p�&�4�ѓ�<,�{IQ���O���-V7������$;{+Z��\Y1⦵I��������>�H�"ص�\[lҸk�|�����Y}� ի"�U3s��^�!�Q��[f?G,�Z�0�S�����;O�_��~�$�~���#���E}����j˵�nP}�.�\����K'�N#jV�{�6��4�L�����eh����?**͇�2]�u1������Ҭ��J���P<͢��z@��S��cǧ���X��cb�ӹ�u��\��WוN�V���4�..��x�'8�f� +��h9%��p���g.���B��R� +Ϳ��4ܕw��3�R�q=��At{�,��=@Y8 0�� :�1 ��sT���K����0���n���IX�����9�^g0����Ûam���Ά��{8�O~�Us=��n���A�c<D��8E�H�G+�2����Oc�1�e�Ig�Mv�bP��v�{c��҆�ѦUz�/E�Q��g�0[D ����@zOK����%�����gӡ}[_�>��\���LYغE�w:,�� +�y\�4����t���������2K�<lS��y��m�'�z�����U�9aa�������TK��69��r]=��p��z�D�H�yN�+-@�䂴��774�8x�ˍ�dI���b<'ì�1� endstream endobj 1267 0 obj @@ -11058,7 +11031,7 @@ endobj 1266 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -11073,14 +11046,14 @@ x g~��P��q�P�&��0w���pDV�#Y�-�C��-80�;"�+�/�>�S��ŽE�����ދ�u39����Ц�?��Y�U~[�y0[t�!�K���t��7߰���?-J�ֳ\�ˁ�J�yW�P�}X�x��k |�[������]2�"ꑁ�ى��<��UVI��gu���@����bM��L�*��������X�ː���YV�c`+/z��tl�C\�l�b'�s�E��a���I#�ܧ���k4��0D|�0��[� �L��a���&�=��|���c6]�/��NfێK}��wqB����.'��2����lSWjx���e��D�?ġ����bNz+:��'��/B�����Ni*�߫��M�)Lk=LJ�,뻪�*^j6�|����y�`~�ww�:gw���}�<��.��f=W�n�QUފVW��O��^�c糋��4���%�p1�.f����DZ<xX�R$��D�b��*�Y�!�=��V�L]�D��<q���'H�rҗc��K߄gqI4�2��+��\=��>�b�N��z_������-��\�b����2�n����������4 n!���H� >}����D4�E�uQ8CP���@��,�a@�a���������t>�x~1�]\MO�9�z�~S0�yCW�\��zs>i`����]s�R;4�����q�D���#^|��s��k^v����q�`�-�2�Kc �wa�I��G�@��q�k -�ݶz\��ڜIz3��8�ztl�n[� �}����#o��ipP^�z UeE��bp�9�9���� �9�@(��_q�X�,�\FCb��~Y����������x��k*Ѧ���ȯ�c} -�w��J�3.@Q}�0�#P@F�u)�~�L��&��i�o*��4������Z �r;��{��J)��.��|S7l%�/3�����+�p�Z)�5���eU�QU� -2J��D��B���,M�d?4�l�"\�U�-Zďu\B�5� /���2P2כ%��*�2*��X����]��h� �3 ���P`�P��Ba�\���� ��|Mn�a�k��ݘ�r�7!�I����P�����1Yy�wQ>4�A�$�=��v��[���f���wp A�V�qp�-�ä�!p��E9&�S��%�`� ��&i{���v�4qS�sb�ȺJ�L�3��$��4k?�����!�Vq�{�p}�4)}�˓Ҵ�UܶewZ��O3��? -_J�o�.�j��F�l�ZhZEaa�`�05� q�N�(G��NQU��[U�N�2ԾQ����S�jI7y -��_��F=��$[ilt�|7��t�I��6Ƭ�����`�����9un�n5���^C�������e#�k�����l V���bwi(@��JR�����;���X����& ��ݮ#���\J>#~q��Do��I]/���L }_y�-w`��D �R�����Iz�_ DA�S)��2� ��5aӽ(�a�tt�ضߦȣ�,����HQn�r���C!�0�.AQ� ^ZÀ�5G���"�Є��_��Q���j�q��Pn�/@��<[}�낫<o�u�Qڸ�w���$��S�oI�� -��Hp��L��9��y����ծ[ܷ\Hw��t�w[���/Q�zf����$T8d�x��iX�j -��@jP?��������3�]^�Y^�>[��[Q<ͣZ��ZP�������QI~!�h�<cw��my;nO/0�m��B������v���C�����A[�!�����:�����aL%�ܙ�(Nñ��j�I`cצ� ����o�w�]%�EDՅ��u0��=�@�=M���D)N ��_���1��"=��{0k6]b�Y���Zh�����}�B4l�Kٚou�(W��W+�W��q��~M��I�� �x~�Y�Mz�^��A��ؽ5�C]{���f�_fuW��_��av���[D|L�}�0�|���lr���CM߆$� �L�T�+�Ճ(R�X��;��t��'Va����f/��2�<T�������I�k3���!�.��6� ߉�l����H��Ξ�T`�&��6�q��QX�4�q{]f��p�I�o{�-��j�@�� -Qs�6C)�z��)�� ���1��a��_��� +�ݶz\��ڜIz3��8�ztl�n[� �}����#o��ipP^�z UeE��bp�9�9���� �9�@`'�+.+r��hH����/��:xA��z�|M%�y]5�s�O���u\�v�(�o�}� +�ȸ.e�\��>��: �M�7��T�b��z�^�!Yn�>�aor^�#e�e�oꆭ$�eF��Q�}�nU+�Ƙ<���:��WAFiҁ����]hr��)�������MX�븊�E����K����%��[fJB�z���BEWFE���������s$�� +L +�S(��kp�~�a��㘯�m7�ym�ݣs0C��&�|# Qu� +�ב�2&+��.ʇ�9�$����.�u�1T��Д��"��=γe�v��#NR�(DŽpJ���,��7�$m���n�&n��A�YWɓ��afb{�D��`��z|�>��<��*n`aw���&�/�uyR�6��۶�N�z�i���G�K)��u�E^�����ZM�(,�L�F:!N�����)Jc�*Px�J��]��7jۡT{JR-�&O�2�krڨ�u�d+m��Μ�����"��Ƙu����!Ss����03�.�Mխ洖��k��0�5~P�l}� }����z��C\�. ��V]Ij4"�z�{�|��s^|ߤa��uD���K�g�/9���q!���C2T�)���"����2�(Q�QUSVC�7I/�D�(�v*�B�@�4AҸ&l��4�C���.���y���~�)ʭX��#�q(d&��!( +�Kk�����]����K�"JY]�8�� ��v�gˡ/v]p��m �N>J��]��V| +B�-��Ya�� �W� �7'�V�!o�w���u�����u�N�n����e"J�U@��u�� 4��j�L�:9 �PMC��H �0�x�\�\>y��k� �+�g+��yTKWV��]\�?�=J �/�m�g���-o���ƾmP�R�`��c��T�s02c��9ha�7�t�C7_�4��9L��ĝ;��i8�U]M1�6vm�w?^@~#��*�, �.����m��9��9hJl�? J�p�H���"�w|��yv�adY{�����Ͳf~�B��?����a#�\��|�#(D���/�Z�R�뎣��kZmNrp�����_�Zo�k����5����C�4�00��2�����b����@~�"�cR�K�a�K�d����jB�6$)N�d���]��D�"��މD��?=� +��,���0{Q�� �2L�@$�4O*]��WE�w �y�N\�e+��HTErWw���h0!=�y�S���r�����2S���M�4xۻm�|W�W��˴J9�ՋN���N�T��[������ endstream endobj 1310 0 obj @@ -11221,7 +11194,7 @@ endobj 1309 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F33 531 0 R /F30 532 0 R /F44 228 0 R /F120 619 0 R >> +/Font << /F45 229 0 R /F33 531 0 R /F30 532 0 R /F44 228 0 R /F122 619 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -11238,9 +11211,9 @@ x ̥��P2�0h�#�&�E�u��##�\� \»�����?�� %�l\�ّ�t�\�ɩI*�r?.!R�L����]�K"����r�����/��w^�J����oλwSz�X`�^Oټ��u�e�H��˰Т[��vmْϪt� 4[�d+{�7y�| ��h��M4y��*���k�f>Mx���l��$A谷Ci.�md�#[`D`L�/�1K�8W!�� /��N�9���7�[ÇC��,U8��������������$�ЏK����(�s����(��Xq��}��]܅�p ��s�j��0�I��҅�����<���8ʖ:���}����I���ɆlC\��<L⸛�!݄ -2�����@��:ެ�n�����Mx)���L���،�:�F�m���<�c��O -^�+���u�ܤ"w�)N�^В��O*�v�8�E`�Rv<�u� 9M�ژ�D������d������%v��J������:��s_ugۗA9�ndm#���m1���d��I^�yI�oE�* �����]��)`Ȧ<�{'��T%�Y;�4��Ms|��c���f̄`a�������40�9�|P�Z���!�FWG�'��~����)���+�o�X`�b������4^@��Tc�r� .��c�g�ѻ�Y�{����D)�8����;��e�km�nƙ��k�M6k���rX��5�����ޟ�$����R��B��C���#��=R������1�V+1\qX�FD��Ѥ��!j�Q��؍1�+��"J�J�Q�ب�25^�`:Xq�o������gp�G���Cb�� |4^�Գ�.y��: -���v �,);~:/҉���o��<�6I�ޫ3�_�U�E�Џ�p�&�۩A�7��=�H�i�����U2!�cB��k��Ug�*˔]%��:)-��٬�����\��(�o%e1�n´<TW�i��i�*R^|1E8di�9�� -�?�ӵH +^�+���u�ܤ"w�)N�^В��O*�v�8�E`�Rv<�u� 9M�ژ�D������d������%v��J������:��s_ugۗA9�ndm#���m1���d��I^�yI�oE�* �����]��)`Ȧ<�{'��T%�Y;�4��Ms|��c���f̄`a�������40�9�|P�Z���!�FWG�'��~����)���+�o�X`�b�Ml���m�N��J5 � �B��>0�z�����)9~@�B��Hꭼ#�aX����f`��{���d�6K/�U�]������M�K).�/d�>� Py˝1�N���#�_����j�#��mD�qYMz��ve����#���-���������(S�������6��/�Y@0�}f�|t�~��:$�!� �G��J=Ka�g����{�]`װʒ�c��"��[?��Hϣl�d��z1��Y%Q^�( 7i����z�H�I��D�F/��_� �8&�m��+]u���L�U _���2����* +껽�e +���V2P���&L�Cu���k�֩"��S�C��1����0��c�5 endstream endobj 1320 0 obj @@ -11312,7 +11285,7 @@ endobj endobj 1329 0 obj << -/Length 2047 +/Length 2048 /Filter /FlateDecode >> stream @@ -11320,12 +11293,10 @@ x ���N��/1���)e�p�B��g��p���[�I5��Q�kr��ۓ�AV�����.��YSʝ�w�**�#6_7�9o>̼����MRG;�&��ܨ������,y�X��XS&�WBx����oM[�|�H���vУ�B-N�hz�2�1���B:�f�B���˓l��+wy\�QkkXI{I���Ʈ,L+P6n6��6�4�kG�Aw��jJ�(�aRTww��>O�h��0r"�f���1/���:hP�B]By��g� F�<��V?i�1H.f8��D��Oa��������*���a����*�v�Q�p�͆�*�� �Ȳ��>J+� b�7t�ơ�$]��'��I��1��M������O�Wog��/ ��@mlA�w�����Bw��v -�R#���>i�Wq�V�Vy58}8\{.�1����*-a���8mb,78�(]Ui煨h�@���O#����9}�C�B�q.���_!���)ü�v��`-�kXRF�k<��h�,z4�NdX -�I��;��e�1�7ʰ:����+�t~~�G�z��{����f��*[i��c���zQ/���t��W�m��}�LJ0��D/��ցs��@u �R�AjGp7�j{�~�{x�}� ~�S��{u���|S�NԎ#���JX��@|��f�B8Ѡ�qG5�Շ �{�}~�����0[^�v9�Z��:�IU��گ�^ ���ц���q�Iq�{[���Q[_><[^��6���T���Yn�+�q���a�2���^%PYk��%8q.n͔�~h��fN�� -l(� ��{�ڄc��qȜq���`�%_�i��D[r���� -����ؤ'q��Knl{�i�×�9��.>24l��<1~u�J�s���F�Rk�ylj���#�y���v��!��?�aλ���tQ���V��(sӮ6Q�}-<�<$� -g3��e]�i����U����T����g����XB3Pt{�An��}$$p�z�1��!����l5����B��Q�w��;%�=H�P`��`�t��%LJ �z�Z^0��ǖ����%��Qe�<Y@��R_�)�����wtt`:��Q�{ �����2�k�5_�x��i����Б;�uG���*Mސ��S�n�<=^?d�Ѫ�F�y�[�*Mq�&A�>K-����W[�2��;q -R �����o��,�%���>�����'�n�M�̘���\��̄(a��K����M�a�M>�s����LhlC&�T8g��]����bݷQ�D'q���E�L���y�ПQ��a'�]^Di� t�_wi������!}�O*�P�(���-�(w�M�[����P:�6J�ݿG&�'u_ǹ�;R2i���0H���D�-H�Hi�1��Ae��%�����:��x!�O�� �[ +�R#���>i�Wq�V�Vy58}8\{.�1����*-a���8mb,78�(]Ui煨h�@���O#����9}�C�B�q.���_!���)ü�v��`-�kXR�Eo�� �E�fىKa9 _�`GR�2�FV��Q�u%������"=@��w�z�lw[e+m@}zl��@^/"�E:"��n�� y�oC�I f���%��:pN_��A�A��/H���Xm�֏�bO�ď�z +�R`�.r_Ԃab�Չ�q���_ ��O�T� :��y��0�s���>\�6[�f���.�A>S�4Y'7��UZ���yB�� �p�:>�5)~o��5�7*c�ˇgˋX�FUZ��X�8�M�=Nغ�!,U��S߫*k���'�ŭ��������@�T� e[`OT�C�p�?�3N����K3�{�hKn�4��aS^A�����$�xɍm�6�y��?�6��g�C��M�'Ư�_)�7w����hR +b �!�M�U�|$<��5��^�6���G7�y���.��?ժ4en��&ʴ��'����@�l&���K=����]���PZ�j{�vP�� 8_K�b�n�1ȭ߁ܳ��nS3�8�Z�ZLf�(��8T�¼���)�A�}{���/aRj ����Q�o<�g��x.���y����u���S�ϛ������2tp���,���0e�vk� ���<Ӵ="�]�#w4���U��!k�ݎ�xz�~�~�U#��Z��U��0�1L��}�ZJ��ﯶ�eVmw�������߂;4YKR��}�m�=��O��&F�V�1?�S�/n� Q��!��g���4�ޛ4| +�|{��؆L$�p� ��c�d�їźo�ЉN�pUK���XG;�?��o�:N�����zA訿��<)#{��C�>��Tڡ�Q�! [[`Q��&2_2 �tm����L�O,꾎s�w�2d���Aa�dq��,[�J���Sc���89K&�/Qu���B����7V[ endstream endobj 1328 0 obj @@ -11405,24 +11376,23 @@ endobj 1327 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F33 531 0 R /F30 532 0 R /F89 511 0 R /F120 619 0 R >> +/Font << /F45 229 0 R /F33 531 0 R /F30 532 0 R /F89 511 0 R /F122 619 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 1337 0 obj << -/Length 2076 +/Length 2077 /Filter /FlateDecode >> stream -x��Y�o�8�����aX1|�qߜ�M��IZ��n�-�f�ْ�G�����(ʒl'�88H+Z$�3�'u2~�h��@]�D�� �$�J�/��D�BwG���,5��6ɰ+��{��,��6��'},�f��Iѥ��i� �a�]��K�4Q͠s�ǁ�����r�4��P���v�9�@M�nK��'�+��`u?�ϋ�O,��%)v}�˨��,�x�J�aܡ�D�!#"��u3�#�xN�͖�!_,80�s�i����㣓w`���@x�!`�����s��w�d��c�y~o��,Is5;�:��h0nC�,-��Щ���J�&A���c�t��-Ѩ)�J�r�I0 ,�O0��75��%�.f�1�.�\-�0��ؼ�(��*z�=�}���~\T�� -�%�v�b�s�{^`��J[I�b��c�u�犮�y��*��ŜK%�O�����=E� F�]�5��Jy�Y �G$f��A|rs;�p;��ף�����?���\}�������;Α���t���x:,�$�A�U����Dzv�ct ���@�C���O��^]�_�?m{�<X����/�և�]c��*��h���0�j^M�h�?̯�?}���7TK��Q�`�m�¬H-�i���j��Č�#C�l��w���~�)Q��^�x�̺��<��d_�$Z:�V'V���E���D���<k�s(�#�7vb�Q��!��Ȭ���Z�\l��ղ�4Y5y���\�J �.<|<�#�Ƿ�����d�&���]�����;�ј$¦%��pp�����v�o�l�ưo��u��Nb��c9�� -�����2�e��ߍ]�jS������#L�S*#.�-ߚ����O�V�|��*�o��1��_A��+Ǫ\�1Z.+߯H�/�q5+F���d��d4�e`� ���[�wbye\�]��UI���t��d�5+k�i���Ci��܇���O�BAn@zo�u���m��p���T���L�bg�2�>X��L�pi�kZ,��T��"�3����`�=�i�Ȼ.��{FS�����>ܠvl�����g��q�b��o�L�{��3��S�l�ƕM���!l �a�eV��!\����0�� -��/P��?�F^NÆC�\�(p$k4��.���3P7�tʽs���lg�5�6H�D�C;4�`j(��s��}������Y��*u����� .�2��6WwQPI&�,gu��e�D��B��_%�b5Uiی��?�hf�)j�j��뱲�.��lS=g������l[���2���;���M��Θd�4���Z'-����#��ׂ�u�ހc�?MN�9��.��B�4k�� ���{�*V����M�a}~�#W٦װ`���$�0���dZ�*(��F��Zx*��4$�- -s�q8<��h��-�����<�?&��u�Ct���f����w��7��K�������xL�U+��{H;����,ڏ�np���;��\/�Ro��N�W�]%s�?��&yL�V���?����Kc��I� ���}x��݇��*�+����t4q��횦�x�̊�!Ղ2�@�1 -�����9���i�t:�%�ӿ&�/��@�ˠo�ε9��i���D�= -���n�v��h�*�$�%�ѳ%�F����H_���%���=M�qDFh�<� K����cN=��̽�7t�g�{�QY8IД�@��S��fQ�s���Ƣj8CGNg��lv��r���ߵ����Nw����kш�cT�Vr��/��$��e�A���_s<[��i�>�S�J�A����k��TK���-�k�[k����!F�Z�11j�r*{q6�����JA�7����\��]���̈́�m���^__��wi�����帊B?�'],f��X��\����0�aHϣl�d������2�r{ۣ_�j�&�bV��{j�@�Z�$�4��=af� $Bi+�<*{id{"�)ꔠ�8�L�z���xۺڊ�y��4p���6���l��i����)X�*����*��a +x��Ymo�8��_Aఀ��J�}s7��&im�ݶ0d[qtgK�^���?���(K��l��p8 �h���3���x���EvD�tq?��7xC��%�)EJ0� ���}�Z|T��d��$î���N왛�(�����TX��V0��Ki�Ӓ�Ô��SK�4Q͠sLa_i�`�\0M�7��D�aN8PӴÒ�F����劣�X����b�˱rI�]%bu��P���T��@K�r0"�Y7�=���d�li��ł��sL}W�?���������1{J!�7x���s�4�f���To�Y�����������!��pO��S���J�&A���c�t��-Ѩ)�Jk��$��'���^쒁J3�v� Ό�q.� ��ؼ�(�yX +�R{��_�C����pK����Bq�{�o��*����JK��b�]s_�*��ŜK%�O�����}��=E� F�]�5��J���/�G$f�� >���OF����p�~�O�n�>���X�����þGJ:LpL<�J_� �*�X�a"=��1:{`z> �!�X��'�o�.�/ǟ����@,���A�o����1��0��h���0�Ἒ*V�<��_����.do.�gJG)�]C�UdEj)L���WW3~��l��='�Y�����D�BxƳЬK��3kH��H��S�����»�^֚��4�Z<������]��p�}q}62k����6�ۺs��.MVM^�a%A%@�>������`��y�Koq�.���h���hL�Aa��z8��~E�p;�b�V cX��|��S�X��X�@/�������dY�D�w�C�w���sts;<����ʈ�l˷��Cd�'[��|��*�o��1��_A��+Ǫ\�1Z.+߯H�_��5/��#ғ�|���@�700�����ʸv�x�o|�B���k�V�4��4����(s�����O�BAn@zo�u�0�u[��5���?z"��76����Y�>X��L�`i�kZ,��T��"�3���b0����4J�]K�=#���گj躰b��N��p{@{��lp=�_��� ��qo2�q�y���+[`qe��-G[�}XcYUh~�EX�XO�K���(p����Ӱ��(W J�M&�K�D��ԍű�r�<�Z��lg�5�6H�D����t05�J���>�������k�:Z�O�QƐ¾��6���û(�$�� ����Teٹ#���c��R��a�6����,��@b�ں��zZS +��d����u`��4�l[���2���;�Y8��9�1Ɋi6K��N�ZL+�_�G�e���3�����zs:]�1x��i� )�LW��hU�* G�7M����<�6��S�&!yP�\&� +�4�"+n4L��g擙���Ea.5��w��!۾%6]�50���G�d9���p����qz���`�Fpt �p0"� ��$�W��(���ӟ ɢ�(�w�{��b)��_��t!yU-�U27�S�x`B�'��lu�s��S?X�46= �����Ї���}�B����JG3'yٮi��ɬXAR-( ������Xʞcn^��M�S^r:�kBT�� :]}+p���j�����(8b�]ڭ$����Òԗ�/Dϖd�C�/�#}u +���R�4���C\���, ��s�9�>3����ўmh�9Ge�$ASz;�QNE�֛�E�� +���Ƣj8CGNg��lv��r���ߵ����Nw����kш�cT�Vr�����$���נ�J��9����Z��)p�o��i�T�C�ƚ�5�s�a������es���f�_�����^����`�/�RP�M�������)z��{3�mC����ח/�]-���e9������I�Yb'A:�%a�3���(['Y�,7����z�D���ѯ�p�&�bV�R�p�@�Z�$�4��=Af� $Bi+�<�����D6S�)!|(�\3]��2��m�j+��f�V��-tl�&�(w�e;�I&�o�T`)�/d�{��>��V endstream endobj 1336 0 obj @@ -11598,22 +11568,22 @@ endobj 1335 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F33 531 0 R /F30 532 0 R /F44 228 0 R /F120 619 0 R >> +/Font << /F45 229 0 R /F33 531 0 R /F30 532 0 R /F44 228 0 R /F122 619 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj 1359 0 obj << -/Length 1535 +/Length 1534 /Filter /FlateDecode >> stream -x��X�n�8}�W��^%jї�q�M����0����%ג�-Џߡ(Y��� �pBR$�r8��x:��h� �#���@�O�� �K�S��`�m4���f�1�`i`��$î�����5�(2��O*,|��UG�̤�"�++8�=L��<E��̀�c -�����P���~`N8��F���(>_�8:KA���Vc�ZN����U���5!�X -�{��w(+j�F$����=��C��S��{�� ��S�5�O���@Jʱ/<M���|��i��O�,\9�SÉN�t�������`4m(C�,�)l����E��0*C��Е2p�D���3*���@ ,@N�������@���G;JLF/�I�� ���~8�Ƒ.z,�� �@�'�!A2`�����q)���F4�)X9@�B������h<{{3���NZ���� �{�+$x6 ���#�wq���^��� �O ��_-�a�,!���[���J��r���y�̶"��I'k�.�����M� p+M[� [X�gW/�ܜ��~�]�������6�?@����j�/���b�C�:���E\m��d�lt5>\n#U� -O�� �� ��o_�&���Ƀ�$�Y��S[���l��r�1ὀz���Z,J��(��R:���#��Ol��~��_njp�q)�4M.&ӷ㖎0ʡƭ�\�PI�����Ҭ7i��ly`]��y�&Y$����r�̃��Y*�a�`S5Hf� ~��5ѥӃe�� G�Ds�x^���t8�]�Y���j6�{�&fU`�cϥM�������8����c���t��J�C7�Dt�U�\��J���wsm�]�Q��H&��d�I2��dװ�'7��Ӑl�����W͟M���m7�!$��k$���e����h|2} ��M�Ts},���O��M)�G�'b[�Wk ��ߒp0��vQ�/=��=i�we@�G<H'H��aV�f.�(6���.(�u����泹z����� � -���l{��s��S[�� �kS���8_���v$i��b|��gi�]�Pd9�@�鑔C��r�*�422�HƜ�+B�c�I9f2&�����5+|���F�MF%��d����G��J?k��mR��L���Q��K��`-#�w�Q������W�C�ϩgBs��왆��c���9r��t�(�-G��[Ղ�>W���l*�!8�^�3�i�2ëa����N�����o�/�j��cR�{����1���-G��f=\���n%ȑ8���S���M�rH������٭1�]�^�j�Sz�/A�QN��&L�(~�B�F�a�s�x����n_��m�Ó��~���Ʉ�z��AS�����`�A��BGq�N�`YL�����2��"x��6��h�>���k2@��"�ķ���ڊ`'��m�8]�=i������z! ��e����3.N�� XV7��<��-k���[��d�x�KQ^��ۚ����7� +x��X�n�8}�W���5�KҸi�&Mm�A[���ؒk����ϥ(YK�q�E8!)^��p�<���)�g�戠�4��|!H���"%��D���>, L{�dؕ~w�q5g=Ef���I��OQ��(��]�}e'��)w��(��P��}La_��\0��J�^�O� 4�ݨ��Ň�Gg)��_��f�3˩��J4̲�"�!K�|�U��e�%B-Ԉ��ֺ��Vq��zHc�w�6�T�c�f��tp�HI9����b>��B�o�=����i���#�yj8�I�nr}���� c���=�O�����:_#Ne�]qЁ�%�4m��Q�@�{L5��=�Vs��k|�g�.f�1��6\$��o�<N��|G�0�|:T�fQ0���̀!.�#ǥ�7���X`y��M +=gW7���������f:i�v��2�`���0�QX����H�ʼn,&{���$�?5������>x���ڮn�ƺ*�+�m����3ۊ�Z'Q����үY��^n��v L& �\4}�6|a�]\�xss6:�1gt�jo0J����8��{�^F��|��� יm�/�j�.��`�+�p��tT�*<��.�.��}1�Lf�'���&N�9�/�<k$�)V�l����Pk:�(�c��1X�v���G<(]�� �� V~��!�&���x4��Lߎ[6��CMX��֡�`%Tae�Yo�Pg�, +�����0M�<Hʸߥ� +�e��b�lo+p��)@3�n��_�P]=Xf��聞�]�k^@,g3�nWz��<������I�ٳ*0����&�T�^�\^�]L���u� ��I�yM���"������ys%ۻ�wsm�]�Q��H&��d�I2��dװ�'7��Ӑl������̟M���m7�!$���NFI˦�����d�@�<6�x���X@��Qm��`�R��xOĶ\��.�%�`��h�E���|�� ߕ� � m�s�Yy��L��x?,����º֛����s:�j +6<+f����?:�m#Om.�d�M]��|�Zۑ�yj���"���v��J��"�<r<F�x�#)�����U�iddN��9'W�(�8�r�dL>�w��u+b��F�MF%��d����G��J?k��mR@�L����S��K��`-#�8�u��p�q�������s�-���y �C{�1|���Gf8�����#���j�E�+�LU6��j�N���v��x%���tj�nww|~aL#��¶��$�>Ѝa���h)i���p��ϫ�� G�L��SO5dj6�2�H�����.�-�.TOb��=�����S�ũ ӣ�_��P��z�\6��)���W��p�qG��d���6�|a2�^�BϠ)� ����`�A��BGq�N�`Y�����2��b�(?m4?�6�}RC �d�*�"�ķ���ڊ�N6Bik���F��t�������N��$X���n�m�qqm����a�p��5�hY��n��:t%�/X���-����y7� endstream endobj 1358 0 obj @@ -11758,7 +11728,7 @@ endobj /D [1358 0 R /XYZ 29.788 174.312 null] >> endobj -1182 0 obj +1373 0 obj << /D [1358 0 R /XYZ 29.788 63.19 null] >> @@ -11766,95 +11736,102 @@ endobj 1357 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R /F158 1366 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R /F158 1366 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj -1375 0 obj +1376 0 obj << -/Length 1310 +/Length 1346 /Filter /FlateDecode >> stream -xڵW]s�6}�Wh�/0S}�r��¦� i��!��8�w���#����d�B�l�D�tut�ѱ�e��]S��{mA�=x@�o0B��%�)EJ0� ����>��x(Xj��e�aW��U�z��^�e��'>E�m�̤�"�jk8�=L��<E��L�j�c -�J;��i�?Q�N�~�aN8�i�V׀�0Ë-G�\=���a� -˩��J�²t��P��lT{�ʀ%B-��6�}�D��X�KZ�|~u���S������G%��������S -y�=������|�0p����0�ӬW���O�ɢ�(�S>p�4��W��0� ��'c����G1��c��Q���{L�4��?AVtjjv~,*]�<� b>�`c�H�p�E�&v༌֡ �zz���<�<��X(��b_{�]�b���ӁZ1�.����d9-&���|tv9x9�HA�����p���������( ���@4�_�$��\br}������W������]Z�ͪ���6��:ʃ�8\ۧܨ��!C� w���\^�!��P:�o�"�� -�9���\�Oaf�Ӵ���1�O0s���rC����M\d�;u�v��D-����f6�N��?����tt��WM���[�I})�ɮ,,�A\V�y��i�f�fS�Tl�7�n� /�m�T`� s��a�y��+��m������h:y�[@v4�9�Y��0K�����\U�&��s�c�}��{��ώ��?������P���o��G_�Y�t���,���Q���i��nX���˻�B�~�j���!H6����ST<�ee��E� --��8NW�Յ1(�wa������X�4�M'�"N+�:&�:�+B����j -3���:V+�h�=�#��Bp�$��iW��V�A!�T�<��n�s/aIghQ q���c�[#"F���a�MR����8��C��̵u)�X�N�+ L���P��2�[�D�� -N�n[FUw�zNg��,vZ��ym��3t������C��㘛ؚ�**��0Q���������-�9V��8��?"<ծ��j�l*���hn��F��Ml4M00c? j[9�^��`���2�����\�*zx�����vBk�eKE�vR�C�W���d�8O�M���dc�仅�Zp��Al���vq�p��k���!HX����� �ݕ�5An/�~�o��0�.~0:(:��*m��M�k*��.���V�ܧY�|]j�|��¬�^�6��M��I2a~�S�.��K���c�� +xڵX�n�8}�W�X1�JԾ9��M�ilc��Pl��B�\]�-Џ�!)ɒ��4m��mx8s8�s����h��"���@���C��%�)EJ0� ��=��G�P��0�i�aW�dz��5kQ���_O*,|�ֻ#0�������0�.�Œ2 �t`�)�+�T\����B ��<��p@�ح�=`:ίw�SP�_����3˩��J�̲t��P���U�ʀ%B-Ԉ���C��V)�E�pPRq��������pJʱ/<-��|�ߋ �0�H����<5��I�fE�>��x;�,Z�P!��{�N������ �EHe�Ɉ�8��Q��m0gT*����X���V[�7twu�*]�<zd�|rim�N�p�E�&�㪌6�1���\ � D�x4q�P9.ž�V�&0��=�rH����j>���LVw��du�n���-�-�=��P�D��P�[��6�C������b��� +�(�^��zP^;��: �<����2lV���t�UO�`��4)��L�ܶ����d�z�5��f��04���.n&���Al�q���g��l����>7�������Znn_��j�����~��ܤO�r�>���{�D3��F|5�.7��Rv�q��N��'j5���˻�t2[���V��t4{ţֿD����:ٗ���K�ye^�"��,�nk҂����]�e�� +L�a6Z7�q�����m�w���j6�N~�����m�~��"̒ ��"+ו�I�;��Xp��na����Q���߃hIj�^j&�٣����M@��"\w��y�}���s:��6E`�����P���t�~�m��r��iY $i�C���"��ui�����0������X�@�\L'�"N+�pL��f�(G�&f�k[�����H'���X�<��gIF[y��b�g�p�������A�$�È�����Ni�>'b���?�J`m=���z����6sG��i�w틾�����ep>����Ŋ+ؙ�l U�58G���d�5K��b��)A�<|<���M#�sc[�ꁜ�wc�(���JR������J��VV�g���o��7U2����Y�lvGF?y�Xkc`�~Ԗr*qsB�<�N�;o�e��M1����i�oc�l�����AHy,�^�B�CS@�����&J��$_-4��4b3��P��Ө0�GՕ��,��]wA��D�Wo+���v_����l J;��SW�w��� +��&�5��~G�}�{Ҭ��)�u<m�aV|�rC>���$�0�����U�^g +�ǿ� endstream endobj -1374 0 obj +1375 0 obj << /Type /Page -/Contents 1375 0 R -/Resources 1373 0 R +/Contents 1376 0 R +/Resources 1374 0 R /MediaBox [0 0 595.911 842.745] /Parent 1326 0 R >> endobj -1376 0 obj +1377 0 obj << -/D [1374 0 R /XYZ -13.423 915.745 null] +/D [1375 0 R /XYZ -13.423 915.745 null] >> endobj -1377 0 obj +1378 0 obj +<< +/D [1375 0 R /XYZ 29.788 737.428 null] +>> +endobj +1182 0 obj +<< +/D [1375 0 R /XYZ 229.882 684.487 null] +>> +endobj +1379 0 obj << -/D [1374 0 R /XYZ 29.788 737.428 null] +/D [1375 0 R /XYZ 29.788 663.877 null] >> endobj 630 0 obj << -/D [1374 0 R /XYZ 192.29 684.487 null] +/D [1375 0 R /XYZ 192.29 602.651 null] >> endobj -1378 0 obj +1380 0 obj << -/D [1374 0 R /XYZ 29.788 663.877 null] +/D [1375 0 R /XYZ 29.788 582.041 null] >> endobj 654 0 obj << -/D [1374 0 R /XYZ 228.66 602.651 null] +/D [1375 0 R /XYZ 228.66 520.815 null] >> endobj -1379 0 obj +1381 0 obj << -/D [1374 0 R /XYZ 29.788 582.041 null] +/D [1375 0 R /XYZ 29.788 500.205 null] >> endobj 678 0 obj << -/D [1374 0 R /XYZ 254.722 520.815 null] +/D [1375 0 R /XYZ 254.722 438.979 null] >> endobj -1380 0 obj +1382 0 obj << -/D [1374 0 R /XYZ 29.788 500.205 null] +/D [1375 0 R /XYZ 29.788 418.369 null] >> endobj -1381 0 obj +1383 0 obj << -/D [1374 0 R /XYZ 319.609 438.979 null] +/D [1375 0 R /XYZ 319.609 357.144 null] >> endobj -1382 0 obj +1384 0 obj << -/D [1374 0 R /XYZ 29.788 418.369 null] +/D [1375 0 R /XYZ 29.788 336.534 null] >> endobj -1373 0 obj +1374 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj -1385 0 obj +1387 0 obj << /Length 26 /Filter /FlateDecode @@ -11864,29 +11841,29 @@ x 0TH/�2PHW0Pp�I��p; endstream endobj -1384 0 obj +1386 0 obj << /Type /Page -/Contents 1385 0 R -/Resources 1383 0 R +/Contents 1387 0 R +/Resources 1385 0 R /MediaBox [0 0 595.911 842.745] /Parent 1326 0 R >> endobj -1386 0 obj +1388 0 obj << -/D [1384 0 R /XYZ -13.423 915.745 null] +/D [1386 0 R /XYZ -13.423 915.745 null] >> endobj -1383 0 obj +1385 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> /ProcSet [ /PDF ] >> endobj -1407 0 obj +1409 0 obj << -/Length 2057 +/Length 2058 /Filter /FlateDecode >> stream @@ -11897,22 +11874,23 @@ IjE �걝��z�l��$S�!�����gnf����M�ӭ�Lۮ�r4=�v?P���<�ʶ��tW�71�Q,}T"�2������8�o�*UM3�0�Nt�En � r?ĭ��T�����~X�}&̆8��ʴ�M�4*�PP�֬�7��4�<�����jׯ��~e�q~]��U��U�FA��4x�w?���c�z�6��@)�ƟԺɻ����p��s̳�>��kށ��m�dt�!뮜/��T�},���#�ӝB% �(��v��;g���<:6�C2��ս���S'��WK��c�v�4uPoaW���(�~��4����z�y��?��П-��[��ΗK�F���@�c��ﮪӾ��3Eaޮ��Q�<QVS��<5��,��\��Tm��{i.u��y��O�>9+M���~��\�8�X�={�-Y{��j@��^�\�����q|��I�h�=�$ ��S��x76+Й+��}���j�?Q�$/���S�ծ������t9�����Vx=1c���{E��"!� ���[T�E�sQ݉~x/��%6 -�aHgn�����n|�@��:<�`�*�?LO+{�zTi�*;�߽�����[���_Z�W�Zf��rwHu. #Yͫw��s��9��B���Ȧ3�-�>S�B߱CI���P>h��%��PK]��V$8����&��c�El�-LG�UwK�G����^�Qt�G�NA��{3�/o���&�^x �'�aפqH}� D�����ʦ3f�Qi��+XP�i�O(�X�0��02|�G��I�ix������e��D�K�o�{gZ{o�'��Ϻ�o��f�����a%3���7"3�)�k�.�.�v�)%����%�y³�#���B��� 6ZX{X�TJ���_Eؽ쵁:�1�,��������v9�mta�g��՛�!��`sO�/adm�K��C�Z�/�vT}�!���n�q���Tx��U�MWI�Tؗ:���U������P��-@W,T�~憐�/�o��pao"�=�����wϋ���B��!4t�h��+ܝw۔� �T�W��+��l� -ճ7����{�����&�G�� ��2~�ݙ $���ȶ'E��k��g!a1Ԛ�]��@#�`(�B���rX�E��_�F~�������̝̺dw���=�0���ҟNO�wɯP5���Z�6�I� �p�ԋ������ӂgՁ��@*��o,��/��h�0DG���78{$�L�6�20c�J2�rm��ۀ�#J���>���H���H����X|6�PSJ&��V�cP���6M�mO@_7U?�L��ԑ�?�,o6U��5B��f]��M�� -6���P�((v���P/��٣���Z�v�̓��x�;��������ڿ%�[�|kO�=z֡��%�¶�_'��g���p\>�Jas��wP >��"ݎ +�aHgn�����n|�@��:<�`�*�?LO+{�zTi�*;�߽�����[���_Z�W�Zf��rwHu. #Yͫw��s��9��B���Ȧ3�-�>S�B߱CI���P>h��%��PK]��V$8����&��c�El�-LG�UwK�G����^�Qt�G�NA��{3�/o���&�^x �'�aפqH}� D�����ʦ3f�Qi��+XP�i�O(�X�0��02|�G��I�ix������e��D�K�o�{gZ{o�'��Ϻ�o��f�����a%3���7"3�)�k�.�.�v�)%����%�y³�#���B��� 6ZX{X�TJ���_Eؽ쵁:�1�,��������v9�mta�g��՛�!��`sO�/adm�K��C�Z�/�vT}�!���n�q���Tx��U�MWI�Tؗ:���U������P��-@W,T�~憐�/�o��pao"�=�����wϋ���B��!4t�h��� +s�D�6%|�%�f� +"9��@�� � ��^��5��I��0���wf�{�s����H�{�a=�,$,�ZӼ���h� �B� :�Q+֣h����ȏ�3};�ݔ���Yw�쎰����[���)�.����z\k݆7I8�n�z�~�c�~Z��:p�H%����%pMƂ�h�g����䖉�fPf�_I�P��w0{D��3ç��Iߗ�I]�]��fcjJɄ��JpJ�ަ��BX� ����'�I��:>��!��ͦj��F��pެ�ܼ�١Z���Q������@��E7�1{4�\��N�yP�O'����u?C�w�duːo��G�: �dAZ����c��1Rb��GP)l�� +�ǿ����{ endstream endobj -1406 0 obj +1408 0 obj << /Type /Page -/Contents 1407 0 R -/Resources 1405 0 R +/Contents 1409 0 R +/Resources 1407 0 R /MediaBox [0 0 595.911 842.745] -/Parent 1411 0 R -/Annots [ 1387 0 R 1388 0 R 1389 0 R 1390 0 R 1391 0 R 1392 0 R 1393 0 R 1394 0 R 1395 0 R 1396 0 R 1397 0 R 1398 0 R 1399 0 R 1400 0 R 1401 0 R 1402 0 R 1403 0 R 1410 0 R 1404 0 R ] +/Parent 1413 0 R +/Annots [ 1389 0 R 1390 0 R 1391 0 R 1392 0 R 1393 0 R 1394 0 R 1395 0 R 1396 0 R 1397 0 R 1398 0 R 1399 0 R 1400 0 R 1401 0 R 1402 0 R 1403 0 R 1404 0 R 1405 0 R 1412 0 R 1406 0 R ] >> endobj -1387 0 obj +1389 0 obj << /Type /Annot /Subtype /Link @@ -11921,7 +11899,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_a300b00f9580b9af76d441cd4db8d7083) >> >> endobj -1388 0 obj +1390 0 obj << /Type /Annot /Subtype /Link @@ -11930,7 +11908,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_aa197109b334a2a443d9349812865bff1) >> >> endobj -1389 0 obj +1391 0 obj << /Type /Annot /Subtype /Link @@ -11939,7 +11917,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga91d06ad8cd57ceae529b66dd30ca4d8c) >> >> endobj -1390 0 obj +1392 0 obj << /Type /Annot /Subtype /Link @@ -11948,7 +11926,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_a500cfa825fa7c6ead38eba7bf7b4b955) >> >> endobj -1391 0 obj +1393 0 obj << /Type /Annot /Subtype /Link @@ -11957,7 +11935,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_afc3ab51b88f259e5cb76c10ee0732e5b) >> >> endobj -1392 0 obj +1394 0 obj << /Type /Annot /Subtype /Link @@ -11966,7 +11944,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_a4407b04a0d403a9fb35fd322999113a9) >> >> endobj -1393 0 obj +1395 0 obj << /Type /Annot /Subtype /Link @@ -11975,7 +11953,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_aecd99f57df2bc07663a7de83f877228e) >> >> endobj -1394 0 obj +1396 0 obj << /Type /Annot /Subtype /Link @@ -11984,7 +11962,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_aed0450820cd910e06e26fba04256bc24) >> >> endobj -1395 0 obj +1397 0 obj << /Type /Annot /Subtype /Link @@ -11993,7 +11971,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_a7984769929826a36f59e7b9dfd6e7447) >> >> endobj -1396 0 obj +1398 0 obj << /Type /Annot /Subtype /Link @@ -12002,7 +11980,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_aa4a1eeae4e7fe44a8093a3862996fbac) >> >> endobj -1397 0 obj +1399 0 obj << /Type /Annot /Subtype /Link @@ -12011,7 +11989,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_gac4726411862aa2d383e3d3b9ca279a5d) >> >> endobj -1398 0 obj +1400 0 obj << /Type /Annot /Subtype /Link @@ -12020,7 +11998,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_aa4a1eeae4e7fe44a8093a3862996fbac) >> >> endobj -1399 0 obj +1401 0 obj << /Type /Annot /Subtype /Link @@ -12029,7 +12007,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_aed0450820cd910e06e26fba04256bc24) >> >> endobj -1400 0 obj +1402 0 obj << /Type /Annot /Subtype /Link @@ -12038,7 +12016,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_a7984769929826a36f59e7b9dfd6e7447) >> >> endobj -1401 0 obj +1403 0 obj << /Type /Annot /Subtype /Link @@ -12047,7 +12025,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_aecd99f57df2bc07663a7de83f877228e) >> >> endobj -1402 0 obj +1404 0 obj << /Type /Annot /Subtype /Link @@ -12056,7 +12034,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_a4407b04a0d403a9fb35fd322999113a9) >> >> endobj -1403 0 obj +1405 0 obj << /Type /Annot /Subtype /Link @@ -12065,7 +12043,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_a500cfa825fa7c6ead38eba7bf7b4b955) >> >> endobj -1410 0 obj +1412 0 obj << /Type /Annot /Subtype /Link @@ -12074,7 +12052,7 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_a500cfa825fa7c6ead38eba7bf7b4b955) >> >> endobj -1404 0 obj +1406 0 obj << /Type /Annot /Subtype /Link @@ -12083,37 +12061,37 @@ endobj /A << /S /GoTo /D (structbsec__bme__settings__t_afc3ab51b88f259e5cb76c10ee0732e5b) >> >> endobj -1408 0 obj +1410 0 obj << -/D [1406 0 R /XYZ -13.423 915.745 null] +/D [1408 0 R /XYZ -13.423 915.745 null] >> endobj 153 0 obj << -/D [1406 0 R /XYZ 29.788 737.428 null] +/D [1408 0 R /XYZ 29.788 737.428 null] >> endobj 1116 0 obj << -/D [1406 0 R /XYZ 29.788 649.232 null] +/D [1408 0 R /XYZ 29.788 649.232 null] >> endobj 157 0 obj << -/D [1406 0 R /XYZ 29.788 649.232 null] +/D [1408 0 R /XYZ 29.788 649.232 null] >> endobj -1409 0 obj +1411 0 obj << -/D [1406 0 R /XYZ 29.788 603.186 null] +/D [1408 0 R /XYZ 29.788 603.186 null] >> endobj 161 0 obj << -/D [1406 0 R /XYZ 29.788 221.409 null] +/D [1408 0 R /XYZ 29.788 221.409 null] >> endobj -1405 0 obj +1407 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> /Font << /F45 229 0 R /F44 228 0 R /F89 511 0 R /F97 510 0 R /F33 531 0 R /F30 532 0 R >> @@ -12121,28 +12099,29 @@ endobj /ProcSet [ /PDF /Text ] >> endobj -1423 0 obj +1425 0 obj << /Length 1484 /Filter /FlateDecode >> stream xڵX�n�8}�W��F��i�[Ӧi�L���0d��5�$WK����\�Ʈ�L$!E��syH^f���@ж��h�\t;�D��-.��!!(��\�R����'������ �=N���\)3���!Aq6q�S��H���3�!? X�@�������r*��8U�����2��e���U �� �wC�p����i��崼�^��L�\����YV���%�8����}�W~�ko2������ɀ1LBO�_�f�7 J�p�}� ���z�t?�.�xw�P?�/e^e-�ϫ���Հ�B+�B�i���?�(���ȅ�R���fj8���-�0�D0��T�40?AV[t����"<L}2!��ye8��k�-�:-r�pۤ�Ԅ.�ӹ<� -A�g��!�c�:&0�����ߤr��^q�ɼ6n��`C`]�� K��$l���Q-�u-���M9��xC�������&�k�k��b��d��dr]ɺN�m��_�8>�Y�����Ӹo��ᡩn�O`�����+��Ҧ��'�?�'�W,��>0�:iʧA�5��_¿�3�gQe�j��IZ__eYE�a����o�s���8�YX�����v�ω7q��zG��%܁���};���ł�B���?O3+�Ɩ�����)hS���U�^�E^���Lx�7OC$L���*�s�Q*'�8�=>X��+��C�t�$��K�3z������*�d!�}��*.�MG�q��w��յ�Ƣ.L���;DU%���Ѓ;�����斝����� �"�몖��+\�%ǯLH3UU`��T���Һ���=�R�dʌ�^y�?����f�\�2:�!dm$P���c?U��� yA̼`(��l��6�~�V��Q�Mm�6V�BW2� ��N�2Q=�����Ci�;��<+ �t|�n��x�I�e��HR%�X_q�;��9loY~U���P���bV�U��WƵ�P�Ve���Tu1L�]��yQ��4?b�B�M���+ǧ���b�\�y��3��:/�r��QqU:����XQ�t�T��t�s�KQ*&�dXP2H�}��d���k��>�:a�T� �k!���[���KB��@��KI��eoF|���y^�� 3tr%Eur<"e?�Ja��Xŭ����X����͜I�31vVjx;��?6����S�1�NQs[Kͭ{��k!�Q���F�H�;��z^T����%���ჰW�c�h5uo�n�GcԻ��İ��@����p�c���9�J�_sD��FS���a -�|~�mޚ�mG2��*�Rme�ݩT��)�|r{/َmT&��U�Q��@'iu(�h� ¹�v��y�٦R�4q��%��e�D �y3�1������i�(�L���|�ʯ��f��R��U-Eٚ'�r ���-<�ڜ��I&5����L�c��/ܑ ��?���M +A�g��!�c�:&0�����ߤr��^q�ɼ6n��`C`]�� K��$l���Q-�u-���M9��xC(E`�y�T��5��5`Q1�T2^o2��d]���Z�/^��,��E���iܷ`����T7�'�JRV���WiS}�ǟĀ�+}h�m�4�Ӡ��L�/����ٳ�2K���$���������W�\�7�9�SS��,,gkgh��uK;� ���ā�8��[������@��?�>���u��b�x�WW̟��vUc����g���i��*}��"��b&<ƛ�!&D�RV��(��S�����ơ�a�u�ѥ�=�}��uj� ���>Hd��#��K�;Y��ZjcQ�������I�g���}ׇ�]s�N��zE�IK�uU�C��.���W&���� +0W�����Ki]��Uq�� �R2e�]������~u�\�M��6�LD�ȱ�*Agj��� f^0�oQ6�zU�v+@Ϩ�&�6{+e�+��ԆPyA������B�ƅΡ����]���i:>}�KF<�$���Y$��s��8�{���,�*]������_k1����+��|(E�2�E�V���?���h쀼��X��M��&���ŕ�SzZ] 1w�����d��N���nਸ��R��B��j:<8*�Q:�9�%����i2,($�>��]2|���oz��F*ф���������ԥ��z��KI��eoF|���y^�� 3tr%Eur<"e?�Ja��Xŭ����X����͜I�31vVjx;��?6����S�1�NQs[Kͭ{��k!�Q���F�H�;��z^T����%���ჰW�c�h5uo�n�GcԻ��İ��@����p�c���9�J�_sD��FS���a +�|~�mޚ�mG2��*�Rme�ݩT��)�|r{/َmT&��U�Q��@'iu(�h� ¹�v��y�٦R�4q��%��e�D �y3�1������i�(�L���|�ʯ��f��R��U-Eٚ'�r ���-<�ڜ��I&5����L�c��/ܑ ��?��H endstream endobj -1422 0 obj +1424 0 obj << /Type /Page -/Contents 1423 0 R -/Resources 1421 0 R +/Contents 1425 0 R +/Resources 1423 0 R /MediaBox [0 0 595.911 842.745] -/Parent 1411 0 R -/Annots [ 1420 0 R ] +/Parent 1413 0 R +/Annots [ 1422 0 R ] >> endobj -1420 0 obj +1422 0 obj << /Type /Annot /Subtype /Link @@ -12151,120 +12130,120 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga91d06ad8cd57ceae529b66dd30ca4d8c) >> >> endobj -1424 0 obj +1426 0 obj << -/D [1422 0 R /XYZ -13.423 915.745 null] +/D [1424 0 R /XYZ -13.423 915.745 null] >> endobj 165 0 obj << -/D [1422 0 R /XYZ 29.788 737.428 null] +/D [1424 0 R /XYZ 29.788 737.428 null] >> endobj -1413 0 obj +1415 0 obj << -/D [1422 0 R /XYZ 29.788 718.941 null] +/D [1424 0 R /XYZ 29.788 718.941 null] >> endobj -1425 0 obj +1427 0 obj << -/D [1422 0 R /XYZ 29.788 718.941 null] +/D [1424 0 R /XYZ 29.788 718.941 null] >> endobj -1414 0 obj +1416 0 obj << -/D [1422 0 R /XYZ 29.788 648.631 null] +/D [1424 0 R /XYZ 29.788 648.631 null] >> endobj -1426 0 obj +1428 0 obj << -/D [1422 0 R /XYZ 29.788 626.563 null] +/D [1424 0 R /XYZ 29.788 626.563 null] >> endobj -1418 0 obj +1420 0 obj << -/D [1422 0 R /XYZ 29.788 558.212 null] +/D [1424 0 R /XYZ 29.788 558.212 null] >> endobj -1427 0 obj +1429 0 obj << -/D [1422 0 R /XYZ 29.788 536.144 null] +/D [1424 0 R /XYZ 29.788 536.144 null] >> endobj 1117 0 obj << -/D [1422 0 R /XYZ 29.788 467.793 null] +/D [1424 0 R /XYZ 29.788 467.793 null] >> endobj -1428 0 obj +1430 0 obj << -/D [1422 0 R /XYZ 29.788 445.725 null] +/D [1424 0 R /XYZ 29.788 445.725 null] >> endobj -1416 0 obj +1418 0 obj << -/D [1422 0 R /XYZ 29.788 377.375 null] +/D [1424 0 R /XYZ 29.788 377.375 null] >> endobj -1429 0 obj +1431 0 obj << -/D [1422 0 R /XYZ 29.788 355.307 null] +/D [1424 0 R /XYZ 29.788 355.307 null] >> endobj -1412 0 obj +1414 0 obj << -/D [1422 0 R /XYZ 29.788 286.956 null] +/D [1424 0 R /XYZ 29.788 286.956 null] >> endobj -1430 0 obj +1432 0 obj << -/D [1422 0 R /XYZ 29.788 264.888 null] +/D [1424 0 R /XYZ 29.788 264.888 null] >> endobj -1415 0 obj +1417 0 obj << -/D [1422 0 R /XYZ 29.788 151.542 null] +/D [1424 0 R /XYZ 29.788 151.542 null] >> endobj -1431 0 obj +1433 0 obj << -/D [1422 0 R /XYZ 29.788 129.474 null] +/D [1424 0 R /XYZ 29.788 129.474 null] >> endobj -1417 0 obj +1419 0 obj << -/D [1422 0 R /XYZ 29.788 61.123 null] +/D [1424 0 R /XYZ 29.788 61.123 null] >> endobj -1421 0 obj +1423 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R /F32 514 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R /F32 514 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj -1443 0 obj +1445 0 obj << /Length 2050 /Filter /FlateDecode >> stream -x��YYo�8~���c��<u�m��� ����}p���E��PK����KG[m�N�&ţX�+���/P�k��!����Qh��A2�8�ł�HHT+t{���K���&3�&er�k��Ho�#c�P��1��ǔN�����<DQL��L�0�b�Ě9�!L��7*�I���0'�iڣ�!:`���}����̾,�)�/��8��H,�.BJ�q�(��x@h�PKzDr+��=!�xI�a��?_-80s�i���Wg�KpJ�q"��nKp�(J��W�Y�����y��xq�ʦ�[�=������j$�xx'��Xӿ�FP��#Je��,����G�ˀ9�2��<b\��j�NM}������� q��V�Oe�vu��Ui��<SF����K-p&� \H�<$�"�(ı&1����ɢU���Z��{U7��P��n���2�����t��,�!��`��m�n� ��M����^�ն@�Y�ϝb�9b��c�=�1q'��)����U䄒�gگ�o�H����Y<����I�z�|�S�z���ݫ��Ś�?�ǔ£��n�Mms[�[�����x�[w��;ը9��Ճ�ߒ��O`.�:�<?��cVwF<t��~�������[U�r;�9'R2�WΰL��>���2WE��ߦ7]��e�L<djѯ,�Nq<�e����n��w8MD$�6L���xA7�L�����ِ���H�YhN�Fp�i����dĜ� E��]\*Ӳ�U��Z5U� q�l����h8� %�fV☆?�範�*}���|W������R�uhRSå�����E�p�Jc��-;Զ���۪Aq�g��������Xg�e��J�����Dб����Цk�;g���p�6CuV�lK�*����w�7�Ų�)`ʵ�{�nm{�{l�m��y���h��^;<��������M���j�u~0|,��~�*�>IK���F� ��.�M�֏瑰�=9�=.�u�2K`Ls�n>�6YfÁ|t 7�=��=$��]a�`}��icg,�l��>m`.~1�b���a���G۵��w�����y�El��zy������w�#�QG��(�b�é2���)C����8KFP��#���V:}<�b�N��Y��6m���:V5���� ��t��|�j�B�k�*���j�HQT��Z�tV�� rÍ5]�6S@�ަ���m�)�z��x��2u�˽7)]VA>����O���_6�1x�N�h+}xBt�Z�yBF�a�X�m�:�����Qd���:�jU�ύ�z��q �J���q2{q1��R:�|�W�aꏪi�M�:^�N�Ǭ"�Mm����T�(;ꀚ�C�Ct; -{ޣ�����C�ڱ��:�G��]������"<^+�_Z4� t�AKt�&`0G�`�9l2�6�6��y�8`������h:���B�!�Ao�^�r�����Q_ �R>1�� C��dL3�_�~�P�p/��8����s����<p�D.�2�t�n�{��i���(���Cc�n�wi�S�/ͻ�����Ɔ�ߖ�w ���oT}qD�������?�1 F��������EHh��:c���̊#�S�I� ��Bp�$�z\j��� ��Kҗ�^i=_\T/aRj4����|���Fh�0`�Oy���s!3,��[tvb:y�v�����epg�z�_�>��v��u��,8� �6�]z�_���-��������h��qmd���p7�IlJ�ԭԿ��v�ަ��$@A΄y]�(��ork��M}e�7�d��z�Xiza`���h�*p�3�Jbj�T�g'eo��� �bq����Nh��,���T����Ng����;�rt���lf�i�hIgys���0����PT��7T+��3����Y�˅n�h!�F{���/�q�yP��6'J#꾯Vz�H67��=/�N3���=��}ti�Q~�y'�0�����@�Y-��I�. +x��YYo�8~���c��<u�m��� ����}p���E��PK����KG[m�N�&ţX�+���/P�k��!����Qh��A2�8�ł�HHT+t{���K���&3�&er�k��Ho�#c�P��1��ǔN�����<DQL��L�0�b�Ě9�!L��7*�I���0'�iڣ�!:`���}����̾,�)�/��8��H,�.BJ�q�(��x@h�PKzDr+��=!�xI�a��?_-80s�i���Wg�KpJ�q"��nKp�(J��W�Y�����y��xq�ʦ�[�=������j$�xx'��Xӿ�FP��#Je��,����G�ˀ9�2��<b\��j�NM}������� q��V�Oe�vu��Ui��<SF����K-p&� \H�<$�"�(ı&1����ɢU���Z��{U7��P��n���2�����t��,�!��`��m�n� ��M����^�ն@�Y�ϝb�9b��c�=�1q'��)����U䄒�gگ�o�H����Y<����I�z�|�S�z���ݫ��Ś�?�ǔ£��n�Mms[�[�����x�[w��;ը9��Ճ�ߒ��O`.�:�<?��cVwF<t��~�������[U�r;�9'R2�WΰL��>���2WE��ߦ7]��e�L<djѯ,�Nq<�e����n��w8MD$�6L���xA7�L�����ِ���H�YhN�Fp�i����dĜ� E��]\*Ӳ�U��Z5U� q�l����h8� %�fV☆?�範�*}���|W������R�uhRSå�����E�p�Jc��-;Զ���۪Aq�g��������Xg�e��J�����Dб����Цk�;g���p�6CuV�lK�*����w�7�Ų�)`ʵ�{�nm{�{l�m��y���h��^;<��������M���j�u~0|,��~�*�>IK���F� ��.�M�֏瑰�=9�=.�u�2K`Ls�n>�6YfÁ|t 7�=��=$��]a�`}��icg,�l��>m`.~1�b���a���G۵��w�����y�El��zy������w�#�QG��(�b�é2���)C����8KFP��#���V:}<�b�N��Y��6m���:V5���� ��t��|�j�B�k�*���j�HQT��Z�tV�� rÍ5]�6S@�ަ���m�)�z��x��2u�˽7)]VA>����O���_6�1x�N�h+}xBt�Z�yBF�a�X�m�:�����Qd���:�jU�ύ�z��q �J���q2{q1��R:�|�W�aꏪi�M�:^�N�Ǭ"�Mm����T�(;ꀚ�C�Ct; +{ޣ�����C�ڱ��:�G��]������"<^+�_Z4� t�AKt�&`0G�`�9l2�6�6��y�8`������h:���B�!�Ao�^�r�����Q_ �R>1�� C��dL3�_�~�P�p/��8����s����<p�D.�2�t�n�{��i���(���Cc�n�wi�S�/ͻ�����Ɔ�ߖ�w ���oT}qD�������?�1 F��������EHh��:c���̊#�Y���}/GL�M�ǥ6 ��Pj��$}����ŵA�&��As����\La����?�I ���s�i� ̰�o�ىm��9��S��?@���!X��Q��,���"�ݢ��h68��v��~Y??�0�O�Ӣ/ǵ��/|C�K��&�)S�R����=z�V���9�uA�x\n�ɭqK�7����ؓ5��=b�酁�S����K08�+��S]����9���7|���~�O;�}[g�T,~�OP=V�;����B�l�m0�M��:��|��%��͡j��lH�CQ�w�P� � ��C�kf�.�@��D��Il������A��sڜ(����Z��"=��|x��O���:̀G�����ѥ�F9���d��ާRx��f���H��! endstream endobj -1442 0 obj +1444 0 obj << /Type /Page -/Contents 1443 0 R -/Resources 1441 0 R +/Contents 1445 0 R +/Resources 1443 0 R /MediaBox [0 0 595.911 842.745] -/Parent 1411 0 R -/Annots [ 1432 0 R 1433 0 R 1434 0 R 1435 0 R 1436 0 R 1437 0 R 1438 0 R 1439 0 R 1440 0 R ] +/Parent 1413 0 R +/Annots [ 1434 0 R 1435 0 R 1436 0 R 1437 0 R 1438 0 R 1439 0 R 1440 0 R 1441 0 R 1442 0 R ] >> endobj -1432 0 obj +1434 0 obj << /Type /Annot /Subtype /Link @@ -12273,7 +12252,7 @@ endobj /A << /S /GoTo /D (structbsec__input__t_a90d515d57b274dfde74a281de469a3ad) >> >> endobj -1433 0 obj +1435 0 obj << /Type /Annot /Subtype /Link @@ -12282,7 +12261,7 @@ endobj /A << /S /GoTo /D (structbsec__input__t_a000803d39a2be521f2b5e7017c31303b) >> >> endobj -1434 0 obj +1436 0 obj << /Type /Annot /Subtype /Link @@ -12291,7 +12270,7 @@ endobj /A << /S /GoTo /D (structbsec__input__t_ab535651a26b2e2c44c83e441385e3def) >> >> endobj -1435 0 obj +1437 0 obj << /Type /Annot /Subtype /Link @@ -12300,7 +12279,7 @@ endobj /A << /S /GoTo /D (structbsec__input__t_a916867811b65988853b69f729b91c262) >> >> endobj -1436 0 obj +1438 0 obj << /Type /Annot /Subtype /Link @@ -12309,7 +12288,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga91d06ad8cd57ceae529b66dd30ca4d8c) >> >> endobj -1437 0 obj +1439 0 obj << /Type /Annot /Subtype /Link @@ -12318,7 +12297,7 @@ endobj /A << /S /GoTo /D (structbsec__input__t_a916867811b65988853b69f729b91c262) >> >> endobj -1438 0 obj +1440 0 obj << /Type /Annot /Subtype /Link @@ -12327,7 +12306,7 @@ endobj /A << /S /GoTo /D (structbsec__input__t_a916867811b65988853b69f729b91c262) >> >> endobj -1439 0 obj +1441 0 obj << /Type /Annot /Subtype /Link @@ -12336,7 +12315,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga5e4d504611e1c4a0219861bbcf2ad650) >> >> endobj -1440 0 obj +1442 0 obj << /Type /Annot /Subtype /Link @@ -12345,70 +12324,70 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga5e4d504611e1c4a0219861bbcf2ad650) >> >> endobj -1444 0 obj +1446 0 obj << -/D [1442 0 R /XYZ -13.423 915.745 null] +/D [1444 0 R /XYZ -13.423 915.745 null] >> endobj -1445 0 obj +1447 0 obj << -/D [1442 0 R /XYZ 29.788 737.428 null] +/D [1444 0 R /XYZ 29.788 737.428 null] >> endobj -1419 0 obj +1421 0 obj << -/D [1442 0 R /XYZ 29.788 680.603 null] +/D [1444 0 R /XYZ 29.788 680.603 null] >> endobj -1446 0 obj +1448 0 obj << -/D [1442 0 R /XYZ 29.788 660.7 null] +/D [1444 0 R /XYZ 29.788 660.7 null] >> endobj 999 0 obj << -/D [1442 0 R /XYZ 29.788 595.455 null] +/D [1444 0 R /XYZ 29.788 595.455 null] >> endobj 169 0 obj << -/D [1442 0 R /XYZ 29.788 574.126 null] +/D [1444 0 R /XYZ 29.788 574.126 null] >> endobj -1447 0 obj +1449 0 obj << -/D [1442 0 R /XYZ 29.788 534.354 null] +/D [1444 0 R /XYZ 29.788 534.354 null] >> endobj 173 0 obj << -/D [1442 0 R /XYZ 29.788 354.675 null] +/D [1444 0 R /XYZ 29.788 354.675 null] >> endobj 177 0 obj << -/D [1442 0 R /XYZ 29.788 169.39 null] +/D [1444 0 R /XYZ 29.788 169.39 null] >> endobj 1026 0 obj << -/D [1442 0 R /XYZ 29.788 143.316 null] +/D [1444 0 R /XYZ 29.788 143.316 null] >> endobj -1448 0 obj +1450 0 obj << -/D [1442 0 R /XYZ 29.788 143.316 null] +/D [1444 0 R /XYZ 29.788 143.316 null] >> endobj -1441 0 obj +1443 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R /F89 511 0 R /F97 510 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R /F89 511 0 R /F97 510 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj -1463 0 obj +1465 0 obj << /Length 1721 /Filter /FlateDecode @@ -12417,24 +12396,23 @@ stream x��YYo�8~���T4Oyk�M���&�!-Ebl�ڒ�#����;<d��MR�Q�-)r8��ᐝ/��hY�Z"��f��(�_`� KS�"�p($���}|@<.Xj6�e��@��U�n�~/��2�o(#,b���D�̤�r:�v�1� #�%e��Ї9�8��A'�`��o�@�~�aN8pӼ]ôW���m8zS����}\�Cj��^�� ���a(�RDq��V��>e`%B-;�ɭ�}����1]�%�M>>Yq2��8��O��)��r�0D��bF c��E�.���NWG>#�BuY5*=��x?{�(C�4�li��� �`�="`T���F�����P����I� '�j�M���Ӂ����N��x����]Ѩe�4yY�6ϔQ�xz����]ݜ99����XD� -i�Pʊ����T��Imk���{�n�� ,��Z�W��}�����6��j��?B�ǖ��L�9��^�/�d=b6?�� �A 4@ `�ʬ�Y�Ik����Ŷm������j�����\��X�N6۵�^�۬�@[��e�x�2�ySV�J�[�6���vV�3<��ȻF0�cH��_?���||!N�'��͋&���S'l�7x���B���H�R��_M[u���+��U�v��w�u�hJ�R�J'��� +i�Pʊ����T��Imk���{�n�� ,��Z�W��}�����6��j��?B�ǖ��L�9��^�/�d=b6?��!�A 4@ `�ʬ�Y�Ik����Ŷm������j�����\��X�N6۵�^�۬�@[��e�x�2�ySV�J�[�6���vV�3<��ȻF0�cH��_?���||!N�'��͋&���S'l�7x���B���H�R��_M[u���+��U�v��w�u�hJ�R�J'��� �I-'���n��O0X,�M6�� ���x4��=X��3KGQ$E {�E�C{�n�txYԟ��(&�&ۃ�0ɥ�1�x3��li<x��nl��;�Uy�6�_��+�¯�VAV.�n�p4y�V*�w�ɺU5>���+uo�Ӥ��Ur�����+�%��3��'T}_7j�W�^O}rAA��* -V4�����0w�:?]��j;�h+������§qH��96���8&P$�0�"٠�l'w�7U�����Q�*R��ġs��6����o���{��uV�Or�:�秐�&I���O, <�"d4]c���.����r�=Q�p{��X`v��p��0D��_��K}�0�GMژD�w��><$�Z��G/r����3���x�3�?R;<C�Q��#MA���g��ٞ=Tz����R�C�g/$��w�*�\G�r&/ol{�WM��K��.-~\�'i�VIz�R����t�K�:��O�'x�и1��3~~�ݎu�@��8[�0r��23�H� �A��As�}� s������ߕ�i�Cݦ��X*ݗ�]ެ��e�C�cx|�ߔi��#h7ת:>�CF���ő����m�z�����/�D�����}���:b?�FO'p��#&�zG�'����I�%�=�<ч�SI�� ��)��wE��b�a��$�Y�"<�����cNCDc���f����h@���;����2�R��ݺ/�#�g�v@�)���Y������n~���NOٯ�j�����{Ƅ�<��Id������t��g��N��T��IF���M�Ƒ4�� w���7�~��N��� �|���Qb��G�����s9xĄO�m���p��Tx��1�Ǫ|���F�wY蕾{��7�L���P�gR�[�Y^o�:Y����ܮ˼1�� ���*3��uC���\߂�h����Ij�l�$"���͝�ʓ�J0)Pխ�s�7�n��.ߎʠ��Z-@w��[U5��ӛ�萔L����K -��%-|�g��b +V4�����0w�:?]��j;�h+������§qH��96���8&P$�0�"٠�l'w�7U�����Q�*R��ġs��6����o���{��uV�Or�:�秐�&I���O, <�"d4]c���.����r�=Q�p{��X`v��p��0D��_��K}�0�GMژD�w��><$�Z��G/r����3���x�3�?R;<C�Q��#MA���g��ٞ=Tz����R�C�g/$��w�*�\G�r&/ol{�WM��K��.-~\�'i�VIz�R����t�K�:��O�'x�и1��3~~�ݎu�@��8[�0r��23�H� �A��As�}� s������ߕ�i�Cݦ��X*ݗ�]ެ��e�C�cx|�ߔi��#h7ת:>�CF���ő����m�z�����/�D�����}���:"����� �&���I����Édt�pbIv'O�a�T�;@�$xJ?C��]Q��tXe��>/���i�9�4D4�,�Oqhv`:��d�Cz9��)�(%Xۭ��8�x�kD����?��'���*Mޑ����=���t���J�F:=.�n�gL(�c>�D�A�:J�w�O7�yV���)H%L��a4|<���h�A��p���~��7��씁�+А�wx�{��%6/T���19��GL�����g;�� �JI��Z�z�ʗ+}m4}��^黧{�qˤ�� U&Že�������Y{������<�\z�2��X7y*��-����ʯ������N"B�(�ܩ�<��Uݚ<7<p��v�����ʋ��t�1H�UU�k<���IɄ��8��p9^����_�j�U endstream endobj -1462 0 obj +1464 0 obj << /Type /Page -/Contents 1463 0 R -/Resources 1461 0 R +/Contents 1465 0 R +/Resources 1463 0 R /MediaBox [0 0 595.911 842.745] -/Parent 1411 0 R -/Annots [ 1450 0 R 1451 0 R 1452 0 R 1453 0 R 1454 0 R 1455 0 R 1456 0 R 1457 0 R ] +/Parent 1413 0 R +/Annots [ 1452 0 R 1453 0 R 1454 0 R 1455 0 R 1456 0 R 1457 0 R 1458 0 R 1459 0 R ] >> endobj -1450 0 obj +1452 0 obj << /Type /Annot /Subtype /Link @@ -12443,7 +12421,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga5e4d504611e1c4a0219861bbcf2ad650) >> >> endobj -1451 0 obj +1453 0 obj << /Type /Annot /Subtype /Link @@ -12452,7 +12430,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga5e4d504611e1c4a0219861bbcf2ad650) >> >> endobj -1452 0 obj +1454 0 obj << /Type /Annot /Subtype /Link @@ -12461,7 +12439,7 @@ endobj /A << /S /GoTo /D (structbsec__output__t_a74a917725569b67eb14e78a34fa9c55d) >> >> endobj -1453 0 obj +1455 0 obj << /Type /Annot /Subtype /Link @@ -12470,7 +12448,7 @@ endobj /A << /S /GoTo /D (structbsec__output__t_a1a046572bcb85189df10c9ac8f362999) >> >> endobj -1454 0 obj +1456 0 obj << /Type /Annot /Subtype /Link @@ -12479,7 +12457,7 @@ endobj /A << /S /GoTo /D (structbsec__output__t_ab188da3e58d458f4b94a64379404da46) >> >> endobj -1455 0 obj +1457 0 obj << /Type /Annot /Subtype /Link @@ -12488,7 +12466,7 @@ endobj /A << /S /GoTo /D (structbsec__output__t_a91006cd8f20e88a5ff2b6ebfbecdeb95) >> >> endobj -1456 0 obj +1458 0 obj << /Type /Annot /Subtype /Link @@ -12497,7 +12475,7 @@ endobj /A << /S /GoTo /D (structbsec__output__t_ab188da3e58d458f4b94a64379404da46) >> >> endobj -1457 0 obj +1459 0 obj << /Type /Annot /Subtype /Link @@ -12506,67 +12484,67 @@ endobj /A << /S /GoTo /D (structbsec__output__t_ac4e7ef20f713075472bc953efb13957f) >> >> endobj -1464 0 obj +1466 0 obj << -/D [1462 0 R /XYZ -13.423 915.745 null] +/D [1464 0 R /XYZ -13.423 915.745 null] >> endobj 1028 0 obj << -/D [1462 0 R /XYZ 29.788 702.891 null] +/D [1464 0 R /XYZ 29.788 702.891 null] >> endobj -1465 0 obj +1467 0 obj << -/D [1462 0 R /XYZ 29.788 679.17 null] +/D [1464 0 R /XYZ 29.788 679.17 null] >> endobj -1449 0 obj +1451 0 obj << -/D [1462 0 R /XYZ 29.788 562.197 null] +/D [1464 0 R /XYZ 29.788 562.197 null] >> endobj -1466 0 obj +1468 0 obj << -/D [1462 0 R /XYZ 29.788 538.476 null] +/D [1464 0 R /XYZ 29.788 538.476 null] >> endobj 1029 0 obj << -/D [1462 0 R /XYZ 29.788 467.755 null] +/D [1464 0 R /XYZ 29.788 467.755 null] >> endobj -1467 0 obj +1469 0 obj << -/D [1462 0 R /XYZ 29.788 444.035 null] +/D [1464 0 R /XYZ 29.788 444.035 null] >> endobj 1000 0 obj << -/D [1462 0 R /XYZ 345.082 341.456 null] +/D [1464 0 R /XYZ 345.082 341.456 null] >> endobj 181 0 obj << -/D [1462 0 R /XYZ 29.788 314.241 null] +/D [1464 0 R /XYZ 29.788 314.241 null] >> endobj -1468 0 obj +1470 0 obj << -/D [1462 0 R /XYZ 29.788 270.565 null] +/D [1464 0 R /XYZ 29.788 270.565 null] >> endobj -1461 0 obj +1463 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R /F89 511 0 R /F97 510 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R /F89 511 0 R /F97 510 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj -1475 0 obj +1477 0 obj << -/Length 3305 +/Length 3304 /Filter /FlateDecode >> stream @@ -12574,37 +12552,30 @@ x $ �"NQȅW$���/��� �L�3AQ d��+�sϋx�3�("�%����� ާ4�t�8a�F BQ%�u4B2R��K0N��7H���0j�v�U�+���o��&Q��}\�!�|�� (�xK-c.��'����j/�O(X Cް`F��뀮�1]�����2Zq2b��_�]\�P�$C��ޣ�Q�������}�*/�K����6ٖyQ%��?��k)C��# 6������*��0�z��F5��y�m�DDЖ�T�49V+o���c: ���7���U�*�*ͷ��]�.��X<=�ɸG�BP% $@<b�0dlq�Dfo�*N�di�z���"�i9��u��F9�>�f��mUԋ�.Ce����������y]��ʼ��f�����yVk[���".�]�|��쑔<A�ܻۀ87��ND�#���iiʊ��j�����7����Ϳ��]��3�@��Y�%ɒM��<�&P[��.��(�o�V���Q}�%��g����E��V�x�<�00����t��3S� \M�-M��`��bk -ܨm �*�n��Pm`���8�g �/�2(��X�,>���\�|Y��9]v Rk���yY���Jn�p4[�4�}˒�U ���5 �U��Y���{�� ?��hQ�+-ꗴ��8�l����0��W��jx�;̐D�Q�X��|������,�B���2�$GN͈Q��I�������rH��V�+>pI]⇮���:g/u/��@(��n����N�U����>����@�a�t�Pn-v�J�M�gC�.�s���iI�6��.�3��#�3�����5���m��lڦ[Sd}o�F��� -529Lc���v����".����6I���6� �lj��(� ��ҿϳ,(_��j�c�z�����������»��'���\HD�)�8@��.A����D�@/�EOS`D�B/�6�Hg�S��aΗ��ߏ�&9CE &�N~EO`�S����������(�K!f�ZP�PI �SCd`���H>] -�DB�Ѣ������q&u�����"�)�Y�LG�ŀ�$�%�ʇ��"�G���Ǜ�_���f�S�V��Q�e�O�i -��������4q������H�4��E/0.[�m����s[��u�\�(�8�F�t�% �b���V�p����c�QP����~�|�����_�{LS0�*�������`��q�`�<�W kzq�r��.��тH0%��=�I�8^����݇�7����L��q?-��b&`����r�L�͓0���,[lb;m�WZ��>/6�v����Xua�i -��� -�4nC�D��w��}�8���ޠ�͞ �h -� �:*��uE��?Z���W%g����c5�D�֞oݨK�ꕪ��t�9+�Wo#�O� �̆!�h%�]�Q��M����f�K�&���_��;�i�I�~qk$v�M9�u�]%��I7�9 �Z��m]%���u�2Cx2�,��O��hHE��I ���6A]N�{zZ^a*̣MnE��na?Ys�H9�V�������Q`�!,��5�2�H ,��E����a��$���(ɘ�܊���⟨Fr���zo�@�B�JH�C�����(��0节��5O�:� -2��W�wn��~%E�b1� -��&�č�Բ~ǵ��VE�@a -���bn�'Pߣ�om�q��hm�0* -8<�a�N�"CB4 Ia�C�Ј")�`��@h�5m�wn����5��'�z7�gIY���m�q�,dZD d��d��Y1!$��L�IrbFR8�u���z:�<6�����L��� -6d��[2@ $gBF�K`gAf$�S��g���2�t�i��[!C��̳{�AF�J4�!��f�N"Qa��4BQw -�"�[tT�����K���1a���tW*}V�i���m^�����*Ua]&�)zX'[SV��+W��I �J!�\ͣ�(�Z�|�D�>��u�::�ɞ�X�!�[�vM�M��*��Q`���`��(�x��U��[�Mzo6 �����%_wy�T�=z�%��j�e�eu�ȓZ:�� ��;����L��⤫-��TmnU;ʓx��� L��̹4��'0_��+��AUq$������c�{µ�N)9,�Z�N�)P&j '�|:8� ��K�(P -F� ��']M�����@��y���J��+ЈIi/)_?� ��3�8�q�'�4O�2��y[��4K���f�2�����hf��34�x+�!���pPKV�#�<�x������hG��q���α]�N��u\��j����F���&f/̬+fEbϭ���쭴Z~�3������\&�����=h��в�-�U�/-��6R$�B�&�F ��åu���fPSR���n�9^6��a�3.f���)~H����X��9�Z�Z� �7� �"�lN�3`�F� �y�A�ݯg�z��0��)G�9���ҁ S�t�i�<������۫O�wϷ��` ���Y�1$;��G�8��Q��É���IX�n�|҆���3,g�(0q^�����gܜI�u:�>R���}�����H����?��!WK5�.tHR��6�� g��+���t�F�]S�e=�O��:�j�QO����=}^�*3W3����Nz��f��B�ncܩH���&��ߺL��{4���G�B�:vM)�|�����\B��9��+��߿��J�{D#;���BmѩUG�_��&��_ ��(&�����d���PL ����/�]|� �и`)�9�Q -�#e7����E�3��jd_ޅ߫�{���Ts�?�����W���_+հ��V����7(n�H�FĶT���<�6��8p1I�!�l�D���6�tv���ҷgb�i����ڭ|��#�H}���J�;}�[w��'���̿3 -�# -�g�z� -�W�Ҿ[/��\H�7[l�*.�:|P?��7Cz��"Ǚ�@��9�Ss��ɮȗ��)�Xt���^����d^���K�l�:r@:��!��"K\lI�4����[�nW5����e�pk7 �.)*�V`��N�i���rwE��'���X��� +ܨm �*�n��Pm`���8�g �/�2(��X�,>���\�|Y��9]v Rk���yY���Jn�p4[�4�}˒�U ���5 �U��Y���{�� ?��hQ�+-ꗴ��8�l����0��W��jx�;̐D�Q�X��|������,�B���2�$GN͈Q��I�������rH��V�+>pI]⇮���:g/u/��@(��n����N�U����>����@�a�t�Pn-v�J�M�gC�.�s���iI�6��.�3��#�3�����5���m��lڦ[Sd}o�F��� +529Lc���v����".����6I���6� �lj��(� ��ҿϳ,(_��j�c�z��������������N�����@.$"� h LC��Ќ�Pt�i�p֢��)�"G�Q�x�3 +�)��0������x���"�L'��'��)��q���[@Zv�ץ3 �-(D�$�ө�2�xW FB$��G"! +�h���^���8���Gkuq��,�s�#��b�P�h�C`�������_�p3�)x+P�(�2�'�4SJC�x�ejr����m�`g�z[$YC�����6uic鹭]�:p�l�vJ�u:��P��YX�D8zT��DZ�(�d��O�}�~��ׯ�=�)�k�wrKS�l���8�Q��+�5�8�K��kU��h�$��ď���$z/�L����͛��~xd&`߸�z1�l��V9Y���I�q�h�-6���ҍ�+-�vIq��x�HN�h�:�0 +�4�Gan �t��!A�vE���{ESpoP�fφa4�F��պ����-�A�+ +�������1��d�gϷn�%_�J��^����ʫ���'�QfÐO4���.�(��&���S��B�d�?�/�ŝ�օ4ˤH��5�Φ�:ޮ�f���v-�uF鶮t�ֺj�!<�� @�'�t�D4����b���ap�a��.'E�==-aB��0��&�"``�������sD��P+EQ}�Skt�(0����LI$Sv��H�A��Hi��Dbq��dL�nER���O�#9�Tr�7rN c!K%$�!}� bv +I�XtE��Z]�����;�οL?aʒ"Q��^�Nj��ZjY��Z[���"�t�0��Z��@1�����ͷ����a4�6�� �0B�S�!!��0�!uhD��t0wl 4G��6�;7��PӚj�s��ݳ�,���6��sT2-�2�~2��,���Wy&b�$91#)��:A�s=L�L��A���o��2��- �3!��%�� 3��)��3`Éb� X:ȴY����S@�ٽ� #g%�� �t3L' +�(��rd� ��;F�-:*�y�˥�o嘌0��e��+�>�ʇ4���6��{�Hg���.��=���)+�ɕ�w뤆rZ�Y���YS�vE��h�K�t��_����dOW��٭]��掦�u�o�(0���f��I�y������&�7 ���^s�͒���t\��=ɒ�R� 5�2ϲ�j�I-�{C�����k +B&�� q�ՖH�B*������I�Xg��v��Y�\���/���q�}��*�8��N� ��Dб�=�ځO����F'�(����{>�Մ��E٥h(#�������&�H��kv ���<�sӿg%��hā��������LՙV���H��� +N���y���km�\�GQo�}4����a<���\Y�L8�%���]�<�A��zw4��djqT�خ{�`�:��t��i�j#��w�f��"��V�lm�VZ-?a��G^�`r.Skfo��fwhY���*ϗ�bj)� Z�S�u�U��ҺZ�n��)��A_��/�j��0��y��?����z����\-C����v�U�n6��0t�H��� ��׳v��XKᔣ�lrb����)X:ԴY�w~i���է�����v0�\���������I���(B\��D�v�$,m�Y>iC�������8/��GH�3n�$���n)�x��YWWB$C�݊ޟ�����L:$)U^��������R:{�Ϯ�겞�'Qw�5騧���О>�m���J���Pt'�m�z3O +p!U�1�T���pD�o]���=��G�#_�M���y>P�xxtt�K}8g`�������T)cs�hd'�_�-:���ky����A�����8�)�'��d��b���wh�}1�b�3o�υƽ�K����R�)��_E,��q�V#���.�^����o}���fM�����~���}��Z����Z��V�A p�Gz6"����~_l��Y���HŁc��I��d��&M͵���;mԕ�=�M�Ԙ���n�[��{�E�pD�V���gغ�?���f���P؆Q>���xPV��R���z��B���b+Vq����o��˴�9��R�Y���$��HvE��MĢ�T��� ��&��M\gCԑ��6IfY�r�`K�Y�vW�bu��7�.k%�[�iwIQٵct�N��\_υ�C��(�u>|��L�� endstream endobj -1474 0 obj +1476 0 obj << /Type /Page -/Contents 1475 0 R -/Resources 1473 0 R +/Contents 1477 0 R +/Resources 1475 0 R /MediaBox [0 0 595.911 842.745] -/Parent 1411 0 R -/Annots [ 1458 0 R 1459 0 R 1460 0 R 1472 0 R ] +/Parent 1413 0 R +/Annots [ 1460 0 R 1461 0 R 1462 0 R 1474 0 R ] >> endobj -1458 0 obj +1460 0 obj << /Type /Annot /Subtype /Link @@ -12613,7 +12584,7 @@ endobj /A << /S /GoTo /D (structbsec__output__t_ab188da3e58d458f4b94a64379404da46) >> >> endobj -1459 0 obj +1461 0 obj << /Type /Annot /Subtype /Link @@ -12622,7 +12593,7 @@ endobj /A << /S /GoTo /D (structbsec__output__t_ab188da3e58d458f4b94a64379404da46) >> >> endobj -1460 0 obj +1462 0 obj << /Type /Annot /Subtype /Link @@ -12631,7 +12602,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga832388c889417ed197609d9965625bfe) >> >> endobj -1472 0 obj +1474 0 obj << /Type /Annot /Subtype /Link @@ -12640,82 +12611,83 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga832388c889417ed197609d9965625bfe) >> >> endobj -1476 0 obj +1478 0 obj << -/D [1474 0 R /XYZ -13.423 915.745 null] +/D [1476 0 R /XYZ -13.423 915.745 null] >> endobj 185 0 obj << -/D [1474 0 R /XYZ 29.788 737.428 null] +/D [1476 0 R /XYZ 29.788 737.428 null] >> endobj 189 0 obj << -/D [1474 0 R /XYZ 29.788 596.231 null] +/D [1476 0 R /XYZ 29.788 596.231 null] >> endobj 591 0 obj << -/D [1474 0 R /XYZ 29.788 570.989 null] +/D [1476 0 R /XYZ 29.788 570.989 null] >> endobj -1477 0 obj +1479 0 obj << -/D [1474 0 R /XYZ 29.788 570.989 null] +/D [1476 0 R /XYZ 29.788 570.989 null] >> endobj -1478 0 obj +1480 0 obj << -/D [1474 0 R /XYZ 29.788 475.536 null] +/D [1476 0 R /XYZ 29.788 475.536 null] >> endobj -1479 0 obj +1481 0 obj << -/D [1474 0 R /XYZ 29.788 326.877 null] +/D [1476 0 R /XYZ 29.788 326.877 null] >> endobj -1480 0 obj +1482 0 obj << -/D [1474 0 R /XYZ 29.788 177.703 null] +/D [1476 0 R /XYZ 29.788 177.703 null] >> endobj 1318 0 obj << -/D [1474 0 R /XYZ 29.788 63.19 null] +/D [1476 0 R /XYZ 29.788 63.19 null] >> endobj -1473 0 obj +1475 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R /F89 511 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R /F89 511 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj -1489 0 obj +1491 0 obj << /Length 1772 /Filter /FlateDecode >> stream -xڵXYo�8~����h�:��n��v�� �C���Zؒ�#���;<t�N6i8!ErFs|sP���_m� AD����3�$#�#JQ(�D�B���G�g�K�fH&�e4��5���E�&��bQ�ޏ�L�1�sc�N��S� �XR��j=�c!�B-L|��y��2t��� �7ͻ75L;�������D=/��j�S�k�����e�EC�"��'���(+j���Hnu��gtO�ڑ�^��ي��!�F����̮����HZ�#� QY/t;}����ǂp:WY��Z_�->L�.z�P! 0�����A l~@���st����м�����I� '�j��m�\�ҁJ����������>�Ԧ��4���u�&�(�\<=5�dQP�@@�d���#�gX'��3�.<�ɴ4^��@��eA���Ќ��vRs��4��e���J�^�uu��e��Հ�5U'�m��-���ʪ��_�6��Ң��}�,/���� ���'�9�X�s�,y�+�3�NJ�0������XQ���`�H�ި��\:����9�J�N��;�;�����G�wy|�-�'�1�����a�̗:�V[�Pgieg�Ҿ�Tb��bt�P�A�������4���~Y�a@�Pn�9����!*D�$�_�&�O�S�ϡ%8FK��<"���U�p������G����m���jb�a���H�+i<� H(t�}�Ik� -D\���9F���ц���t�p`�L��)hH��Y/ɳ���|Ww�#v�=���d��f ���f�>a+���2��� �ŚÙQ�a��!��m[�̫�^����W�����SIɜ��!��9�2�b��*U��<�/�Գ�0����O��I<p%���GKEי�����%���?��.0H2^`@���{�����6��h����2]�J����TQ}s@z��n�]�/t��\k� ��?��&���#'��q��y�/ I���.�Z� �9m�:���索�tפ�KU���`�Ȉ�<a&��T�&�4����lԚ���J|�������p#�]=$&0�^��m�3 evB�c�u$��*�(�xa�����ٰ�:���Cz-�z՚O���"dh\�Z�ū���]`f��7�Zi�X��H�C�U�r7�:�~g&}q�����)^�M�oQ7�S�V�qa��+����<bh8��?�~s��2�F��"`���<1!�6�̈́�O��#�t�]�� ��G�¥�������F�4�1f�Y^�P����e����i���*^]x�`����xo�x���]�<s��^�IH�i����A��LZ��ӹop�խ���A��y��+��x���7�gz���v��� >ҷI���}������<�CR�!$�����7p h��o����2t�=�@�����B�`m��␇��f�r�5�x�]oD������X����o���Z5��17��ߟ�xD�7�Ih��PwR����=z�U�7q�IL��H���էC�;�4�xZg��O�K�6�2�c��^�0'D��'݆���O����'x��������Pl�����V���N�f�\o�pWM����ĔQ�g_-�$-y�A4U�vyZ��� -]�Y -�*I+`��(#��G�6�@� ����\���èv@Eʪaa��]���A�H���4��=@���c�h"�0������x)$������u{ +xڵXIo�F��W�Q�g#��%u�$@��Ѓc�8�XH���i����Y�J�k'd�p�Ƿ|o�lq�A�r� �����3��HDG� �)�@�B���G�g@MfxMP�h|kּ�{A��� +�yD�z?b�S�ǔ 9�BLX�BI� T�z�G%��f&A�8մ�F:K��3�5M�75D;�������X=���b��k���IJ��}�",���'���-�Ē��/�������?%kw��������a����dv�$G<����R�0��^$�v�&/����r:WY��Z_�->L�.z�.�C�N��{�6? �J�st���м/f� gYH@s�`�A�n�O�@D�iHFB���nex�UjS�U�gv�Nez.���3��Cg���sɐP�}ǚ�SL/<�ɴ4^�ɀ�����ׄ���vBS��4�� +TLW�Z/�:�ղz�j@Ъ�cH�6KK�}��*��W��M~oLJ���xg,�!�x�61z���!�����\){=ޕ�u�ay�0�oM?^�#Тv[�/,y#�cs鄮N���* 9�W�o挒n2�����{���0�������S_�`[m�B����%J�.S�}�ϋ��B���҇��S���c�j�?� +0[��EE�Q���X&��B4)�˞"|-�1Zz��'_�`yU<!㾮��Q�~sp��;Gk��w�r;�JF5r�y_w���e�~��@g?��!ű�<HLlq��)�r����,���Y�zO����;���RH2\M3��No����njCӂZ�x�C�b�����h��6�-��UQ���FݫBek�� ���N�P�tW�%s��]R���e�ٕ�F���� �sLI ,�����}�#�����KP���vU`���y=�$�NB,��{�����6��hぇ��2]�R����TQ}s@z��n]�-t�LK� ��?`�&���"'��q��y�- H���΅Z�q�i�:���索�tׄ�KU���`�Ȉ�8�a���P�"�4����lĚ���J|2�@o��z�tU� ���as��GC�S��,CI��7 +4^ا/i�}6,����!��e�jէ��Q2w\���*�W;ǟk`f��c7�Zn�X��H�C#U�r7�:�~�&�8���z�Wy�[ԍ�T��w���~��r���E ��'�o�Z�H�Q�XHW���'���FW �iWvD�L�끺$�����(���ֿ��8�(=3F�z#˫Қ���R���5;́z�Rū/�4��-��揷���^�癎�{���KO�U��g�˓Qh���Ґ3D��mG��x%��7����x�i����T/`l��I���}:���J}�{~�Q�CH��n`$DPR��~CA�3����h(F��/H_���Z>�zk��L�e��w�M�h�v��e�wKo����z�������V��7r̍l��'H��b_�/1ĝ���z�^���Mr�&=�P���thrg����Ok����{���v�/C�S�Ë��+��d��9��Ę�}}�G>�ޯ�� �mɖ��kݸ�"�lu�7s���aܵ�nc�I��1ξZ�IZ�2ޙ�T�{��ie��[*T� ��fINU�V@���FVu�N\�`��'dm�����ڇQ�U���������fI�h�=p{�:��=F9��DPn>$C�%���b<���up endstream endobj -1488 0 obj +1490 0 obj << /Type /Page -/Contents 1489 0 R -/Resources 1487 0 R +/Contents 1491 0 R +/Resources 1489 0 R /MediaBox [0 0 595.911 842.745] -/Parent 1411 0 R -/Annots [ 1481 0 R 1482 0 R 1483 0 R 1484 0 R 1485 0 R 1486 0 R ] +/Parent 1413 0 R +/Annots [ 1483 0 R 1484 0 R 1485 0 R 1486 0 R 1487 0 R 1488 0 R ] >> endobj -1481 0 obj +1483 0 obj << /Type /Annot /Subtype /Link @@ -12724,7 +12696,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga832388c889417ed197609d9965625bfe) >> >> endobj -1482 0 obj +1484 0 obj << /Type /Annot /Subtype /Link @@ -12733,7 +12705,7 @@ endobj /A << /S /GoTo /D (structbsec__output__t_ab188da3e58d458f4b94a64379404da46) >> >> endobj -1483 0 obj +1485 0 obj << /Type /Annot /Subtype /Link @@ -12742,7 +12714,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga832388c889417ed197609d9965625bfe) >> >> endobj -1484 0 obj +1486 0 obj << /Type /Annot /Subtype /Link @@ -12751,7 +12723,7 @@ endobj /A << /S /GoTo /D (structbsec__sensor__configuration__t_a150ba3a737fb75f56052c60d55246ae4) >> >> endobj -1485 0 obj +1487 0 obj << /Type /Annot /Subtype /Link @@ -12760,7 +12732,7 @@ endobj /A << /S /GoTo /D (structbsec__sensor__configuration__t_a92665e4f2f3cd5237814488774c0f546) >> >> endobj -1486 0 obj +1488 0 obj << /Type /Annot /Subtype /Link @@ -12769,102 +12741,99 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga49210a8ceb36d8610075b9220a0cdec6) >> >> endobj -1490 0 obj +1492 0 obj << -/D [1488 0 R /XYZ -13.423 915.745 null] +/D [1490 0 R /XYZ -13.423 915.745 null] >> endobj -1491 0 obj +1493 0 obj << -/D [1488 0 R /XYZ 29.788 737.428 null] +/D [1490 0 R /XYZ 29.788 737.428 null] >> endobj -1470 0 obj +1472 0 obj << -/D [1488 0 R /XYZ 29.788 636.452 null] +/D [1490 0 R /XYZ 29.788 636.452 null] >> endobj -1492 0 obj +1494 0 obj << -/D [1488 0 R /XYZ 29.788 614.986 null] +/D [1490 0 R /XYZ 29.788 614.986 null] >> endobj -1471 0 obj +1473 0 obj << -/D [1488 0 R /XYZ 29.788 502.963 null] +/D [1490 0 R /XYZ 29.788 502.963 null] >> endobj -1493 0 obj +1495 0 obj << -/D [1488 0 R /XYZ 29.788 481.497 null] +/D [1490 0 R /XYZ 29.788 481.497 null] >> endobj -1469 0 obj +1471 0 obj << -/D [1488 0 R /XYZ 29.788 414.01 null] +/D [1490 0 R /XYZ 29.788 414.01 null] >> endobj -1494 0 obj +1496 0 obj << -/D [1488 0 R /XYZ 29.788 392.544 null] +/D [1490 0 R /XYZ 29.788 392.544 null] >> endobj 673 0 obj << -/D [1488 0 R /XYZ 29.788 325.058 null] +/D [1490 0 R /XYZ 29.788 325.058 null] >> endobj 193 0 obj << -/D [1488 0 R /XYZ 29.788 302.166 null] +/D [1490 0 R /XYZ 29.788 302.166 null] >> endobj -1495 0 obj +1497 0 obj << -/D [1488 0 R /XYZ 29.788 260.796 null] +/D [1490 0 R /XYZ 29.788 260.796 null] >> endobj 197 0 obj << -/D [1488 0 R /XYZ 29.788 142.722 null] +/D [1490 0 R /XYZ 29.788 142.722 null] >> endobj -1487 0 obj +1489 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R /F89 511 0 R /F97 510 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R /F89 511 0 R /F97 510 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj -1517 0 obj +1519 0 obj << /Length 2069 /Filter /FlateDecode >> stream -x���nܶ��_�� pD�7��[s;)��66Ї$0d-�V�+m$m���ΐ��Z�k���&E�s�pfx|��7FV�QHV$$gG�A�_`$$*Q4a�h�i,��>���1`� -ь�)N#�LW�{�{1����4� #�fB��JN1�k[tRĔ��ĚQ�8"E��&��N ��� {�~9�"� q�iπ8~��R��0�� -Z���������*���A�z��AJ!s�*�x��{x���/l�����Zʒ�8:>�d�&2���5� ��&q��}�$o�:�y�X/�MQ�Uc�W�/~>z{1`�Ie-<� �T#���C��ɟIB��ւnhdM·<P����+b��4�:��Vd�ԇ�9��(�ل���u<�/���&/7p�˗�2t�==�e�0F�8RQ� "A=a���|��,Ns�^:�N�l�1E�Ȝ�����p�7���P�R���f�6������S�C9����u�6����Um���j�2+��|�s"�l^���w�Q�4�0h��[hǦ]b{�k�?�5��]����k�7��<kG=��{e�3U��u?���"AS -~-��=��v���^OH�]7��X�^��fI'B���S4P�װ�`�<D ��h��1D���/���O��L�l(��s{2 -����,0����$l���Hh�ؘ�ȋ��@2�mn���,�x2�#�I���3K�5Ų_Z�����U���R7�.k�J�S۩'`���35�ĥ�ߋ��e��5���JG���Z�3�Zz���qC%�so�1�k�]eս�.�/��U�U���)T!��Ȏ��VSi=�'r�W�����4 Ȯ�rG.�������"�S�.��vp����$�K"���߇���+�6g�j�'8P�b��7=N��v��b{�$�a{;=E͝y�Q\�T��rB��0QS!�<[�OH3�C����kY�����zc�me�U����O`��a"���fJ��!d��8]3c#�CT91������f�jV�C��a��lF�<� �QgS $>O�`�L�/��(��Hzu�:���<�����f��6�8D�S>���h��w��SH��;�����#$�<����t�g]��ST@X��n�a.���G��S@�<��hI��\��R*��R�h��T� {}fj�;��`�Me��ܳU��a�43��Iڤ�M��y�?)W=>��4e�T)�v�ģx�c©-����'���O��K|�O��$����n,mL�?�ܛ�/���J���ˈ -�A �h��)���3{�Y$���q\^�V�}{AS�}����d~ϗ�];|�4��Z�H�u����t�{�n�+'�Kl�X՜_�ן�컶���t�q���� �e��I�laz ��q�a.u�mm��j�(J[��!l��0�05y[{q�i�t��I�%uS�*�._Z� �����[�٢L�{�����6_�;�\��o�f�ٺ��~wmi�!��/��%c�d෮��!��NO�(�Qc�������K��L�8��D�m�,j��\:IZ2� �M�œ���|����O�a~�j�u'�+�|sS�<�?� ����al�`��2��WA�H��d��_�F:e��V�����:�����p�� v��y_3��%�A���M�S��Gۘ��Y�al��^� -&AOXݖ}5yg�C�a��,k��<IP�b�0tvo:�h�2�w�#�+�.�?@�ᬄ��~AB&4h�m@����`2L�Uނu�s�A�:=]?F���-疷�=<z��i������� y�T���˫�&b��B���a<������S���M730�� -2� -����̐��'$����5L5x �O�8�\�sh�n@&?��Ʊ*_���3���|J����UZ�z6|��w�z��۲N�vA�0߶�2w51?T�mU.�l���,s�(x�@w��n�&����� dl�mn�z=�"�,�}k�v���rH��u��[���g�;$�}8�j��j�;��7*��:>lC,��G��Ň�xP� +x���nܶ��_�� pD�7��[s;)��66Ї$0d-�V�+m$m���ΐ��Z�k���&Er�s�pfx|��7FV�QHV$$gG�A�_`$$*Q4a�h�i,��>����c�B��)N#�L���=��A0�+Me�H��@��SL���1e""�fT1�H���渦�F�EBr��)�^�_��`C܃�E�3`��o9)����>��>���/�h��-'�0�$�J�$~�����q�R�:�J8^��^�C�� �M~?�q RAY!�����S0J&h"�\\��Xk'N�K�q�W����uY5&{���磷f�T��c��L5���9$K���� TNn�� .Y��!Tp�4�1W`T�`V+�o���LE��l�����:��YUi���8��Kc:Ԟj�2I��R)��Ԃ���0E�d� +�D��Y/M'e�ۘ�qd���p�`C8�T�u(h)s��t�]�K`z���)��A�"9��z]� `�jqU�첶ڿ���:_�/�ׯ'�>F�1M9Z��v�cӂ�^y����|ͫf���l�����:��QG���^��L��pݏ�~|�HД�_��w�a�ݢ={���j�M+?����Y҉�(BD� �5�%�/Q�./}�(E�?���K0���:S=[J-�ܞ��'u�<�)��� �7Z.6&-�b�>�l���v=K$���n�be���lM��A���`�j��]��e���:��z��2_v�����{q׳�ܡ��T�ȱ�V+{��TK�sp^2ch�$t�m:~�|�PVݻ����]�Y�oQ۟B���ô�J�>���Ƽ�Ԧi@v��;r�o�8h8���v��η�X@8��λ��.�L��+~X�@��X���9�`Tc�8��J�ǝ��qZt���=0��[& ���)j��뎺ತ��������� +�E�ْ}B�a^@��TG��^��՝v��Sm+3�G�J�.~�w q��=�0c�P�� ����"����ȉ�^����&�0�V��m {L�e3��yuL��:�j �y�g"~!uF1 Eҫs��������6�4[m��!�<��uFG����B��8��W�Ȭ�}!�����?�rO��Ƞ�J�wsa�h�>?Ƙ�䱧DK*d�2��R m��(E;���m��3Sܹ�sm*Sd枭���u���]N�&uhl:V��I���N�)��J1��'��(�Nm�d�<!�ܤB�x_�{|��$�ĄGvcic������|~�H\��T2N�^FThJ�@�O ,/�!���"�����j� ������o�&�{�4��ᣥy����E2���O�����u[^91]b3Ū������gߵ5��,��+����6o�.��Mf�K�8w�#� s��ok�ֈW�EQ��a+,��X��Y��ڋL����Mڂ�M�3l\P�|ie�8K?�A�&�E��}�L��n��|��s�+�a�ef� +Z8�ݵ�-��_�P,"X�����ߺ���:=aR�,G�=^3��^�.�Z3M����e����r�$iUl�(���6�WO"��/l���qr�? ������U���@��M��@�9�_c[��v�+S�~Ĝ��.�N���m��`P�l:��a�[���ʞ`ǎԳ~oKp�p��Ƨ +����1#���4�ƭ��L����-�8j>��Ό�<�(��Y��wy���ńa���t��0�w�#�+��� �pVB�rk� !4Ӷ�E����`2L��.o�u�s��tz +?F���-疷�=<z��i����+�7�g�4�v; �W�M�b=|��ɯ�K�5uN��Gk�1���q�13� �U����7�R����� ��a�)g��wnm�� ���'��8V�[|ƾ�B��O��:?�J+_φϴ��P/�z[���$�m�.sW�C��V�.�vH/�2NJ�_�(�.�� `��9�B�F��֬��*r���ݷ�kW�n/�t�]睿ő��}f�Cڇ�vk�ƿ�8��{�����6�2�}�PjZ|���P� endstream endobj -1516 0 obj +1518 0 obj << /Type /Page -/Contents 1517 0 R -/Resources 1515 0 R +/Contents 1519 0 R +/Resources 1517 0 R /MediaBox [0 0 595.911 842.745] -/Parent 1523 0 R -/Annots [ 1496 0 R 1505 0 R 1507 0 R 1508 0 R 1509 0 R 1510 0 R 1511 0 R 1512 0 R 1513 0 R 1514 0 R ] +/Parent 1525 0 R +/Annots [ 1498 0 R 1507 0 R 1509 0 R 1510 0 R 1511 0 R 1512 0 R 1513 0 R 1514 0 R 1515 0 R 1516 0 R ] >> endobj -1496 0 obj +1498 0 obj << /Type /Annot /Subtype /Link @@ -12873,7 +12842,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga49210a8ceb36d8610075b9220a0cdec6) >> >> endobj -1505 0 obj +1507 0 obj << /Type /Annot /Subtype /Link @@ -12882,7 +12851,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga49210a8ceb36d8610075b9220a0cdec6) >> >> endobj -1507 0 obj +1509 0 obj << /Type /Annot /Subtype /Link @@ -12891,7 +12860,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga832388c889417ed197609d9965625bfe) >> >> endobj -1508 0 obj +1510 0 obj << /Type /Annot /Subtype /Link @@ -12900,7 +12869,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga5e4d504611e1c4a0219861bbcf2ad650) >> >> endobj -1509 0 obj +1511 0 obj << /Type /Annot /Subtype /Link @@ -12909,7 +12878,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga5e4d504611e1c4a0219861bbcf2ad650) >> >> endobj -1510 0 obj +1512 0 obj << /Type /Annot /Subtype /Link @@ -12918,7 +12887,7 @@ endobj /A << /S /GoTo /D (group__bsec__interface_ga832388c889417ed197609d9965625bfe) >> >> endobj -1511 0 obj +1513 0 obj << /Type /Annot /Subtype /Link @@ -12927,7 +12896,7 @@ endobj /A << /S /GoTo /D (structbsec__version__t_af823001b85e62b90279f9e6f3c478c23) >> >> endobj -1512 0 obj +1514 0 obj << /Type /Annot /Subtype /Link @@ -12936,7 +12905,7 @@ endobj /A << /S /GoTo /D (structbsec__version__t_a9d47d254d17740222791fa0f53c7ac52) >> >> endobj -1513 0 obj +1515 0 obj << /Type /Annot /Subtype /Link @@ -12945,7 +12914,7 @@ endobj /A << /S /GoTo /D (structbsec__version__t_a3d9b11a72027026f492a438342a2efbd) >> >> endobj -1514 0 obj +1516 0 obj << /Type /Annot /Subtype /Link @@ -12954,70 +12923,70 @@ endobj /A << /S /GoTo /D (structbsec__version__t_a5daac4534748c6f0be9f009273613b02) >> >> endobj -1518 0 obj +1520 0 obj << -/D [1516 0 R /XYZ -13.423 915.745 null] +/D [1518 0 R /XYZ -13.423 915.745 null] >> endobj 201 0 obj << -/D [1516 0 R /XYZ 29.788 737.428 null] +/D [1518 0 R /XYZ 29.788 737.428 null] >> endobj 677 0 obj << -/D [1516 0 R /XYZ 29.788 719.646 null] +/D [1518 0 R /XYZ 29.788 719.646 null] >> endobj -1519 0 obj +1521 0 obj << -/D [1516 0 R /XYZ 29.788 719.646 null] +/D [1518 0 R /XYZ 29.788 719.646 null] >> endobj 676 0 obj << -/D [1516 0 R /XYZ 234.846 638.216 null] +/D [1518 0 R /XYZ 234.846 638.216 null] >> endobj -1520 0 obj +1522 0 obj << -/D [1516 0 R /XYZ 29.788 617.606 null] +/D [1518 0 R /XYZ 29.788 617.606 null] >> endobj -1521 0 obj +1523 0 obj << -/D [1516 0 R /XYZ 29.788 510.563 null] +/D [1518 0 R /XYZ 29.788 510.563 null] >> endobj 1069 0 obj << -/D [1516 0 R /XYZ 29.788 389.752 null] +/D [1518 0 R /XYZ 29.788 389.752 null] >> endobj 205 0 obj << -/D [1516 0 R /XYZ 29.788 370.414 null] +/D [1518 0 R /XYZ 29.788 370.414 null] >> endobj -1522 0 obj +1524 0 obj << -/D [1516 0 R /XYZ 29.788 329.111 null] +/D [1518 0 R /XYZ 29.788 329.111 null] >> endobj 209 0 obj << -/D [1516 0 R /XYZ 29.788 142.709 null] +/D [1518 0 R /XYZ 29.788 142.709 null] >> endobj -1515 0 obj +1517 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R /F89 511 0 R /F97 510 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R /F89 511 0 R /F97 510 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> endobj -1526 0 obj +1528 0 obj << /Length 1144 /Filter /FlateDecode @@ -13025,75 +12994,78 @@ endobj stream xڵW�n�8}�W�QV4���fs��M�C�d��Uؒ+�I ��wH�f�F��$�m�p�p43�Lo>Q��F-A�#X -�7�!Hj�5�H �c!Qi�b����P��0�j��H�C�I{gEV�����BS�n�L�C�Sc'x�)�P�(��YPk`gLa��q0�".�����$����LhO�mL�o8�(���ƾL����%)�����"�!��P:~�UoxHx�P3"���OOp/q�U�|~5q0Rq������t4����k�h�@L�X)k���9�*]�C����UQ�&�~]Nd��.�c������}!h��2��D7Vl�h�n�0gT*��1�X��VKt����*#�bz@���O��}^�e��Y����]67��k��,�R��d�2���Qq�&��lB�W�YϽME�ۘ��f��c�c |� O���,�x�|-�=��e�'E��.�ku_�6���2���)+0�>;�м��L� -3�t ����h��1���6`p?�-��o���R�����u�@�O�Aod��Y�;ߩE{���{#1`�?�S����3��w���5C���=G�o�|��t����< �b�Y�S��q(�((Me��Bs��.�:���n�դ�_ԅ�U�/����1�WŮȋ:K��������63S��ØQȢӱ�Ax��2R$���e���߄��:�)fR�Ɩ��#⣩l������I,|�V�蠊�P�*���k�F�{ ��H6C�&&����s���!�B��J��eř�Q�Y��4:��N�ccQ+ �����>����Ŋ+x�v5����@9hY�V�;?&���LJ���+K��<n����2�!�&�u7�����y�A����&N�*7B�a'�GS#ӈ�hꚦ��dlC�_��td����h(6��s��� j[����s9��`)����/`cC6�"x�^��2[�ꪙ7Y�X -$�h�I9��_&�w=ϪmQ%k���]�op���l�b�K�-�yVT#�u��v������s����X��w -Bn̚��^?1.��i�hd��u��[��hkI��wր��k������wγҹW�$�3js|S�d����ICE +�7�!Hj�5�H �c!Qi�b����P��0�j��H�C�I{gEV�����BS�n�L�C�Sc'x�)�P�(��YPk`gLa��q0�".�����$����LhO�mL�o8�(���ƾL����%)�����"�!��P:~�UoxHx�P3"���OOp/q�U�|~5q0Rq������t4����k�h�@L�X)k���9�*]�C����UQ�&�~]Nd��.�c������}!h��2��D7Vl�h�n�0gT*��1�X��VKt����*#�bz@���O��}^�e��Y����]67��k��,�R��d�2���Qq�&��lB�W�YϽME�ۘ��f��c�c |� O���,�x�|-�=��e�'E��.�ku_�6���2���)+0�>;�м��L� +3�t ����h��1���6`p?�-��o���R�����u�@�O�Aod��Y�;ߩE{���{#1`�?�S����3��w���5C���=G�o�|��t����< �b�Y�S��q(�((Me��Bs��.�:���n�դ�_ԅ�U�/����1�WŮȋ:K��������63S��ØQȢӱ�Ax��2R$���e���߄��:�)fR�Ɩ��#��T�WG��Bp�$�� ��dtPEb(�]y��u����Cx$��E����ݹ@b���D!o +%�߲���i���,�} �PC'ﱱ��OYu�P +��o�b��L;��i�F��ix���x+֝{���C�}���FZ��[��A��n��H���<ݠ_�jw�`�����հ�꣩�iD\4uMS��{2���/�l:2p�r4� +�x ��9b�vm���^Gǹtt���f��?���!S�[��^�-Wu�̛,�,� +�uU�ˤ�g��/�����gն���SЁyڮ��78�Vi�e1ߥݖ +�<������f��NR�dŀ��9�l�h���;!7fM�W�������X4���:���Y��$��;k@����[S����;�Y�ܫS� ���9�)V2�S���Q�C: endstream endobj -1525 0 obj +1527 0 obj << /Type /Page -/Contents 1526 0 R -/Resources 1524 0 R +/Contents 1528 0 R +/Resources 1526 0 R /MediaBox [0 0 595.911 842.745] -/Parent 1523 0 R +/Parent 1525 0 R >> endobj -1527 0 obj +1529 0 obj << -/D [1525 0 R /XYZ -13.423 915.745 null] +/D [1527 0 R /XYZ -13.423 915.745 null] >> endobj 213 0 obj << -/D [1525 0 R /XYZ 29.788 737.428 null] +/D [1527 0 R /XYZ 29.788 737.428 null] >> endobj 1093 0 obj << -/D [1525 0 R /XYZ 29.788 719.646 null] +/D [1527 0 R /XYZ 29.788 719.646 null] >> endobj -1528 0 obj +1530 0 obj << -/D [1525 0 R /XYZ 29.788 719.646 null] +/D [1527 0 R /XYZ 29.788 719.646 null] >> endobj 1095 0 obj << -/D [1525 0 R /XYZ 29.788 654.393 null] +/D [1527 0 R /XYZ 29.788 654.393 null] >> endobj -1529 0 obj +1531 0 obj << -/D [1525 0 R /XYZ 29.788 635.851 null] +/D [1527 0 R /XYZ 29.788 635.851 null] >> endobj 1094 0 obj << -/D [1525 0 R /XYZ 29.788 572.558 null] +/D [1527 0 R /XYZ 29.788 572.558 null] >> endobj -1530 0 obj +1532 0 obj << -/D [1525 0 R /XYZ 29.788 554.015 null] +/D [1527 0 R /XYZ 29.788 554.015 null] >> endobj 1096 0 obj << -/D [1525 0 R /XYZ 29.788 492.707 null] +/D [1527 0 R /XYZ 29.788 492.707 null] >> endobj -1531 0 obj +1533 0 obj << -/D [1525 0 R /XYZ 29.788 474.164 null] +/D [1527 0 R /XYZ 29.788 474.164 null] >> endobj -1524 0 obj +1526 0 obj << /ColorSpace 3 0 R /Pattern 2 0 R /ExtGState 1 0 R /ExtGState<</TRP1<</ca 1/CA 1>>/TRP.5<</ca .5/CA .5>>>> -/Font << /F45 229 0 R /F44 228 0 R /F120 619 0 R >> +/Font << /F45 229 0 R /F44 228 0 R /F122 619 0 R >> /XObject << /Im3 221 0 R /Im4 222 0 R >> /ProcSet [ /PDF /Text ] >> @@ -13107,43 +13079,43 @@ endobj 3 0 obj << /pgfprgb [/Pattern /DeviceRGB] >> endobj -1532 0 obj +1534 0 obj [799.4] endobj -1533 0 obj +1535 0 obj [525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525] endobj -1534 0 obj +1536 0 obj [513.9] endobj -1535 0 obj +1537 0 obj [777.8 500 777.8] endobj -1536 0 obj +1538 0 obj [525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525 525] endobj -1537 0 obj +1539 0 obj [295.1] endobj -1538 0 obj +1540 0 obj [1062.5] endobj -1539 0 obj +1541 0 obj [500] endobj -1540 0 obj +1542 0 obj [633] endobj -1542 0 obj +1544 0 obj [500 500 167 333 556 222 333 333 0 333 584 0 611 500 333 278 222 655 789 811 549 713 549 549 494 713 823 670 333 191 278 278 355 556 556 889 667 222 333 333 389 584 278 333 278 278 556 556 556 556 556 556 556 556 556 556 278 278 584 584 584 556 1015 667 667 722 722 667 611 778 722 278 500 667 556 833 722 778 667 778 722 667 611 722 667 944 667 667 611 278 278 278 469 556 222 556 556 500 556 556 278 556 556 222 222 500 222 833 556 556 556 556 333 500 278 556 500 722 500 500 500] endobj -1543 0 obj +1545 0 obj [500 500 167 333 556 222 333 333 0 333 584 0 611 500 333 278 222 655 789 811 549 713 549 549 494 713 823 690 333 191 278 278 355 556 556 889 667 222 333 333 389 584 278 333 278 278 556 556 556 556 556 556 556 556 556 556 278 278 584 584 584 556 1015 667 667 722 722 667 611 778 722 278 500 667 556 833 722 778 667 778 722 667 611 722 667 944 667 667 611 278 278 278 469 556 222 556 556 500 556 556 278 556 556 222 222 500 222 833 556 556 556 556 333 500 278 556 500 722 500 500 500 334 260] endobj -1544 0 obj +1546 0 obj [611 611 167 333 611 278 333 333 0 333 584 0 611 500 333 278 278 744 1042 1083 549 713 549 549 494 713 823 766 333 238 278 333 474 556 556 889 722 278 333 333 389 584 278 333 278 278 556 556 556 556 556 556 556 556 556 556 333 333 584 584 584 611 975 722 722 722 722 667 611 778 722 278 556 722 611 833 722 778 667 778 722 667 611 722 667 944 667 667 611 333 278 333 584 556 278 556 611 556 611 556 333 611 611 278 278 556 278 889 611 611 611 611 389 556 333 611 556 778 556 556] endobj -1545 0 obj +1547 0 obj << /Length1 1416 /Length2 6052 @@ -13187,7 +13159,7 @@ k?_ Z$��"��qr���,�8jL�����ŅK;J�2p�rݷ����\s~�����a~�Ѳ$:�cNLJ����j��ux�L>�� ͋��y���->��j��Łyn����c>�yR��X�PHi�d�{��G�%�ź����Q�xz �qKʽ����w���ǟ�;V>|�F�����z`G���a������\��x����m����I6.�r�����v�� �kz�7ٌ��(I����(�^ endstream endobj -1546 0 obj +1548 0 obj << /Type /FontDescriptor /FontName /SYFPBV+CMMI10 @@ -13200,10 +13172,10 @@ endobj /StemV 72 /XHeight 431 /CharSet (/greater/less) -/FontFile 1545 0 R +/FontFile 1547 0 R >> endobj -1547 0 obj +1549 0 obj << /Length1 1398 /Length2 5932 @@ -13233,7 +13205,7 @@ L) �!����qD������S�猡�U�ؖ��f$ �-��D7����oZ� endstream endobj -1548 0 obj +1550 0 obj << /Type /FontDescriptor /FontName /GNUTFA+CMMI8 @@ -13246,10 +13218,10 @@ endobj /StemV 78 /XHeight 431 /CharSet (/arrowhookright) -/FontFile 1547 0 R +/FontFile 1549 0 R >> endobj -1549 0 obj +1551 0 obj << /Length1 1388 /Length2 5940 @@ -13285,7 +13257,7 @@ wD% ՐRX���������g:��g[���G$�A���_�\De)��h�'�辊�'����B�+Ei�0��'H�q6��J���c��N4�E����@��Iw���`�m$�t�Akj��&u���h���]E0�v���@|S� endstream endobj -1550 0 obj +1552 0 obj << /Type /FontDescriptor /FontName /QMHUCV+CMMI9 @@ -13298,10 +13270,10 @@ endobj /StemV 74 /XHeight 431 /CharSet (/less) -/FontFile 1549 0 R +/FontFile 1551 0 R >> endobj -1551 0 obj +1553 0 obj << /Length1 1386 /Length2 6039 @@ -13336,7 +13308,7 @@ Hb` ��� R�{:D�qY�d��_���(��0W�T��6��T�v�A����a��#�I5�D��1H��_mʎ�A�Ƈటk߁w鄍X�D�g]�?�K�� endstream endobj -1552 0 obj +1554 0 obj << /Type /FontDescriptor /FontName /UEIZYW+CMSY10 @@ -13349,10 +13321,10 @@ endobj /StemV 40 /XHeight 431 /CharSet (/asteriskmath) -/FontFile 1551 0 R +/FontFile 1553 0 R >> endobj -1553 0 obj +1555 0 obj << /Length1 1376 /Length2 5989 @@ -13402,7 +13374,7 @@ $ �&l�����6��jLu��F"f+�n9zj�ywJ�ya0�ݛ�z��L���.b�1It�� �X��v���cڃnռ%�rJ�Y����2�ݕ���oR��o�}�uIM7����4� 8F�-Q�f�OY4�q�~���i����Y7r��ڠW�&l�}�'e��Z\�%�����P5X3A�$"y����[7����r<r# endstream endobj -1554 0 obj +1556 0 obj << /Type /FontDescriptor /FontName /HTWALK+CMSY8 @@ -13415,10 +13387,10 @@ endobj /StemV 46 /XHeight 431 /CharSet (/arrowleft) -/FontFile 1553 0 R +/FontFile 1555 0 R >> endobj -1555 0 obj +1557 0 obj << /Length1 1378 /Length2 6048 @@ -13458,7 +13430,7 @@ C ֵ ?ޡ��M [R,03�3��3k�� ��Ѧʑ�x��w�`yv�-y��U�����#��Zw]\������S���'v?+��ö���V�$�'Ұb��� �^b�R��^��>n��Q�>��!��� endstream endobj -1556 0 obj +1558 0 obj << /Type /FontDescriptor /FontName /GJVTUN+CMSY9 @@ -13471,10 +13443,10 @@ endobj /StemV 43 /XHeight 431 /CharSet (/asteriskmath) -/FontFile 1555 0 R +/FontFile 1557 0 R >> endobj -1557 0 obj +1559 0 obj << /Length1 1894 /Length2 113985 @@ -13915,7 +13887,7 @@ v ��h��� �n`*�JQ� 4�i,��$���9xBXά��k�+M�-��w)^�^��o�����Q&ֿ;K���m>�/�٩�h��X��$/���3�� w˒[���3Q78�@ K�}K���?���Í���{��3�E�����PB���ƃ�"na�Zh0��S�p7�Y��N�x�����k�,����sGM3ρ���{j���4}jV����A���V�'��0���H q�����o`��en?.�F����w<C�f�H����Oh�3W�R�1�1� �3[T�feJ���N��.���O[L��qu����:E=�w�ٜG��ۃ���|L" �:7N���]n��/�,�R<M�\}�_M1Z���`��ܟy$zf��60�fM�gC4Y&�1c?n��bc�m�����P�]N�!ɗv�ň$yf�ڜ�q(���J��ez�n5_�\�閱��= 杹�.2kD�o6pPǝ�QP��D���W�xaa�S��D�AFC�p�����z�e�Wt������A=��GG'�Q������D� endstream endobj -1558 0 obj +1560 0 obj << /Type /FontDescriptor /FontName /WRFWLY+BoschOfficeSans-Bold @@ -13928,10 +13900,10 @@ endobj /StemV 150 /XHeight 523 /CharSet (/A/B/C/D/E/F/G/H/I/K/L/M/N/O/P/Q/R/S/T/U/V/W/X/Y/Z/a/b/c/d/e/eight/f/ff/fi/five/four/g/h/hyphen/i/j/k/l/m/n/nine/o/one/p/parenleft/parenright/period/q/question/quotedbl/r/s/seven/six/slash/t/three/two/u/underscore/v/w/x/y/zero) -/FontFile 1557 0 R +/FontFile 1559 0 R >> endobj -1559 0 obj +1561 0 obj << /Length1 2170 /Length2 105555 @@ -14403,7 +14375,7 @@ Bֳ \Y(�����Qb���$C�ꃊ��s����r�pb���J����{��>�S��Xf��Tug�����u왁�������C���R;�%�/<[v��� �)� ?�5���G��:Jp�X�ϡh`ǔ�b�6�-��������1�t�}<��D endstream endobj -1560 0 obj +1562 0 obj << /Type /FontDescriptor /FontName /ADYYFI+BoschOfficeSans-Regular @@ -14416,10 +14388,10 @@ endobj /StemV 93 /XHeight 523 /CharSet (/A/B/C/D/E/F/G/H/I/J/K/L/M/N/O/P/Q/R/S/T/U/V/W/X/Y/Z/a/b/backslash/bar/bracketleft/bracketright/c/colon/comma/d/e/eight/equal/exclam/f/ff/ffi/fi/five/fl/four/g/h/hyphen/i/j/k/l/m/n/nine/o/one/p/parenleft/parenright/percent/period/plus/q/question/quotedbl/quotesingle/r/s/semicolon/seven/six/slash/t/three/two/u/underscore/v/w/x/y/z/zero) -/FontFile 1559 0 R +/FontFile 1561 0 R >> endobj -1561 0 obj +1563 0 obj << /Length1 1664 /Length2 94813 @@ -14805,7 +14777,7 @@ $ڑ ct��t�@O/�9���_���ˌ�PF�_ɯ���ş.ه1+� �H�CMޱ�EKF���_}l U6"f��ɳ-��L��1�,����Yj,F���ڻL{!�3>�(��O:I��*g�R�d�ߖ���^c�\N�2`H�t1L<q�A�t�'ɂۥ���V�n#z�ں����-�'����� endstream endobj -1562 0 obj +1564 0 obj << /Type /FontDescriptor /FontName /GYDQSB+BoschOfficeSans-Italic @@ -14818,10 +14790,10 @@ endobj /StemV 93 /XHeight 523 /CharSet (/A/B/C/E/H/I/M/O/P/S/T/a/b/bracketleft/bracketright/c/colon/comma/d/e/f/ff/fi/five/g/h/hyphen/i/j/k/l/m/n/o/one/p/parenleft/parenright/period/q/r/s/slash/t/three/u/underscore/v/w/x/y/z/zero) -/FontFile 1561 0 R +/FontFile 1563 0 R >> endobj -1563 0 obj +1565 0 obj << /Length1 1199 /Length2 806 @@ -14835,7 +14807,7 @@ A\$&e6�R 6��S� � �D��Y�H��i�5'*u(�����M�V�L8_� @G���]�Ɍ�����s���`��VJd���?�i�(���z!X�����}��i��j��x^�:�o�o��*W�>ڀ������S��|t�!��3��M�2S7&�����W'G-�^�9]7|��g '��{�ҭ~��sb��>ג�tu<{c�2;�Ybַ8��Rɺr�A^���|Sy�cqrJJ̙��W.v3}z7�A۲;biuݞm�5~!Y��z|ֳ��u�&�,�~,����{�����mm��I�$�O2�I4�g�i�hͲ��£�O����ބ��c�fpsƝ=�a�����E����7Fn�iS���$tU*�Y'.���#���̽�b���������n�ŦI'�u.����6{#||aWUNo�ǑK.�"��Sbbmv/\��$n�������E������j=+�:��TEB�ܢf^U�е"�U2��Ɋ]�F6���VR;���Ƨ�׳����8������n>�K�ј�o�/6�(S��H�ڶNk�-�"�o4/�Q�lp�W5l�^R{;��������c�S �--/N:�����"��֏������˓�]Ą+#��.��x�q�;<{y��-�����d���|E>y(N�u������6�N��yRn�շ����q�G���}90�������k�Wzg��h�_b-��ϞB����+�D�G��j����_��E_4���#u�Ɣ7�Qu.[r,P�(��lQ�f��;]s�-TU�9��:#��%~]N��W6{���T}V�2]��*��M���:��~������|�Gs�ٱw�\���{o��>�k�u��{.� ^>�Q��<���^��[����<�<�����הn"�����!k�'r�sr��m웨��<�Z%�x0 endstream endobj -1564 0 obj +1566 0 obj << /Type /FontDescriptor /FontName /WJPRUX+MarVoSym @@ -14848,10 +14820,10 @@ endobj /StemV 16 /XHeight 400 /CharSet (/Forward) -/FontFile 1563 0 R +/FontFile 1565 0 R >> endobj -1565 0 obj +1567 0 obj << /Length1 2139 /Length2 9316 @@ -14910,7 +14882,7 @@ w'J �ٜ}O��]��X���S�tvj�JY��|����T��S�ь�|���Q����܋�Ӥ�hJ�����zRZu��4%e1�ƞլN��L3ϤʭS|�k~�#r�~�ŝ���9�V endstream endobj -1566 0 obj +1568 0 obj << /Type /FontDescriptor /FontName /BOOWFK+t1xtt @@ -14923,10 +14895,10 @@ endobj /StemV 84 /XHeight 461 /CharSet (/A/B/C/D/E/F/G/H/I/K/L/M/N/O/P/Q/R/S/T/U/W/X/Y/Z/a/ampersand/asterisk/b/backslash/bar/braceleft/braceright/bracketleft/bracketright/c/colon/comma/d/e/eight/equal/f/five/four/g/greater/h/hyphen/i/j/k/l/less/m/n/nine/numbersign/o/one/p/parenleft/parenright/percent/period/plus/q/quotedbl/quoteright/r/s/semicolon/seven/six/slash/t/three/two/u/underscore/v/w/x/y/z/zero) -/FontFile 1565 0 R +/FontFile 1567 0 R >> endobj -1567 0 obj +1569 0 obj << /Length1 1134 /Length2 3354 @@ -14952,7 +14924,7 @@ k �����͢�Z X��ZE��-C33֬�ϾS�m���NI�=����:,��<Q����ނ��Jr3���[���q�[a�����/�*���c���Rst���D*s�l�3��>�2�Jsc�g�O+is��h�'�U61��Ϳ��^�kW:�'�\��A�7|ʥ���6\���ps��:��k�6�:'�7�Il��˩��������l�H7vp6xr�5T�yu�,���"N�<=��i���k*|ga��t��@+�I�)V�=����xz��=?L��"\������jG<H�����fW��sپ�OW�f��S��3�vC�&qԩi;��ö2 z�'�Aֱ*�\�x�[������!IQ�g���̏��G�STf�L���VuU��iSX����Q�E:y�\�?�P|���̊������;x�����c�����,� endstream endobj -1568 0 obj +1570 0 obj << /Type /FontDescriptor /FontName /SGLLBS+t1xtt-Slant_167 @@ -14965,10 +14937,10 @@ endobj /StemV 84 /XHeight 461 /CharSet (/a/b/c/comma/d/e/f/g/i/k/l/m/n/o/p/q/r/s/t/u/underscore/v/w/x/z) -/FontFile 1567 0 R +/FontFile 1569 0 R >> endobj -1541 0 obj +1543 0 obj << /Type /Encoding /Differences [2/fi/fl 19/ff/ffi 31/quotesingle 33/exclam/quotedbl 37/percent 40/parenleft/parenright 43/plus/comma/hyphen/period/slash/zero/one/two/three/four/five/six/seven/eight/nine/colon/semicolon 61/equal 63/question 65/A/B/C/D/E/F/G/H/I/J/K/L/M/N/O/P/Q/R/S/T/U/V/W/X/Y/Z/bracketleft/backslash/bracketright 95/underscore 97/a/b/c/d/e/f/g/h/i/j/k/l/m/n/o/p/q/r/s/t/u/v/w/x/y/z 124/bar] @@ -14979,10 +14951,10 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /SYFPBV+CMMI10 -/FontDescriptor 1546 0 R +/FontDescriptor 1548 0 R /FirstChar 60 /LastChar 62 -/Widths 1535 0 R +/Widths 1537 0 R >> endobj 532 0 obj @@ -14990,10 +14962,10 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /GNUTFA+CMMI8 -/FontDescriptor 1548 0 R +/FontDescriptor 1550 0 R /FirstChar 45 /LastChar 45 -/Widths 1537 0 R +/Widths 1539 0 R >> endobj 1366 0 obj @@ -15001,10 +14973,10 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /QMHUCV+CMMI9 -/FontDescriptor 1550 0 R +/FontDescriptor 1552 0 R /FirstChar 60 /LastChar 60 -/Widths 1532 0 R +/Widths 1534 0 R >> endobj 514 0 obj @@ -15012,10 +14984,10 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /UEIZYW+CMSY10 -/FontDescriptor 1552 0 R +/FontDescriptor 1554 0 R /FirstChar 3 /LastChar 3 -/Widths 1539 0 R +/Widths 1541 0 R >> endobj 531 0 obj @@ -15023,10 +14995,10 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /HTWALK+CMSY8 -/FontDescriptor 1554 0 R +/FontDescriptor 1556 0 R /FirstChar 32 /LastChar 32 -/Widths 1538 0 R +/Widths 1540 0 R >> endobj 996 0 obj @@ -15034,10 +15006,10 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /GJVTUN+CMSY9 -/FontDescriptor 1556 0 R +/FontDescriptor 1558 0 R /FirstChar 3 /LastChar 3 -/Widths 1534 0 R +/Widths 1536 0 R >> endobj 228 0 obj @@ -15045,11 +15017,11 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /WRFWLY+BoschOfficeSans-Bold -/FontDescriptor 1558 0 R +/FontDescriptor 1560 0 R /FirstChar 2 /LastChar 121 -/Widths 1544 0 R -/Encoding 1541 0 R +/Widths 1546 0 R +/Encoding 1543 0 R >> endobj 229 0 obj @@ -15057,11 +15029,11 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /ADYYFI+BoschOfficeSans-Regular -/FontDescriptor 1560 0 R +/FontDescriptor 1562 0 R /FirstChar 2 /LastChar 124 -/Widths 1543 0 R -/Encoding 1541 0 R +/Widths 1545 0 R +/Encoding 1543 0 R >> endobj 510 0 obj @@ -15069,11 +15041,11 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /GYDQSB+BoschOfficeSans-Italic -/FontDescriptor 1562 0 R +/FontDescriptor 1564 0 R /FirstChar 2 /LastChar 122 -/Widths 1542 0 R -/Encoding 1541 0 R +/Widths 1544 0 R +/Encoding 1543 0 R >> endobj 619 0 obj @@ -15081,10 +15053,10 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /BOOWFK+t1xtt -/FontDescriptor 1566 0 R +/FontDescriptor 1568 0 R /FirstChar 34 /LastChar 125 -/Widths 1536 0 R +/Widths 1538 0 R >> endobj 997 0 obj @@ -15092,10 +15064,10 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /SGLLBS+t1xtt-Slant_167 -/FontDescriptor 1568 0 R +/FontDescriptor 1570 0 R /FirstChar 44 /LastChar 122 -/Widths 1533 0 R +/Widths 1535 0 R >> endobj 511 0 obj @@ -15103,17 +15075,17 @@ endobj /Type /Font /Subtype /Type1 /BaseFont /WJPRUX+MarVoSym -/FontDescriptor 1564 0 R +/FontDescriptor 1566 0 R /FirstChar 183 /LastChar 183 -/Widths 1540 0 R +/Widths 1542 0 R >> endobj 230 0 obj << /Type /Pages /Count 6 -/Parent 1569 0 R +/Parent 1571 0 R /Kids [217 0 R 425 0 R 470 0 R 487 0 R 491 0 R 506 0 R] >> endobj @@ -15121,7 +15093,7 @@ endobj << /Type /Pages /Count 6 -/Parent 1569 0 R +/Parent 1571 0 R /Kids [527 0 R 571 0 R 594 0 R 603 0 R 614 0 R 625 0 R] >> endobj @@ -15129,7 +15101,7 @@ endobj << /Type /Pages /Count 6 -/Parent 1569 0 R +/Parent 1571 0 R /Kids [633 0 R 639 0 R 645 0 R 670 0 R 682 0 R 687 0 R] >> endobj @@ -15137,7 +15109,7 @@ endobj << /Type /Pages /Count 6 -/Parent 1569 0 R +/Parent 1571 0 R /Kids [704 0 R 731 0 R 758 0 R 788 0 R 816 0 R 839 0 R] >> endobj @@ -15145,7 +15117,7 @@ endobj << /Type /Pages /Count 6 -/Parent 1569 0 R +/Parent 1571 0 R /Kids [866 0 R 900 0 R 928 0 R 947 0 R 975 0 R 992 0 R] >> endobj @@ -15153,7 +15125,7 @@ endobj << /Type /Pages /Count 6 -/Parent 1569 0 R +/Parent 1571 0 R /Kids [1021 0 R 1044 0 R 1061 0 R 1085 0 R 1109 0 R 1128 0 R] >> endobj @@ -15161,7 +15133,7 @@ endobj << /Type /Pages /Count 6 -/Parent 1570 0 R +/Parent 1572 0 R /Kids [1149 0 R 1178 0 R 1232 0 R 1239 0 R 1267 0 R 1310 0 R] >> endobj @@ -15169,50 +15141,50 @@ endobj << /Type /Pages /Count 6 -/Parent 1570 0 R -/Kids [1320 0 R 1328 0 R 1336 0 R 1358 0 R 1374 0 R 1384 0 R] +/Parent 1572 0 R +/Kids [1320 0 R 1328 0 R 1336 0 R 1358 0 R 1375 0 R 1386 0 R] >> endobj -1411 0 obj +1413 0 obj << /Type /Pages /Count 6 -/Parent 1570 0 R -/Kids [1406 0 R 1422 0 R 1442 0 R 1462 0 R 1474 0 R 1488 0 R] +/Parent 1572 0 R +/Kids [1408 0 R 1424 0 R 1444 0 R 1464 0 R 1476 0 R 1490 0 R] >> endobj -1523 0 obj +1525 0 obj << /Type /Pages /Count 2 -/Parent 1570 0 R -/Kids [1516 0 R 1525 0 R] +/Parent 1572 0 R +/Kids [1518 0 R 1527 0 R] >> endobj -1569 0 obj +1571 0 obj << /Type /Pages /Count 36 -/Parent 1571 0 R +/Parent 1573 0 R /Kids [230 0 R 535 0 R 636 0 R 714 0 R 878 0 R 1025 0 R] >> endobj -1570 0 obj +1572 0 obj << /Type /Pages /Count 20 -/Parent 1571 0 R -/Kids [1153 0 R 1326 0 R 1411 0 R 1523 0 R] +/Parent 1573 0 R +/Kids [1153 0 R 1326 0 R 1413 0 R 1525 0 R] >> endobj -1571 0 obj +1573 0 obj << /Type /Pages /Count 56 -/Kids [1569 0 R 1570 0 R] +/Kids [1571 0 R 1572 0 R] >> endobj -1572 0 obj +1574 0 obj << /Type /Outlines /First 6 0 R @@ -15362,7 +15334,7 @@ endobj << /Title 155 0 R /A 152 0 R -/Parent 1572 0 R +/Parent 1574 0 R /Prev 130 0 R /First 158 0 R /Last 206 0 R @@ -15417,7 +15389,7 @@ endobj << /Title 131 0 R /A 128 0 R -/Parent 1572 0 R +/Parent 1574 0 R /Prev 98 0 R /Next 154 0 R /First 134 0 R @@ -15491,7 +15463,7 @@ endobj << /Title 99 0 R /A 96 0 R -/Parent 1572 0 R +/Parent 1574 0 R /Prev 54 0 R /Next 130 0 R /First 102 0 R @@ -15591,7 +15563,7 @@ endobj << /Title 55 0 R /A 52 0 R -/Parent 1572 0 R +/Parent 1574 0 R /Prev 6 0 R /Next 98 0 R /First 58 0 R @@ -15702,746 +15674,752 @@ endobj << /Title 7 0 R /A 4 0 R -/Parent 1572 0 R +/Parent 1574 0 R /Next 54 0 R /First 10 0 R /Last 34 0 R /Count -3 >> endobj -1573 0 obj +1575 0 obj << /Names [(Doc-Start) 227 0 R (Item.1) 620 0 R (Item.2) 621 0 R (Item.3) 649 0 R (Item.4) 650 0 R (Item.5) 651 0 R] /Limits [(Doc-Start) (Item.5)] >> endobj -1574 0 obj +1576 0 obj << /Names [(chapter*.1) 473 0 R (chapter.1) 5 0 R (chapter.2) 53 0 R (chapter.3) 97 0 R (chapter.4) 129 0 R (chapter.5) 153 0 R] /Limits [(chapter*.1) (chapter.5)] >> endobj -1575 0 obj +1577 0 obj << /Names [(ex_step_by_step) 617 0 R (ex_step_by_step_exConclusion) 692 0 R (ex_step_by_step_exDataRate) 652 0 R (ex_step_by_step_exExampleCode) 628 0 R (ex_step_by_step_exHelloIaq) 629 0 R (ex_step_by_step_exMod) 653 0 R] /Limits [(ex_step_by_step) (ex_step_by_step_exMod)] >> endobj -1576 0 obj +1578 0 obj << /Names [(ex_step_by_step_exPrereq) 618 0 R (ex_step_by_step_exSelfHeating) 685 0 R (ex_step_by_step_exSetup) 622 0 R (ex_step_by_step_exSimMultSensors) 690 0 R (ex_step_by_step_exqULP) 691 0 R (faq) 707 0 R] /Limits [(ex_step_by_step_exPrereq) (faq)] >> endobj -1577 0 obj +1579 0 obj << /Names [(faq_faqErrorSensorControl) 936 0 R (faq_faqErrorSet) 873 0 R (faq_faqErrorUpdateSubscription) 791 0 R (faq_faqError_BSEC_E_CONFIG_CRCMISMATCH) 905 0 R (faq_faqError_BSEC_E_CONFIG_EMPTY) 908 0 R (faq_faqError_BSEC_E_CONFIG_FEATUREMISMATCH) 877 0 R] /Limits [(faq_faqErrorSensorControl) (faq_faqError_BSEC_E_CONFIG_FEATUREMISMATCH)] >> endobj -1578 0 obj +1580 0 obj << /Names [(faq_faqError_BSEC_E_CONFIG_INSUFFICIENTBUFFER) 934 0 R (faq_faqError_BSEC_E_CONFIG_INSUFFICIENTWORKBUFFER) 910 0 R (faq_faqError_BSEC_E_CONFIG_INVALIDSTRINGSIZE) 931 0 R (faq_faqError_BSEC_E_CONFIG_VERSIONMISMATCH) 874 0 R (faq_faqError_BSEC_E_DOSTEPS_DUPLICATEINPUT) 737 0 R (faq_faqError_BSEC_E_DOSTEPS_INVALIDINPUT) 712 0 R] /Limits [(faq_faqError_BSEC_E_CONFIG_INSUFFICIENTBUFFER) (faq_faqError_BSEC_E_DOSTEPS_INVALIDINPUT)] >> endobj -1579 0 obj +1581 0 obj << /Names [(faq_faqError_BSEC_E_DOSTEPS_VALUELIMITS) 735 0 R (faq_faqError_BSEC_E_SU_DUPLICATEGATE) 796 0 R (faq_faqError_BSEC_E_SU_GATECOUNTEXCEEDSARRAY) 821 0 R (faq_faqError_BSEC_E_SU_HIGHHEATERONDURATION) 844 0 R (faq_faqError_BSEC_E_SU_INVALIDSAMPLERATE) 819 0 R (faq_faqError_BSEC_E_SU_MULTGASSAMPLINTVL) 842 0 R] /Limits [(faq_faqError_BSEC_E_DOSTEPS_VALUELIMITS) (faq_faqError_BSEC_E_SU_MULTGASSAMPLINTVL)] >> endobj -1580 0 obj +1582 0 obj << /Names [(faq_faqError_BSEC_E_SU_SAMPLERATELIMITS) 794 0 R (faq_faqError_BSEC_E_SU_SAMPLINTVLINTEGERMULT) 823 0 R (faq_faqError_BSEC_E_SU_WRONGDATARATE) 792 0 R (faq_faqError_BSEC_I_DOSTEPS_NOOUTPUTSRETURNABLE) 761 0 R (faq_faqError_BSEC_I_SU_SUBSCRIBEDOUTPUTGATES) 848 0 R (faq_faqError_BSEC_W_DOSTEPS_EXCESSOUTPUTS) 764 0 R] /Limits [(faq_faqError_BSEC_E_SU_SAMPLERATELIMITS) (faq_faqError_BSEC_W_DOSTEPS_EXCESSOUTPUTS)] >> endobj -1581 0 obj +1583 0 obj << /Names [(faq_faqError_BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE) 767 0 R (faq_faqError_BSEC_W_SC_CALL_TIMING_VIOLATION) 937 0 R (faq_faqError_BSEC_W_SC_MODEXCEEDULPTIMELIMIT) 950 0 R (faq_faqError_BSEC_W_SC_MODINSUFFICIENTWAITTIME) 939 0 R (faq_faqError_BSEC_W_SU_MODINNOULP) 871 0 R (faq_faqError_BSEC_W_SU_UNKNOWNOUTPUTGATE) 846 0 R] /Limits [(faq_faqError_BSEC_W_DOSTEPS_TSINTRADIFFOUTOFRANGE) (faq_faqError_BSEC_W_SU_UNKNOWNOUTPUTGATE)] >> endobj -1582 0 obj +1584 0 obj << /Names [(faq_faqErrors) 710 0 R (faq_faqErrorsDoSteps) 711 0 R (faq_faqNoOutput) 708 0 R (faq_faqOutputZero) 709 0 R (figure.1.1) 598 0 R (group__bsec__interface) 978 0 R] /Limits [(faq_faqErrors) (group__bsec__interface)] >> endobj -1583 0 obj +1585 0 obj << /Names [(group__bsec__interface_ga109bf6e051d8635725da5bedeecf9eb2) 1346 0 R (group__bsec__interface_ga157748484a31501acfeee3df656adf54) 630 0 R (group__bsec__interface_ga216b6f4807227a2c6a183aaa9a8b8d7c) 1182 0 R (group__bsec__interface_ga339df4596b1c0e02eede5d54aa0f2858) 642 0 R (group__bsec__interface_ga49210a8ceb36d8610075b9220a0cdec6) 601 0 R (group__bsec__interface_ga51bcd13812ea62b35749284385a72f98) 536 0 R] /Limits [(group__bsec__interface_ga109bf6e051d8635725da5bedeecf9eb2) (group__bsec__interface_ga51bcd13812ea62b35749284385a72f98)] >> endobj -1584 0 obj +1586 0 obj << /Names [(group__bsec__interface_ga5e4d504611e1c4a0219861bbcf2ad650) 739 0 R (group__bsec__interface_ga6c18af8c9be0813f7d8e3547e58428db) 678 0 R (group__bsec__interface_ga70e68dbe60e2ba462537540d60192a2e) 882 0 R (group__bsec__interface_ga78ceba2853489683f274831b41460d3e) 1348 0 R (group__bsec__interface_ga7a53a20ee206f9b4c30c1d63395b3c49) 1371 0 R (group__bsec__interface_ga832388c889417ed197609d9965625bfe) 770 0 R] /Limits [(group__bsec__interface_ga5e4d504611e1c4a0219861bbcf2ad650) (group__bsec__interface_ga832388c889417ed197609d9965625bfe)] >> endobj -1585 0 obj +1587 0 obj << /Names [(group__bsec__interface_ga847070d3ecfa970cb2f716a2d11fe219) 674 0 R (group__bsec__interface_ga853243e7f08cc25be117fca5c8216d99) 1049 0 R (group__bsec__interface_ga8798390d842b820e79e9cbf8ba4d516e) 916 0 R (group__bsec__interface_ga8967694b8e412412977488e3e6fdb3ed) 1362 0 R (group__bsec__interface_ga91d06ad8cd57ceae529b66dd30ca4d8c) 715 0 R (group__bsec__interface_ga9de59ebc6a2504f15ba51d6d983faae8) 516 0 R] /Limits [(group__bsec__interface_ga847070d3ecfa970cb2f716a2d11fe219) (group__bsec__interface_ga9de59ebc6a2504f15ba51d6d983faae8)] >> endobj -1586 0 obj -<< -/Names [(group__bsec__interface_ga9e190b85f103d75ede9477227567e799) 1364 0 R (group__bsec__interface_gaa8bb29e07b5b96d6f576962aef094466) 1369 0 R (group__bsec__interface_gab2122fa3909f67a2c786ecd2d8993977) 1068 0 R (group__bsec__interface_gac182d75bb2ca95c32ba4b98a136ad081) 1381 0 R (group__bsec__interface_gac4726411862aa2d383e3d3b9ca279a5d) 518 0 R (group__bsec__interface_gac79a471c6e20fd8c17577f6f69a9469f) 517 0 R] -/Limits [(group__bsec__interface_ga9e190b85f103d75ede9477227567e799) (group__bsec__interface_gac79a471c6e20fd8c17577f6f69a9469f)] ->> -endobj -1587 0 obj -<< -/Names [(group__bsec__interface_gacf6a5816306dfc1e3c0b26a6d459fc71) 654 0 R (group__bsec__interface_gad8f5b300b8cf00c73d837660a05e0507) 1367 0 R (group__bsec__interface_gae89eedb131288b72c267c02ec9dea8e5) 1089 0 R (group__bsec__interface_gae8fc6d614d6a40f0088262dccbb960dc) 883 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a06af666972edcebef3302d015f1d56c5) 675 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a0a7f6e18d053c4af5f26f3852ef6ae14) 771 0 R] -/Limits [(group__bsec__interface_gacf6a5816306dfc1e3c0b26a6d459fc71) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a0a7f6e18d053c4af5f26f3852ef6ae14)] ->> -endobj 1588 0 obj << -/Names [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a178d85d77cf448057897e9b0e0932e33) 800 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a17bf2f98e8c59e29a8eda42c692e5b3d) 716 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a1ba36727b09433f1ae925646864d8a61) 826 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a2175fa185bbcaafb28b5c73ca8ff2394) 825 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a360b54bd3d53b377010d3afa29e04b89) 1243 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a3975b1dfa3c35829ce97814e04c143ce) 941 0 R] -/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a178d85d77cf448057897e9b0e0932e33) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a3975b1dfa3c35829ce97814e04c143ce)] +/Names [(group__bsec__interface_ga9e190b85f103d75ede9477227567e799) 1364 0 R (group__bsec__interface_gaa77a59249421277ab2fe8fbb2028eb99) 1373 0 R (group__bsec__interface_gaa8bb29e07b5b96d6f576962aef094466) 1369 0 R (group__bsec__interface_gab2122fa3909f67a2c786ecd2d8993977) 1068 0 R (group__bsec__interface_gac182d75bb2ca95c32ba4b98a136ad081) 1383 0 R (group__bsec__interface_gac4726411862aa2d383e3d3b9ca279a5d) 518 0 R] +/Limits [(group__bsec__interface_ga9e190b85f103d75ede9477227567e799) (group__bsec__interface_gac4726411862aa2d383e3d3b9ca279a5d)] >> endobj 1589 0 obj << -/Names [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a465d9fc420b12cfe3d24e937c5e5f110) 798 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a5946f4a20c9ba0cd83fed96ce3103c06) 742 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a5fa05dbfcae3caa309d9f62422eb61f3) 1242 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a6d707845ea3200a1a45726c2700333e5) 772 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a76ee5462e14060fcc889bd889b6f7b3c) 914 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a7f2cea23dbdaeddb2d91d861c608f239) 879 0 R] -/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a465d9fc420b12cfe3d24e937c5e5f110) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a7f2cea23dbdaeddb2d91d861c608f239)] +/Names [(group__bsec__interface_gac79a471c6e20fd8c17577f6f69a9469f) 517 0 R (group__bsec__interface_gacf6a5816306dfc1e3c0b26a6d459fc71) 654 0 R (group__bsec__interface_gad8f5b300b8cf00c73d837660a05e0507) 1367 0 R (group__bsec__interface_gae89eedb131288b72c267c02ec9dea8e5) 1089 0 R (group__bsec__interface_gae8fc6d614d6a40f0088262dccbb960dc) 883 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a06af666972edcebef3302d015f1d56c5) 675 0 R] +/Limits [(group__bsec__interface_gac79a471c6e20fd8c17577f6f69a9469f) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a06af666972edcebef3302d015f1d56c5)] >> endobj 1590 0 obj << -/Names [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a81fd5b4436be253e0ef3ebdf51b3d193) 740 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a87428d7a4a5d52e48af8db92ab71c83e) 880 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a89e2eec8486c2880912af108bbed3593) 913 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a8d7a8938ef9616b935094ed223122914) 1244 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a978a12de4397b9c0814e07650f8a1b46) 1245 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa1a59666f0af5463087f528473d4ff8c) 827 0 R] -/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a81fd5b4436be253e0ef3ebdf51b3d193) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa1a59666f0af5463087f528473d4ff8c)] +/Names [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a0a7f6e18d053c4af5f26f3852ef6ae14) 771 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a178d85d77cf448057897e9b0e0932e33) 800 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a17bf2f98e8c59e29a8eda42c692e5b3d) 716 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a1ba36727b09433f1ae925646864d8a61) 826 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a2175fa185bbcaafb28b5c73ca8ff2394) 825 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a360b54bd3d53b377010d3afa29e04b89) 1243 0 R] +/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a0a7f6e18d053c4af5f26f3852ef6ae14) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a360b54bd3d53b377010d3afa29e04b89)] >> endobj 1591 0 obj << -/Names [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa238cfe9b905deda6f1823ca32378f91) 944 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa5de81322b446f028934aa30c4826610) 799 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ab5356ac211454109eac007fcc458a6dd) 915 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ab78d6a66fc7a4205a6caf69ce4f161e4) 849 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ab810ba8e0fc4425c37aa460e57dc8129) 850 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ab87b5a5abeadc975488850bece3dbf84) 769 0 R] -/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa238cfe9b905deda6f1823ca32378f91) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ab87b5a5abeadc975488850bece3dbf84)] +/Names [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a3975b1dfa3c35829ce97814e04c143ce) 941 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a465d9fc420b12cfe3d24e937c5e5f110) 798 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a5946f4a20c9ba0cd83fed96ce3103c06) 742 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a5fa05dbfcae3caa309d9f62422eb61f3) 1242 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a6d707845ea3200a1a45726c2700333e5) 772 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a76ee5462e14060fcc889bd889b6f7b3c) 914 0 R] +/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a3975b1dfa3c35829ce97814e04c143ce) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a76ee5462e14060fcc889bd889b6f7b3c)] >> endobj 1592 0 obj << -/Names [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ac2600415df086d1a9b36105ac29396de) 881 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ac2eca8b900ce91ee50004c549a409024) 942 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ac5899ebab7738c4c99b19ad9d934f8d1) 851 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ada34397de8a8e88ad72e8546748866cd) 943 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ae5d8b5de70152c09b4153bcb41997ee7) 912 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ae8e920ecde96d7d79b8962da38233880) 952 0 R] -/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ac2600415df086d1a9b36105ac29396de) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ae8e920ecde96d7d79b8962da38233880)] +/Names [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a7f2cea23dbdaeddb2d91d861c608f239) 879 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a81fd5b4436be253e0ef3ebdf51b3d193) 740 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a87428d7a4a5d52e48af8db92ab71c83e) 880 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a89e2eec8486c2880912af108bbed3593) 913 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a8d7a8938ef9616b935094ed223122914) 1244 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a978a12de4397b9c0814e07650f8a1b46) 1245 0 R] +/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a7f2cea23dbdaeddb2d91d861c608f239) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a978a12de4397b9c0814e07650f8a1b46)] >> endobj 1593 0 obj << -/Names [(group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650a161b8c7ebab8fcea5590d37295d31b35) 1315 0 R (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650a381b968290256e77d50c4f7e92bfb27c) 1030 0 R (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650a3eb936f08a8f6f01d4c683a6ba0c9d3a) 741 0 R (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650a9202c1504b464b16f432da6a4dd582a2) 1272 0 R (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650aaf8083737123a5c4d012783ee10a522d) 1313 0 R (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650ad30626f0de1be98802cb5e50c8b67207) 1027 0 R] -/Limits [(group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650a161b8c7ebab8fcea5590d37295d31b35) (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650ad30626f0de1be98802cb5e50c8b67207)] +/Names [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa1a59666f0af5463087f528473d4ff8c) 827 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa238cfe9b905deda6f1823ca32378f91) 944 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa5de81322b446f028934aa30c4826610) 799 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ab5356ac211454109eac007fcc458a6dd) 915 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ab78d6a66fc7a4205a6caf69ce4f161e4) 849 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ab810ba8e0fc4425c37aa460e57dc8129) 850 0 R] +/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa1a59666f0af5463087f528473d4ff8c) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ab810ba8e0fc4425c37aa460e57dc8129)] >> endobj 1594 0 obj << -/Names [(group__bsec__interface_gga832388c889417ed197609d9965625bfea134c7c7f7bd544e304209368ec72467a) 1324 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea1369c4abd0a13602b197dfc94ae6ff7d) 1325 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea1aac5358fbe12702647de81cacd6d062) 590 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea1c0eee38a61b05c5239c871f9cdc85a4) 588 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea2368e219ebbce4e1ede7209486283a6e) 586 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea4e05ab48912e70486351f5199910fcb9) 587 0 R] -/Limits [(group__bsec__interface_gga832388c889417ed197609d9965625bfea134c7c7f7bd544e304209368ec72467a) (group__bsec__interface_gga832388c889417ed197609d9965625bfea4e05ab48912e70486351f5199910fcb9)] +/Names [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ab87b5a5abeadc975488850bece3dbf84) 769 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ac2600415df086d1a9b36105ac29396de) 881 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ac2eca8b900ce91ee50004c549a409024) 942 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ac5899ebab7738c4c99b19ad9d934f8d1) 851 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ada34397de8a8e88ad72e8546748866cd) 943 0 R (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ae5d8b5de70152c09b4153bcb41997ee7) 912 0 R] +/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ab87b5a5abeadc975488850bece3dbf84) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ae5d8b5de70152c09b4153bcb41997ee7)] >> endobj 1595 0 obj << -/Names [(group__bsec__interface_gga832388c889417ed197609d9965625bfea5f42ad42c6bb71627b5ce91d4c410985) 582 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea64d14f069c838de2d2c1f3f436ef6108) 585 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea684dc07fef8c1723e60211068365b30a) 1323 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea78b917ecbffc8eac6875644c4136a26d) 1342 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea792b0fbeffceea19513cc0bd31ce7ef7) 583 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea9fe6dbe27991e3f9f1a444c40b30af3d) 589 0 R] -/Limits [(group__bsec__interface_gga832388c889417ed197609d9965625bfea5f42ad42c6bb71627b5ce91d4c410985) (group__bsec__interface_gga832388c889417ed197609d9965625bfea9fe6dbe27991e3f9f1a444c40b30af3d)] +/Names [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ae8e920ecde96d7d79b8962da38233880) 952 0 R (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650a161b8c7ebab8fcea5590d37295d31b35) 1315 0 R (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650a381b968290256e77d50c4f7e92bfb27c) 1030 0 R (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650a3eb936f08a8f6f01d4c683a6ba0c9d3a) 741 0 R (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650a9202c1504b464b16f432da6a4dd582a2) 1272 0 R (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650aaf8083737123a5c4d012783ee10a522d) 1313 0 R] +/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858ae8e920ecde96d7d79b8962da38233880) (group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650aaf8083737123a5c4d012783ee10a522d)] >> endobj 1596 0 obj << -/Names [(group__bsec__interface_gga832388c889417ed197609d9965625bfeab9d6e7e5bb1c5f99d339a649d588b3cc) 584 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfeaf2cfe69583f70b1196660122ab5a94b6) 1341 0 R (index) 494 0 R (index_intguideBSECConfiguration) 515 0 R (index_intguideBSECSolutions) 512 0 R (index_intguideLibrary) 500 0 R] -/Limits [(group__bsec__interface_gga832388c889417ed197609d9965625bfeab9d6e7e5bb1c5f99d339a649d588b3cc) (index_intguideLibrary)] +/Names [(group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650ad30626f0de1be98802cb5e50c8b67207) 1027 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea134c7c7f7bd544e304209368ec72467a) 1324 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea1369c4abd0a13602b197dfc94ae6ff7d) 1325 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea1aac5358fbe12702647de81cacd6d062) 590 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea1c0eee38a61b05c5239c871f9cdc85a4) 588 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea2368e219ebbce4e1ede7209486283a6e) 586 0 R] +/Limits [(group__bsec__interface_gga5e4d504611e1c4a0219861bbcf2ad650ad30626f0de1be98802cb5e50c8b67207) (group__bsec__interface_gga832388c889417ed197609d9965625bfea2368e219ebbce4e1ede7209486283a6e)] >> endobj 1597 0 obj << -/Names [(index_intguideLibraryOutputs) 575 0 R (index_intguideOverviewSensors) 495 0 R (index_intguideQuickintroCodeBuild) 606 0 R (index_intguideRequirements) 579 0 R (index_intguideRequirementsFramework) 581 0 R (index_intguideRequirementsHardware) 580 0 R] -/Limits [(index_intguideLibraryOutputs) (index_intguideRequirementsHardware)] +/Names [(group__bsec__interface_gga832388c889417ed197609d9965625bfea4e05ab48912e70486351f5199910fcb9) 587 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea5f42ad42c6bb71627b5ce91d4c410985) 582 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea64d14f069c838de2d2c1f3f436ef6108) 585 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea684dc07fef8c1723e60211068365b30a) 1323 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea78b917ecbffc8eac6875644c4136a26d) 1342 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfea792b0fbeffceea19513cc0bd31ce7ef7) 583 0 R] +/Limits [(group__bsec__interface_gga832388c889417ed197609d9965625bfea4e05ab48912e70486351f5199910fcb9) (group__bsec__interface_gga832388c889417ed197609d9965625bfea792b0fbeffceea19513cc0bd31ce7ef7)] >> endobj 1598 0 obj << -/Names [(index_intguideRequirementsInputs) 599 0 R (index_intguideSolutionKeyfeature) 533 0 R (page.1) 225 0 R (page.10) 605 0 R (page.11) 616 0 R (page.12) 627 0 R] -/Limits [(index_intguideRequirementsInputs) (page.12)] +/Names [(group__bsec__interface_gga832388c889417ed197609d9965625bfea9fe6dbe27991e3f9f1a444c40b30af3d) 589 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfeab9d6e7e5bb1c5f99d339a649d588b3cc) 584 0 R (group__bsec__interface_gga832388c889417ed197609d9965625bfeaf2cfe69583f70b1196660122ab5a94b6) 1341 0 R (index) 494 0 R (index_intguideBSECConfiguration) 515 0 R (index_intguideBSECSolutions) 512 0 R] +/Limits [(group__bsec__interface_gga832388c889417ed197609d9965625bfea9fe6dbe27991e3f9f1a444c40b30af3d) (index_intguideBSECSolutions)] >> endobj 1599 0 obj << -/Names [(page.13) 635 0 R (page.14) 641 0 R (page.15) 647 0 R (page.16) 672 0 R (page.17) 684 0 R (page.18) 689 0 R] -/Limits [(page.13) (page.18)] +/Names [(index_intguideLibrary) 500 0 R (index_intguideLibraryOutputs) 575 0 R (index_intguideOverviewSensors) 495 0 R (index_intguideQuickintroCodeBuild) 606 0 R (index_intguideRequirements) 579 0 R (index_intguideRequirementsFramework) 581 0 R] +/Limits [(index_intguideLibrary) (index_intguideRequirementsFramework)] >> endobj 1600 0 obj << -/Names [(page.19) 706 0 R (page.2) 427 0 R (page.20) 733 0 R (page.21) 760 0 R (page.22) 790 0 R (page.23) 818 0 R] -/Limits [(page.19) (page.23)] +/Names [(index_intguideRequirementsHardware) 580 0 R (index_intguideRequirementsInputs) 599 0 R (index_intguideSolutionKeyfeature) 533 0 R (page.1) 225 0 R (page.10) 605 0 R (page.11) 616 0 R] +/Limits [(index_intguideRequirementsHardware) (page.11)] >> endobj 1601 0 obj << -/Names [(page.24) 841 0 R (page.25) 868 0 R (page.26) 902 0 R (page.27) 930 0 R (page.28) 949 0 R (page.29) 977 0 R] -/Limits [(page.24) (page.29)] +/Names [(page.12) 627 0 R (page.13) 635 0 R (page.14) 641 0 R (page.15) 647 0 R (page.16) 672 0 R (page.17) 684 0 R] +/Limits [(page.12) (page.17)] >> endobj 1602 0 obj << -/Names [(page.3) 472 0 R (page.30) 994 0 R (page.31) 1023 0 R (page.32) 1046 0 R (page.33) 1063 0 R (page.34) 1087 0 R] -/Limits [(page.3) (page.34)] +/Names [(page.18) 689 0 R (page.19) 706 0 R (page.2) 427 0 R (page.20) 733 0 R (page.21) 760 0 R (page.22) 790 0 R] +/Limits [(page.18) (page.22)] >> endobj 1603 0 obj << -/Names [(page.35) 1111 0 R (page.36) 1130 0 R (page.37) 1151 0 R (page.38) 1180 0 R (page.39) 1234 0 R (page.4) 489 0 R] -/Limits [(page.35) (page.4)] +/Names [(page.23) 818 0 R (page.24) 841 0 R (page.25) 868 0 R (page.26) 902 0 R (page.27) 930 0 R (page.28) 949 0 R] +/Limits [(page.23) (page.28)] >> endobj 1604 0 obj << -/Names [(page.40) 1241 0 R (page.41) 1269 0 R (page.42) 1312 0 R (page.43) 1322 0 R (page.44) 1330 0 R (page.45) 1338 0 R] -/Limits [(page.40) (page.45)] +/Names [(page.29) 977 0 R (page.3) 472 0 R (page.30) 994 0 R (page.31) 1023 0 R (page.32) 1046 0 R (page.33) 1063 0 R] +/Limits [(page.29) (page.33)] >> endobj 1605 0 obj << -/Names [(page.46) 1360 0 R (page.47) 1376 0 R (page.48) 1386 0 R (page.49) 1408 0 R (page.5) 493 0 R (page.50) 1424 0 R] -/Limits [(page.46) (page.50)] +/Names [(page.34) 1087 0 R (page.35) 1111 0 R (page.36) 1130 0 R (page.37) 1151 0 R (page.38) 1180 0 R (page.39) 1234 0 R] +/Limits [(page.34) (page.39)] >> endobj 1606 0 obj << -/Names [(page.51) 1444 0 R (page.52) 1464 0 R (page.53) 1476 0 R (page.54) 1490 0 R (page.55) 1518 0 R (page.56) 1527 0 R] -/Limits [(page.51) (page.56)] +/Names [(page.4) 489 0 R (page.40) 1241 0 R (page.41) 1269 0 R (page.42) 1312 0 R (page.43) 1322 0 R (page.44) 1330 0 R] +/Limits [(page.4) (page.44)] >> endobj 1607 0 obj << -/Names [(page.6) 508 0 R (page.7) 529 0 R (page.8) 573 0 R (page.9) 596 0 R (section*.10) 984 0 R (section*.11) 1409 0 R] -/Limits [(page.6) (section*.11)] +/Names [(page.45) 1338 0 R (page.46) 1360 0 R (page.47) 1377 0 R (page.48) 1388 0 R (page.49) 1410 0 R (page.5) 493 0 R] +/Limits [(page.45) (page.5)] >> endobj 1608 0 obj << -/Names [(section*.12) 1447 0 R (section*.13) 1468 0 R (section*.14) 1495 0 R (section*.15) 1522 0 R (section*.2) 496 0 R (section*.3) 497 0 R] -/Limits [(section*.12) (section*.3)] +/Names [(page.50) 1426 0 R (page.51) 1446 0 R (page.52) 1466 0 R (page.53) 1478 0 R (page.54) 1492 0 R (page.55) 1520 0 R] +/Limits [(page.50) (page.55)] >> endobj 1609 0 obj << -/Names [(section*.4) 498 0 R (section*.5) 499 0 R (section*.6) 509 0 R (section*.7) 534 0 R (section*.8) 574 0 R (section*.9) 979 0 R] -/Limits [(section*.4) (section*.9)] +/Names [(page.56) 1529 0 R (page.6) 508 0 R (page.7) 529 0 R (page.8) 573 0 R (page.9) 596 0 R (section*.10) 984 0 R] +/Limits [(page.56) (section*.10)] >> endobj 1610 0 obj << -/Names [(section.1.1) 9 0 R (section.1.2) 13 0 R (section.1.3) 33 0 R (section.2.1) 57 0 R (section.2.10) 93 0 R (section.2.2) 61 0 R] -/Limits [(section.1.1) (section.2.2)] +/Names [(section*.11) 1411 0 R (section*.12) 1449 0 R (section*.13) 1470 0 R (section*.14) 1497 0 R (section*.15) 1524 0 R (section*.2) 496 0 R] +/Limits [(section*.11) (section*.2)] >> endobj 1611 0 obj << -/Names [(section.2.3) 65 0 R (section.2.4) 69 0 R (section.2.5) 73 0 R (section.2.6) 77 0 R (section.2.7) 81 0 R (section.2.8) 85 0 R] -/Limits [(section.2.3) (section.2.8)] +/Names [(section*.3) 497 0 R (section*.4) 498 0 R (section*.5) 499 0 R (section*.6) 509 0 R (section*.7) 534 0 R (section*.8) 574 0 R] +/Limits [(section*.3) (section*.8)] >> endobj 1612 0 obj << -/Names [(section.2.9) 89 0 R (section.3.1) 101 0 R (section.3.2) 105 0 R (section.3.3) 109 0 R (section.4.1) 133 0 R (section.5.1) 157 0 R] -/Limits [(section.2.9) (section.5.1)] +/Names [(section*.9) 979 0 R (section.1.1) 9 0 R (section.1.2) 13 0 R (section.1.3) 33 0 R (section.2.1) 57 0 R (section.2.10) 93 0 R] +/Limits [(section*.9) (section.2.10)] >> endobj 1613 0 obj << -/Names [(section.5.2) 169 0 R (section.5.3) 181 0 R (section.5.4) 193 0 R (section.5.5) 205 0 R (structbsec__bme__settings__t) 1116 0 R (structbsec__bme__settings__t_a300b00f9580b9af76d441cd4db8d7083) 1117 0 R] -/Limits [(section.5.2) (structbsec__bme__settings__t_a300b00f9580b9af76d441cd4db8d7083)] +/Names [(section.2.2) 61 0 R (section.2.3) 65 0 R (section.2.4) 69 0 R (section.2.5) 73 0 R (section.2.6) 77 0 R (section.2.7) 81 0 R] +/Limits [(section.2.2) (section.2.7)] >> endobj 1614 0 obj << -/Names [(structbsec__bme__settings__t_a4407b04a0d403a9fb35fd322999113a9) 1415 0 R (structbsec__bme__settings__t_a500cfa825fa7c6ead38eba7bf7b4b955) 1413 0 R (structbsec__bme__settings__t_a7984769929826a36f59e7b9dfd6e7447) 1418 0 R (structbsec__bme__settings__t_aa197109b334a2a443d9349812865bff1) 1412 0 R (structbsec__bme__settings__t_aa4a1eeae4e7fe44a8093a3862996fbac) 1419 0 R (structbsec__bme__settings__t_aecd99f57df2bc07663a7de83f877228e) 1416 0 R] -/Limits [(structbsec__bme__settings__t_a4407b04a0d403a9fb35fd322999113a9) (structbsec__bme__settings__t_aecd99f57df2bc07663a7de83f877228e)] +/Names [(section.2.8) 85 0 R (section.2.9) 89 0 R (section.3.1) 101 0 R (section.3.2) 105 0 R (section.3.3) 109 0 R (section.4.1) 133 0 R] +/Limits [(section.2.8) (section.4.1)] >> endobj 1615 0 obj << -/Names [(structbsec__bme__settings__t_aed0450820cd910e06e26fba04256bc24) 1417 0 R (structbsec__bme__settings__t_afc3ab51b88f259e5cb76c10ee0732e5b) 1414 0 R (structbsec__input__t) 999 0 R (structbsec__input__t_a000803d39a2be521f2b5e7017c31303b) 1028 0 R (structbsec__input__t_a90d515d57b274dfde74a281de469a3ad) 1029 0 R (structbsec__input__t_a916867811b65988853b69f729b91c262) 1026 0 R] -/Limits [(structbsec__bme__settings__t_aed0450820cd910e06e26fba04256bc24) (structbsec__input__t_a916867811b65988853b69f729b91c262)] +/Names [(section.5.1) 157 0 R (section.5.2) 169 0 R (section.5.3) 181 0 R (section.5.4) 193 0 R (section.5.5) 205 0 R (structbsec__bme__settings__t) 1116 0 R] +/Limits [(section.5.1) (structbsec__bme__settings__t)] >> endobj 1616 0 obj << -/Names [(structbsec__input__t_ab535651a26b2e2c44c83e441385e3def) 1449 0 R (structbsec__output__t) 1000 0 R (structbsec__output__t_a1a046572bcb85189df10c9ac8f362999) 1470 0 R (structbsec__output__t_a74a917725569b67eb14e78a34fa9c55d) 1469 0 R (structbsec__output__t_a91006cd8f20e88a5ff2b6ebfbecdeb95) 1471 0 R (structbsec__output__t_ab188da3e58d458f4b94a64379404da46) 1318 0 R] -/Limits [(structbsec__input__t_ab535651a26b2e2c44c83e441385e3def) (structbsec__output__t_ab188da3e58d458f4b94a64379404da46)] +/Names [(structbsec__bme__settings__t_a300b00f9580b9af76d441cd4db8d7083) 1117 0 R (structbsec__bme__settings__t_a4407b04a0d403a9fb35fd322999113a9) 1417 0 R (structbsec__bme__settings__t_a500cfa825fa7c6ead38eba7bf7b4b955) 1415 0 R (structbsec__bme__settings__t_a7984769929826a36f59e7b9dfd6e7447) 1420 0 R (structbsec__bme__settings__t_aa197109b334a2a443d9349812865bff1) 1414 0 R (structbsec__bme__settings__t_aa4a1eeae4e7fe44a8093a3862996fbac) 1421 0 R] +/Limits [(structbsec__bme__settings__t_a300b00f9580b9af76d441cd4db8d7083) (structbsec__bme__settings__t_aa4a1eeae4e7fe44a8093a3862996fbac)] >> endobj 1617 0 obj << -/Names [(structbsec__output__t_ac4e7ef20f713075472bc953efb13957f) 591 0 R (structbsec__sensor__configuration__t) 673 0 R (structbsec__sensor__configuration__t_a150ba3a737fb75f56052c60d55246ae4) 677 0 R (structbsec__sensor__configuration__t_a92665e4f2f3cd5237814488774c0f546) 676 0 R (structbsec__version__t) 1069 0 R (structbsec__version__t_a3d9b11a72027026f492a438342a2efbd) 1095 0 R] -/Limits [(structbsec__output__t_ac4e7ef20f713075472bc953efb13957f) (structbsec__version__t_a3d9b11a72027026f492a438342a2efbd)] +/Names [(structbsec__bme__settings__t_aecd99f57df2bc07663a7de83f877228e) 1418 0 R (structbsec__bme__settings__t_aed0450820cd910e06e26fba04256bc24) 1419 0 R (structbsec__bme__settings__t_afc3ab51b88f259e5cb76c10ee0732e5b) 1416 0 R (structbsec__input__t) 999 0 R (structbsec__input__t_a000803d39a2be521f2b5e7017c31303b) 1028 0 R (structbsec__input__t_a90d515d57b274dfde74a281de469a3ad) 1029 0 R] +/Limits [(structbsec__bme__settings__t_aecd99f57df2bc07663a7de83f877228e) (structbsec__input__t_a90d515d57b274dfde74a281de469a3ad)] >> endobj 1618 0 obj << -/Names [(structbsec__version__t_a5daac4534748c6f0be9f009273613b02) 1096 0 R (structbsec__version__t_a9d47d254d17740222791fa0f53c7ac52) 1094 0 R (structbsec__version__t_af823001b85e62b90279f9e6f3c478c23) 1093 0 R (subsection.1.2.1) 17 0 R (subsection.1.2.2) 21 0 R (subsection.1.2.3) 25 0 R] -/Limits [(structbsec__version__t_a5daac4534748c6f0be9f009273613b02) (subsection.1.2.3)] +/Names [(structbsec__input__t_a916867811b65988853b69f729b91c262) 1026 0 R (structbsec__input__t_ab535651a26b2e2c44c83e441385e3def) 1451 0 R (structbsec__output__t) 1000 0 R (structbsec__output__t_a1a046572bcb85189df10c9ac8f362999) 1472 0 R (structbsec__output__t_a74a917725569b67eb14e78a34fa9c55d) 1471 0 R (structbsec__output__t_a91006cd8f20e88a5ff2b6ebfbecdeb95) 1473 0 R] +/Limits [(structbsec__input__t_a916867811b65988853b69f729b91c262) (structbsec__output__t_a91006cd8f20e88a5ff2b6ebfbecdeb95)] >> endobj 1619 0 obj << -/Names [(subsection.1.2.4) 29 0 R (subsection.1.3.1) 37 0 R (subsection.1.3.2) 41 0 R (subsection.1.3.3) 45 0 R (subsection.1.3.4) 49 0 R (subsection.3.3.1) 113 0 R] -/Limits [(subsection.1.2.4) (subsection.3.3.1)] +/Names [(structbsec__output__t_ab188da3e58d458f4b94a64379404da46) 1318 0 R (structbsec__output__t_ac4e7ef20f713075472bc953efb13957f) 591 0 R (structbsec__sensor__configuration__t) 673 0 R (structbsec__sensor__configuration__t_a150ba3a737fb75f56052c60d55246ae4) 677 0 R (structbsec__sensor__configuration__t_a92665e4f2f3cd5237814488774c0f546) 676 0 R (structbsec__version__t) 1069 0 R] +/Limits [(structbsec__output__t_ab188da3e58d458f4b94a64379404da46) (structbsec__version__t)] >> endobj 1620 0 obj << -/Names [(subsection.3.3.2) 117 0 R (subsection.3.3.3) 121 0 R (subsection.3.3.4) 125 0 R (subsection.4.1.1) 137 0 R (subsection.4.1.2) 141 0 R (subsection.4.1.3) 145 0 R] -/Limits [(subsection.3.3.2) (subsection.4.1.3)] +/Names [(structbsec__version__t_a3d9b11a72027026f492a438342a2efbd) 1095 0 R (structbsec__version__t_a5daac4534748c6f0be9f009273613b02) 1096 0 R (structbsec__version__t_a9d47d254d17740222791fa0f53c7ac52) 1094 0 R (structbsec__version__t_af823001b85e62b90279f9e6f3c478c23) 1093 0 R (subsection.1.2.1) 17 0 R (subsection.1.2.2) 21 0 R] +/Limits [(structbsec__version__t_a3d9b11a72027026f492a438342a2efbd) (subsection.1.2.2)] >> endobj 1621 0 obj << -/Names [(subsection.4.1.4) 149 0 R (subsection.5.1.1) 161 0 R (subsection.5.1.2) 165 0 R (subsection.5.2.1) 173 0 R (subsection.5.2.2) 177 0 R (subsection.5.3.1) 185 0 R] -/Limits [(subsection.4.1.4) (subsection.5.3.1)] +/Names [(subsection.1.2.3) 25 0 R (subsection.1.2.4) 29 0 R (subsection.1.3.1) 37 0 R (subsection.1.3.2) 41 0 R (subsection.1.3.3) 45 0 R (subsection.1.3.4) 49 0 R] +/Limits [(subsection.1.2.3) (subsection.1.3.4)] >> endobj 1622 0 obj << -/Names [(subsection.5.3.2) 189 0 R (subsection.5.4.1) 197 0 R (subsection.5.4.2) 201 0 R (subsection.5.5.1) 209 0 R (subsection.5.5.2) 213 0 R (subsubsection.3.3.1.1) 713 0 R] -/Limits [(subsection.5.3.2) (subsubsection.3.3.1.1)] +/Names [(subsection.3.3.1) 113 0 R (subsection.3.3.2) 117 0 R (subsection.3.3.3) 121 0 R (subsection.3.3.4) 125 0 R (subsection.4.1.1) 137 0 R (subsection.4.1.2) 141 0 R] +/Limits [(subsection.3.3.1) (subsection.4.1.2)] >> endobj 1623 0 obj << -/Names [(subsubsection.3.3.1.2) 736 0 R (subsubsection.3.3.1.3) 738 0 R (subsubsection.3.3.1.4) 762 0 R (subsubsection.3.3.1.5) 765 0 R (subsubsection.3.3.1.6) 768 0 R (subsubsection.3.3.2.1) 793 0 R] -/Limits [(subsubsection.3.3.1.2) (subsubsection.3.3.2.1)] +/Names [(subsection.4.1.3) 145 0 R (subsection.4.1.4) 149 0 R (subsection.5.1.1) 161 0 R (subsection.5.1.2) 165 0 R (subsection.5.2.1) 173 0 R (subsection.5.2.2) 177 0 R] +/Limits [(subsection.4.1.3) (subsection.5.2.2)] >> endobj 1624 0 obj << -/Names [(subsubsection.3.3.2.10) 869 0 R (subsubsection.3.3.2.11) 872 0 R (subsubsection.3.3.2.2) 795 0 R (subsubsection.3.3.2.3) 797 0 R (subsubsection.3.3.2.4) 820 0 R (subsubsection.3.3.2.5) 822 0 R] -/Limits [(subsubsection.3.3.2.10) (subsubsection.3.3.2.5)] +/Names [(subsection.5.3.1) 185 0 R (subsection.5.3.2) 189 0 R (subsection.5.4.1) 197 0 R (subsection.5.4.2) 201 0 R (subsection.5.5.1) 209 0 R (subsection.5.5.2) 213 0 R] +/Limits [(subsection.5.3.1) (subsection.5.5.2)] >> endobj 1625 0 obj << -/Names [(subsubsection.3.3.2.6) 824 0 R (subsubsection.3.3.2.7) 843 0 R (subsubsection.3.3.2.8) 845 0 R (subsubsection.3.3.2.9) 847 0 R (subsubsection.3.3.3.1) 875 0 R (subsubsection.3.3.3.2) 903 0 R] -/Limits [(subsubsection.3.3.2.6) (subsubsection.3.3.3.2)] +/Names [(subsubsection.3.3.1.1) 713 0 R (subsubsection.3.3.1.2) 736 0 R (subsubsection.3.3.1.3) 738 0 R (subsubsection.3.3.1.4) 762 0 R (subsubsection.3.3.1.5) 765 0 R (subsubsection.3.3.1.6) 768 0 R] +/Limits [(subsubsection.3.3.1.1) (subsubsection.3.3.1.6)] >> endobj 1626 0 obj << -/Names [(subsubsection.3.3.3.3) 906 0 R (subsubsection.3.3.3.4) 909 0 R (subsubsection.3.3.3.5) 911 0 R (subsubsection.3.3.3.6) 932 0 R (subsubsection.3.3.3.7) 935 0 R (subsubsection.3.3.4.1) 938 0 R] -/Limits [(subsubsection.3.3.3.3) (subsubsection.3.3.4.1)] +/Names [(subsubsection.3.3.2.1) 793 0 R (subsubsection.3.3.2.10) 869 0 R (subsubsection.3.3.2.11) 872 0 R (subsubsection.3.3.2.2) 795 0 R (subsubsection.3.3.2.3) 797 0 R (subsubsection.3.3.2.4) 820 0 R] +/Limits [(subsubsection.3.3.2.1) (subsubsection.3.3.2.4)] >> endobj 1627 0 obj << -/Names [(subsubsection.3.3.4.2) 940 0 R (subsubsection.3.3.4.3) 951 0 R (subsubsection.4.1.2.1) 995 0 R (subsubsection.4.1.2.10) 1152 0 R (subsubsection.4.1.2.2) 1024 0 R (subsubsection.4.1.2.3) 1048 0 R] -/Limits [(subsubsection.3.3.4.2) (subsubsection.4.1.2.3)] +/Names [(subsubsection.3.3.2.5) 822 0 R (subsubsection.3.3.2.6) 824 0 R (subsubsection.3.3.2.7) 843 0 R (subsubsection.3.3.2.8) 845 0 R (subsubsection.3.3.2.9) 847 0 R (subsubsection.3.3.3.1) 875 0 R] +/Limits [(subsubsection.3.3.2.5) (subsubsection.3.3.3.1)] >> endobj 1628 0 obj << -/Names [(subsubsection.4.1.2.4) 1066 0 R (subsubsection.4.1.2.5) 1088 0 R (subsubsection.4.1.2.6) 1090 0 R (subsubsection.4.1.2.7) 1092 0 R (subsubsection.4.1.2.8) 1114 0 R (subsubsection.4.1.2.9) 1131 0 R] -/Limits [(subsubsection.4.1.2.4) (subsubsection.4.1.2.9)] +/Names [(subsubsection.3.3.3.2) 903 0 R (subsubsection.3.3.3.3) 906 0 R (subsubsection.3.3.3.4) 909 0 R (subsubsection.3.3.3.5) 911 0 R (subsubsection.3.3.3.6) 932 0 R (subsubsection.3.3.3.7) 935 0 R] +/Limits [(subsubsection.3.3.3.2) (subsubsection.3.3.3.7)] >> endobj 1629 0 obj << -/Names [(subsubsection.4.1.3.1) 1235 0 R (subsubsection.4.1.3.2) 1270 0 R (subsubsection.4.1.3.3) 1316 0 R (subsubsection.4.1.4.1) 1343 0 R (subsubsection.4.1.4.10) 1372 0 R (subsubsection.4.1.4.11) 1377 0 R] -/Limits [(subsubsection.4.1.3.1) (subsubsection.4.1.4.11)] +/Names [(subsubsection.3.3.4.1) 938 0 R (subsubsection.3.3.4.2) 940 0 R (subsubsection.3.3.4.3) 951 0 R (subsubsection.4.1.2.1) 995 0 R (subsubsection.4.1.2.10) 1152 0 R (subsubsection.4.1.2.2) 1024 0 R] +/Limits [(subsubsection.3.3.4.1) (subsubsection.4.1.2.2)] >> endobj 1630 0 obj << -/Names [(subsubsection.4.1.4.12) 1378 0 R (subsubsection.4.1.4.13) 1379 0 R (subsubsection.4.1.4.14) 1380 0 R (subsubsection.4.1.4.15) 1382 0 R (subsubsection.4.1.4.2) 1344 0 R (subsubsection.4.1.4.3) 1345 0 R] -/Limits [(subsubsection.4.1.4.12) (subsubsection.4.1.4.3)] +/Names [(subsubsection.4.1.2.3) 1048 0 R (subsubsection.4.1.2.4) 1066 0 R (subsubsection.4.1.2.5) 1088 0 R (subsubsection.4.1.2.6) 1090 0 R (subsubsection.4.1.2.7) 1092 0 R (subsubsection.4.1.2.8) 1114 0 R] +/Limits [(subsubsection.4.1.2.3) (subsubsection.4.1.2.8)] >> endobj 1631 0 obj << -/Names [(subsubsection.4.1.4.4) 1347 0 R (subsubsection.4.1.4.5) 1361 0 R (subsubsection.4.1.4.6) 1363 0 R (subsubsection.4.1.4.7) 1365 0 R (subsubsection.4.1.4.8) 1368 0 R (subsubsection.4.1.4.9) 1370 0 R] -/Limits [(subsubsection.4.1.4.4) (subsubsection.4.1.4.9)] +/Names [(subsubsection.4.1.2.9) 1131 0 R (subsubsection.4.1.3.1) 1235 0 R (subsubsection.4.1.3.2) 1270 0 R (subsubsection.4.1.3.3) 1316 0 R (subsubsection.4.1.4.1) 1343 0 R (subsubsection.4.1.4.10) 1372 0 R] +/Limits [(subsubsection.4.1.2.9) (subsubsection.4.1.4.10)] >> endobj 1632 0 obj << -/Names [(subsubsection.5.1.2.1) 1425 0 R (subsubsection.5.1.2.2) 1426 0 R (subsubsection.5.1.2.3) 1427 0 R (subsubsection.5.1.2.4) 1428 0 R (subsubsection.5.1.2.5) 1429 0 R (subsubsection.5.1.2.6) 1430 0 R] -/Limits [(subsubsection.5.1.2.1) (subsubsection.5.1.2.6)] +/Names [(subsubsection.4.1.4.11) 1378 0 R (subsubsection.4.1.4.12) 1379 0 R (subsubsection.4.1.4.13) 1380 0 R (subsubsection.4.1.4.14) 1381 0 R (subsubsection.4.1.4.15) 1382 0 R (subsubsection.4.1.4.16) 1384 0 R] +/Limits [(subsubsection.4.1.4.11) (subsubsection.4.1.4.16)] >> endobj 1633 0 obj << -/Names [(subsubsection.5.1.2.7) 1431 0 R (subsubsection.5.1.2.8) 1445 0 R (subsubsection.5.1.2.9) 1446 0 R (subsubsection.5.2.2.1) 1448 0 R (subsubsection.5.2.2.2) 1465 0 R (subsubsection.5.2.2.3) 1466 0 R] -/Limits [(subsubsection.5.1.2.7) (subsubsection.5.2.2.3)] +/Names [(subsubsection.4.1.4.2) 1344 0 R (subsubsection.4.1.4.3) 1345 0 R (subsubsection.4.1.4.4) 1347 0 R (subsubsection.4.1.4.5) 1361 0 R (subsubsection.4.1.4.6) 1363 0 R (subsubsection.4.1.4.7) 1365 0 R] +/Limits [(subsubsection.4.1.4.2) (subsubsection.4.1.4.7)] >> endobj 1634 0 obj << -/Names [(subsubsection.5.2.2.4) 1467 0 R (subsubsection.5.3.2.1) 1477 0 R (subsubsection.5.3.2.2) 1491 0 R (subsubsection.5.3.2.3) 1492 0 R (subsubsection.5.3.2.4) 1493 0 R (subsubsection.5.3.2.5) 1494 0 R] -/Limits [(subsubsection.5.2.2.4) (subsubsection.5.3.2.5)] +/Names [(subsubsection.4.1.4.8) 1368 0 R (subsubsection.4.1.4.9) 1370 0 R (subsubsection.5.1.2.1) 1427 0 R (subsubsection.5.1.2.2) 1428 0 R (subsubsection.5.1.2.3) 1429 0 R (subsubsection.5.1.2.4) 1430 0 R] +/Limits [(subsubsection.4.1.4.8) (subsubsection.5.1.2.4)] >> endobj 1635 0 obj << -/Names [(subsubsection.5.4.2.1) 1519 0 R (subsubsection.5.4.2.2) 1520 0 R (subsubsection.5.5.2.1) 1528 0 R (subsubsection.5.5.2.2) 1529 0 R (subsubsection.5.5.2.3) 1530 0 R (subsubsection.5.5.2.4) 1531 0 R] -/Limits [(subsubsection.5.4.2.1) (subsubsection.5.5.2.4)] +/Names [(subsubsection.5.1.2.5) 1431 0 R (subsubsection.5.1.2.6) 1432 0 R (subsubsection.5.1.2.7) 1433 0 R (subsubsection.5.1.2.8) 1447 0 R (subsubsection.5.1.2.9) 1448 0 R (subsubsection.5.2.2.1) 1450 0 R] +/Limits [(subsubsection.5.1.2.5) (subsubsection.5.2.2.1)] >> endobj 1636 0 obj << -/Names [(table.1.1) 513 0 R (table.1.2) 530 0 R (table.1.3) 576 0 R (table.1.4) 607 0 R (table.4.1) 980 0 R (table.4.10) 1113 0 R] -/Limits [(table.1.1) (table.4.10)] +/Names [(subsubsection.5.2.2.2) 1467 0 R (subsubsection.5.2.2.3) 1468 0 R (subsubsection.5.2.2.4) 1469 0 R (subsubsection.5.3.2.1) 1479 0 R (subsubsection.5.3.2.2) 1493 0 R (subsubsection.5.3.2.3) 1494 0 R] +/Limits [(subsubsection.5.2.2.2) (subsubsection.5.3.2.3)] >> endobj 1637 0 obj << -/Names [(table.4.11) 1115 0 R (table.4.12) 1132 0 R (table.4.13) 1181 0 R (table.4.14) 1236 0 R (table.4.15) 1271 0 R (table.4.16) 1317 0 R] -/Limits [(table.4.11) (table.4.16)] +/Names [(subsubsection.5.3.2.4) 1495 0 R (subsubsection.5.3.2.5) 1496 0 R (subsubsection.5.4.2.1) 1521 0 R (subsubsection.5.4.2.2) 1522 0 R (subsubsection.5.5.2.1) 1530 0 R (subsubsection.5.5.2.2) 1531 0 R] +/Limits [(subsubsection.5.3.2.4) (subsubsection.5.5.2.2)] >> endobj 1638 0 obj << -/Names [(table.4.2) 981 0 R (table.4.3) 982 0 R (table.4.4) 983 0 R (table.4.5) 998 0 R (table.4.6) 1047 0 R (table.4.7) 1065 0 R] -/Limits [(table.4.2) (table.4.7)] +/Names [(subsubsection.5.5.2.3) 1532 0 R (subsubsection.5.5.2.4) 1533 0 R (table.1.1) 513 0 R (table.1.2) 530 0 R (table.1.3) 576 0 R (table.1.4) 607 0 R] +/Limits [(subsubsection.5.5.2.3) (table.1.4)] >> endobj 1639 0 obj << -/Names [(table.4.8) 1067 0 R (table.4.9) 1091 0 R (table.5.1) 1478 0 R (table.5.2) 1479 0 R (table.5.3) 1480 0 R (table.5.4) 1521 0 R] -/Limits [(table.4.8) (table.5.4)] +/Names [(table.4.1) 980 0 R (table.4.10) 1113 0 R (table.4.11) 1115 0 R (table.4.12) 1132 0 R (table.4.13) 1181 0 R (table.4.14) 1236 0 R] +/Limits [(table.4.1) (table.4.14)] >> endobj 1640 0 obj << -/Kids [1573 0 R 1574 0 R 1575 0 R 1576 0 R 1577 0 R 1578 0 R] -/Limits [(Doc-Start) (faq_faqError_BSEC_E_DOSTEPS_INVALIDINPUT)] +/Names [(table.4.15) 1271 0 R (table.4.16) 1317 0 R (table.4.2) 981 0 R (table.4.3) 982 0 R (table.4.4) 983 0 R (table.4.5) 998 0 R] +/Limits [(table.4.15) (table.4.5)] >> endobj 1641 0 obj << -/Kids [1579 0 R 1580 0 R 1581 0 R 1582 0 R 1583 0 R 1584 0 R] -/Limits [(faq_faqError_BSEC_E_DOSTEPS_VALUELIMITS) (group__bsec__interface_ga832388c889417ed197609d9965625bfe)] +/Names [(table.4.6) 1047 0 R (table.4.7) 1065 0 R (table.4.8) 1067 0 R (table.4.9) 1091 0 R (table.5.1) 1480 0 R (table.5.2) 1481 0 R] +/Limits [(table.4.6) (table.5.2)] >> endobj 1642 0 obj << -/Kids [1585 0 R 1586 0 R 1587 0 R 1588 0 R 1589 0 R 1590 0 R] -/Limits [(group__bsec__interface_ga847070d3ecfa970cb2f716a2d11fe219) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa1a59666f0af5463087f528473d4ff8c)] +/Names [(table.5.3) 1482 0 R (table.5.4) 1523 0 R] +/Limits [(table.5.3) (table.5.4)] >> endobj 1643 0 obj << -/Kids [1591 0 R 1592 0 R 1593 0 R 1594 0 R 1595 0 R 1596 0 R] -/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa238cfe9b905deda6f1823ca32378f91) (index_intguideLibrary)] +/Kids [1575 0 R 1576 0 R 1577 0 R 1578 0 R 1579 0 R 1580 0 R] +/Limits [(Doc-Start) (faq_faqError_BSEC_E_DOSTEPS_INVALIDINPUT)] >> endobj 1644 0 obj << -/Kids [1597 0 R 1598 0 R 1599 0 R 1600 0 R 1601 0 R 1602 0 R] -/Limits [(index_intguideLibraryOutputs) (page.34)] +/Kids [1581 0 R 1582 0 R 1583 0 R 1584 0 R 1585 0 R 1586 0 R] +/Limits [(faq_faqError_BSEC_E_DOSTEPS_VALUELIMITS) (group__bsec__interface_ga832388c889417ed197609d9965625bfe)] >> endobj 1645 0 obj << -/Kids [1603 0 R 1604 0 R 1605 0 R 1606 0 R 1607 0 R 1608 0 R] -/Limits [(page.35) (section*.3)] +/Kids [1587 0 R 1588 0 R 1589 0 R 1590 0 R 1591 0 R 1592 0 R] +/Limits [(group__bsec__interface_ga847070d3ecfa970cb2f716a2d11fe219) (group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858a978a12de4397b9c0814e07650f8a1b46)] >> endobj 1646 0 obj << -/Kids [1609 0 R 1610 0 R 1611 0 R 1612 0 R 1613 0 R 1614 0 R] -/Limits [(section*.4) (structbsec__bme__settings__t_aecd99f57df2bc07663a7de83f877228e)] +/Kids [1593 0 R 1594 0 R 1595 0 R 1596 0 R 1597 0 R 1598 0 R] +/Limits [(group__bsec__interface_gga339df4596b1c0e02eede5d54aa0f2858aa1a59666f0af5463087f528473d4ff8c) (index_intguideBSECSolutions)] >> endobj 1647 0 obj << -/Kids [1615 0 R 1616 0 R 1617 0 R 1618 0 R 1619 0 R 1620 0 R] -/Limits [(structbsec__bme__settings__t_aed0450820cd910e06e26fba04256bc24) (subsection.4.1.3)] +/Kids [1599 0 R 1600 0 R 1601 0 R 1602 0 R 1603 0 R 1604 0 R] +/Limits [(index_intguideLibrary) (page.33)] >> endobj 1648 0 obj << -/Kids [1621 0 R 1622 0 R 1623 0 R 1624 0 R 1625 0 R 1626 0 R] -/Limits [(subsection.4.1.4) (subsubsection.3.3.4.1)] +/Kids [1605 0 R 1606 0 R 1607 0 R 1608 0 R 1609 0 R 1610 0 R] +/Limits [(page.34) (section*.2)] >> endobj 1649 0 obj << -/Kids [1627 0 R 1628 0 R 1629 0 R 1630 0 R 1631 0 R 1632 0 R] -/Limits [(subsubsection.3.3.4.2) (subsubsection.5.1.2.6)] +/Kids [1611 0 R 1612 0 R 1613 0 R 1614 0 R 1615 0 R 1616 0 R] +/Limits [(section*.3) (structbsec__bme__settings__t_aa4a1eeae4e7fe44a8093a3862996fbac)] >> endobj 1650 0 obj << -/Kids [1633 0 R 1634 0 R 1635 0 R 1636 0 R 1637 0 R 1638 0 R] -/Limits [(subsubsection.5.1.2.7) (table.4.7)] +/Kids [1617 0 R 1618 0 R 1619 0 R 1620 0 R 1621 0 R 1622 0 R] +/Limits [(structbsec__bme__settings__t_aecd99f57df2bc07663a7de83f877228e) (subsection.4.1.2)] >> endobj 1651 0 obj << -/Kids [1639 0 R] -/Limits [(table.4.8) (table.5.4)] +/Kids [1623 0 R 1624 0 R 1625 0 R 1626 0 R 1627 0 R 1628 0 R] +/Limits [(subsection.4.1.3) (subsubsection.3.3.3.7)] >> endobj 1652 0 obj << -/Kids [1640 0 R 1641 0 R 1642 0 R 1643 0 R 1644 0 R 1645 0 R] -/Limits [(Doc-Start) (section*.3)] +/Kids [1629 0 R 1630 0 R 1631 0 R 1632 0 R 1633 0 R 1634 0 R] +/Limits [(subsubsection.3.3.4.1) (subsubsection.5.1.2.4)] >> endobj 1653 0 obj << -/Kids [1646 0 R 1647 0 R 1648 0 R 1649 0 R 1650 0 R 1651 0 R] -/Limits [(section*.4) (table.5.4)] +/Kids [1635 0 R 1636 0 R 1637 0 R 1638 0 R 1639 0 R 1640 0 R] +/Limits [(subsubsection.5.1.2.5) (table.4.5)] >> endobj 1654 0 obj << -/Kids [1652 0 R 1653 0 R] -/Limits [(Doc-Start) (table.5.4)] +/Kids [1641 0 R 1642 0 R] +/Limits [(table.4.6) (table.5.4)] >> endobj 1655 0 obj << -/Dests 1654 0 R +/Kids [1643 0 R 1644 0 R 1645 0 R 1646 0 R 1647 0 R 1648 0 R] +/Limits [(Doc-Start) (section*.2)] >> endobj 1656 0 obj << +/Kids [1649 0 R 1650 0 R 1651 0 R 1652 0 R 1653 0 R 1654 0 R] +/Limits [(section*.3) (table.5.4)] +>> +endobj +1657 0 obj +<< +/Kids [1655 0 R 1656 0 R] +/Limits [(Doc-Start) (table.5.4)] +>> +endobj +1658 0 obj +<< +/Dests 1657 0 R +>> +endobj +1659 0 obj +<< /Type /Catalog -/Pages 1571 0 R -/Outlines 1572 0 R -/Names 1655 0 R +/Pages 1573 0 R +/Outlines 1574 0 R +/Names 1658 0 R /PageMode/UseOutlines /OpenAction 216 0 R >> endobj -1657 0 obj +1660 0 obj << /Author()/Title()/Subject()/Creator(LaTeX with hyperref package)/Producer(pdfTeX-1.40.18)/Keywords() -/CreationDate (D:20190628134145+08'00') -/ModDate (D:20190628134145+08'00') +/CreationDate (D:20200624162025+08'00') +/ModDate (D:20200624162025+08'00') /Trapped /False /PTEX.Fullbanner (This is MiKTeX-pdfTeX 2.9.6362 (1.40.18)) >> endobj xref -0 1658 +0 1661 0000000519 65535 f -0000840812 00000 n -0000840832 00000 n -0000840852 00000 n +0000840938 00000 n +0000840958 00000 n +0000840978 00000 n 0000000015 00000 n 0000547474 00000 n -0001229897 00000 n +0001230023 00000 n 0000000060 00000 n 0000000222 00000 n 0000547655 00000 n -0001229825 00000 n +0001229951 00000 n 0000000269 00000 n 0000000458 00000 n 0000552570 00000 n -0001229702 00000 n +0001229828 00000 n 0000000506 00000 n 0000000730 00000 n 0000552751 00000 n -0001229628 00000 n +0001229754 00000 n 0000000783 00000 n 0000000926 00000 n 0000552934 00000 n -0001229541 00000 n +0001229667 00000 n 0000000979 00000 n 0000001147 00000 n -0000556966 00000 n -0001229454 00000 n +0000556967 00000 n +0001229580 00000 n 0000001200 00000 n 0000001290 00000 n -0000564100 00000 n -0001229380 00000 n +0000564064 00000 n +0001229506 00000 n 0000001343 00000 n 0000001577 00000 n -0000564283 00000 n -0001229270 00000 n +0000564247 00000 n +0001229396 00000 n 0000001625 00000 n 0000001798 00000 n -0000564404 00000 n -0001229196 00000 n +0000564367 00000 n +0001229322 00000 n 0000001851 00000 n 0000001918 00000 n -0000602032 00000 n -0001229109 00000 n +0000601993 00000 n +0001229235 00000 n 0000001971 00000 n 0000002091 00000 n -0000604706 00000 n -0001229022 00000 n +0000604666 00000 n +0001229148 00000 n 0000002144 00000 n 0000002325 00000 n -0000604828 00000 n -0001228948 00000 n +0000604788 00000 n +0001229074 00000 n 0000002378 00000 n 0000002501 00000 n -0000609616 00000 n -0001228822 00000 n +0000609576 00000 n +0001228948 00000 n 0000002547 00000 n 0000002705 00000 n -0000609799 00000 n -0001228748 00000 n +0000609759 00000 n +0001228874 00000 n 0000002753 00000 n 0000002845 00000 n -0000610043 00000 n -0001228661 00000 n +0000610003 00000 n +0001228787 00000 n 0000002893 00000 n 0000003031 00000 n -0000614559 00000 n -0001228574 00000 n +0000614520 00000 n +0001228700 00000 n 0000003079 00000 n 0000003192 00000 n -0000618304 00000 n -0001228487 00000 n +0000618265 00000 n +0001228613 00000 n 0000003240 00000 n 0000003416 00000 n -0000626182 00000 n -0001228400 00000 n +0000626141 00000 n +0001228526 00000 n 0000003464 00000 n 0000003627 00000 n -0000632926 00000 n -0001228313 00000 n +0000632886 00000 n +0001228439 00000 n 0000003675 00000 n 0000003788 00000 n -0000637047 00000 n -0001228226 00000 n +0000637005 00000 n +0001228352 00000 n 0000003836 00000 n 0000004147 00000 n -0000640369 00000 n -0001228139 00000 n +0000640327 00000 n +0001228265 00000 n 0000004195 00000 n 0000004500 00000 n -0000640489 00000 n -0001228052 00000 n +0000640447 00000 n +0001228178 00000 n 0000004548 00000 n 0000004763 00000 n -0000640610 00000 n -0001227978 00000 n +0000640568 00000 n +0001228104 00000 n 0000004812 00000 n 0000004889 00000 n -0000645524 00000 n -0001227849 00000 n +0000645483 00000 n +0001227975 00000 n 0000004935 00000 n 0000004977 00000 n -0000645706 00000 n -0001227771 00000 n +0000645665 00000 n +0001227897 00000 n 0000005026 00000 n 0000005225 00000 n -0000645828 00000 n -0001227679 00000 n +0000645787 00000 n +0001227805 00000 n 0000005274 00000 n 0000005566 00000 n -0000645950 00000 n -0001227562 00000 n +0000645909 00000 n +0001227688 00000 n 0000005615 00000 n 0000005830 00000 n -0000646073 00000 n -0001227483 00000 n +0000646032 00000 n +0001227609 00000 n 0000005884 00000 n 0000006103 00000 n -0000664192 00000 n -0001227390 00000 n +0000664151 00000 n +0001227516 00000 n 0000006157 00000 n 0000006431 00000 n -0000682056 00000 n -0001227297 00000 n +0000682017 00000 n +0001227423 00000 n 0000006485 00000 n 0000006862 00000 n -0000694561 00000 n -0001227218 00000 n +0000694522 00000 n +0001227344 00000 n 0000006916 00000 n 0000007165 00000 n -0000701856 00000 n -0001227086 00000 n +0000701820 00000 n +0001227212 00000 n 0000007212 00000 n 0000007343 00000 n -0000701978 00000 n -0001226982 00000 n +0000701942 00000 n +0001227108 00000 n 0000007392 00000 n 0000007506 00000 n -0000702039 00000 n -0001226903 00000 n +0000702003 00000 n +0001227029 00000 n 0000007560 00000 n 0000007666 00000 n -0000707601 00000 n -0001226810 00000 n +0000707564 00000 n +0001226936 00000 n 0000007720 00000 n 0000007846 00000 n -0000766265 00000 n -0001226717 00000 n +0000766229 00000 n +0001226843 00000 n 0000007900 00000 n 0000007988 00000 n -0000795693 00000 n -0001226638 00000 n +0000795657 00000 n +0001226764 00000 n 0000008042 00000 n 0000008105 00000 n -0000810346 00000 n -0001226519 00000 n +0000810473 00000 n +0001226645 00000 n 0000008152 00000 n 0000008326 00000 n -0000810471 00000 n -0001226401 00000 n +0000810598 00000 n +0001226527 00000 n 0000008375 00000 n 0000008598 00000 n -0000810596 00000 n -0001226322 00000 n +0000810723 00000 n +0001226448 00000 n 0000008652 00000 n 0000008783 00000 n -0000812920 00000 n -0001226243 00000 n +0000813047 00000 n +0001226369 00000 n 0000008837 00000 n 0000008963 00000 n -0000818632 00000 n -0001226111 00000 n +0000818759 00000 n +0001226237 00000 n 0000009012 00000 n 0000009197 00000 n -0000818757 00000 n -0001226032 00000 n +0000818884 00000 n +0001226158 00000 n 0000009251 00000 n 0000009382 00000 n -0000818819 00000 n -0001225953 00000 n +0000818946 00000 n +0001226079 00000 n 0000009436 00000 n 0000009562 00000 n -0000823380 00000 n -0001225821 00000 n +0000823507 00000 n +0001225947 00000 n 0000009611 00000 n 0000009801 00000 n -0000828199 00000 n -0001225742 00000 n +0000828325 00000 n +0001225868 00000 n 0000009855 00000 n 0000009986 00000 n -0000828261 00000 n -0001225663 00000 n +0000828387 00000 n +0001225789 00000 n 0000010040 00000 n 0000010166 00000 n -0000832790 00000 n -0001225531 00000 n +0000832916 00000 n +0001225657 00000 n 0000010215 00000 n 0000010478 00000 n -0000832915 00000 n -0001225452 00000 n +0000833041 00000 n +0001225578 00000 n 0000010532 00000 n 0000010663 00000 n -0000837684 00000 n -0001225373 00000 n +0000837810 00000 n +0001225499 00000 n 0000010717 00000 n 0000010843 00000 n -0000838123 00000 n -0001225255 00000 n +0000838249 00000 n +0001225381 00000 n 0000010892 00000 n 0000011087 00000 n -0000838248 00000 n -0001225176 00000 n +0000838374 00000 n +0001225302 00000 n 0000011141 00000 n 0000011272 00000 n -0000839998 00000 n -0001225097 00000 n +0000840124 00000 n +0001225223 00000 n 0000011326 00000 n 0000011452 00000 n 0000012595 00000 n @@ -16455,9 +16433,9 @@ xref 0000530469 00000 n 0000032736 00000 n 0000530531 00000 n -0001222552 00000 n -0001222730 00000 n -0001223540 00000 n +0001222678 00000 n +0001222856 00000 n +0001223666 00000 n 0000014448 00000 n 0000014578 00000 n 0000014802 00000 n @@ -16737,33 +16715,33 @@ xref 0000548250 00000 n 0000552508 00000 n 0000552630 00000 n -0001222911 00000 n -0001223391 00000 n +0001223037 00000 n +0001223517 00000 n 0000552690 00000 n 0000552811 00000 n -0001222123 00000 n +0001222249 00000 n 0000552872 00000 n -0000739405 00000 n -0000720396 00000 n -0000732735 00000 n +0000739367 00000 n +0000720357 00000 n +0000732696 00000 n 0000000520 00000 f 0000000521 00000 f 0000000522 00000 f 0000000524 00000 f -0000556382 00000 n +0000556383 00000 n 0000000537 00000 f -0000556582 00000 n -0000557087 00000 n -0000556234 00000 n +0000556583 00000 n +0000557088 00000 n +0000556235 00000 n 0000553266 00000 n -0000556781 00000 n -0000556843 00000 n -0001222266 00000 n -0001221834 00000 n -0000556904 00000 n -0000557026 00000 n -0001223658 00000 n -0000732421 00000 n +0000556782 00000 n +0000556844 00000 n +0001222392 00000 n +0001221960 00000 n +0000556905 00000 n +0000557027 00000 n +0001223784 00000 n +0000732382 00000 n 0000000538 00000 f 0000000539 00000 f 0000000540 00000 f @@ -16782,634 +16760,634 @@ xref 0000000553 00000 f 0000000554 00000 f 0000000953 00000 f -0000560960 00000 n -0000561193 00000 n -0000561426 00000 n -0000561659 00000 n -0000561890 00000 n -0000562122 00000 n -0000562588 00000 n -0000563054 00000 n -0000563287 00000 n -0000563520 00000 n -0000563718 00000 n -0000600974 00000 n -0000601373 00000 n -0000601572 00000 n -0000601772 00000 n -0000564525 00000 n -0000560724 00000 n -0000557359 00000 n -0000563916 00000 n -0000563978 00000 n -0000564039 00000 n -0000564160 00000 n -0000562355 00000 n -0000562821 00000 n -0000564221 00000 n -0000564343 00000 n -0000564464 00000 n -0000786152 00000 n -0000786090 00000 n -0000786215 00000 n -0000786278 00000 n -0000783020 00000 n -0000790478 00000 n -0000795505 00000 n -0000786341 00000 n -0000786403 00000 n -0000828323 00000 n -0000567083 00000 n -0000602213 00000 n -0000566911 00000 n -0000564797 00000 n -0000601970 00000 n -0000601174 00000 n -0000602092 00000 n -0000602153 00000 n -0000593452 00000 n -0000751830 00000 n -0000604949 00000 n -0000604524 00000 n -0000602501 00000 n -0000604644 00000 n -0000604766 00000 n -0000604888 00000 n -0000608564 00000 n -0000608737 00000 n -0000608961 00000 n -0000609142 00000 n -0000609346 00000 n -0000610102 00000 n -0000608392 00000 n -0000605208 00000 n -0000609554 00000 n -0000609676 00000 n -0000609737 00000 n -0001223091 00000 n -0000609859 00000 n -0000609920 00000 n -0000609981 00000 n -0000614236 00000 n -0000614678 00000 n -0000614096 00000 n -0000610362 00000 n -0000614435 00000 n -0000614497 00000 n -0000614619 00000 n -0000802768 00000 n -0000618043 00000 n -0000618364 00000 n -0000617903 00000 n -0000614938 00000 n -0000618242 00000 n -0001223776 00000 n -0000621477 00000 n -0000621737 00000 n -0000621337 00000 n -0000618611 00000 n -0000621675 00000 n -0000766327 00000 n -0000625676 00000 n -0000626302 00000 n -0000625536 00000 n -0000621971 00000 n -0000625876 00000 n -0001221689 00000 n -0000625938 00000 n -0000625999 00000 n -0000626060 00000 n -0000626121 00000 n -0000626242 00000 n -0000802893 00000 n -0000630051 00000 n -0000630229 00000 n -0000630407 00000 n -0000630606 00000 n -0000630806 00000 n -0000631005 00000 n -0000631239 00000 n -0000631452 00000 n -0000631686 00000 n -0000631898 00000 n -0000632097 00000 n -0000632296 00000 n -0000632496 00000 n -0000632693 00000 n -0000632986 00000 n -0000629807 00000 n -0000626601 00000 n -0000632864 00000 n -0000832728 00000 n -0000795754 00000 n -0000766515 00000 n -0000837871 00000 n -0000837746 00000 n -0000803018 00000 n -0000636725 00000 n -0000640046 00000 n -0000637107 00000 n -0000636585 00000 n -0000633233 00000 n -0000636924 00000 n -0000636986 00000 n -0000640670 00000 n -0000639906 00000 n -0000637354 00000 n -0000640246 00000 n -0000640308 00000 n -0000640429 00000 n -0000640549 00000 n -0000643634 00000 n -0000643834 00000 n -0000644034 00000 n -0000644234 00000 n -0000644434 00000 n -0000644634 00000 n -0000644834 00000 n -0000645034 00000 n -0000645266 00000 n -0000649023 00000 n -0000646256 00000 n -0000643430 00000 n -0000640917 00000 n -0000645462 00000 n -0000645584 00000 n -0000645645 00000 n -0000645767 00000 n -0000645889 00000 n -0000646011 00000 n -0000646134 00000 n -0000646195 00000 n -0001223894 00000 n -0000707662 00000 n -0000766578 00000 n -0000649223 00000 n -0000649422 00000 n -0000649621 00000 n -0000649821 00000 n -0000650021 00000 n -0000650419 00000 n -0000650618 00000 n -0000650851 00000 n -0000651051 00000 n -0000651285 00000 n -0000651484 00000 n -0000651684 00000 n -0000654802 00000 n -0000652221 00000 n -0000648779 00000 n -0000646528 00000 n -0000651915 00000 n -0000650221 00000 n -0000651977 00000 n -0000652038 00000 n -0000652099 00000 n -0000652160 00000 n -0000772854 00000 n -0000766640 00000 n -0000777485 00000 n -0000766703 00000 n -0000655002 00000 n -0000655236 00000 n -0000655469 00000 n -0000655668 00000 n -0000655866 00000 n -0000656098 00000 n -0000656297 00000 n -0000656496 00000 n -0000656893 00000 n -0000657126 00000 n -0000657326 00000 n -0000657525 00000 n -0000657923 00000 n -0000661175 00000 n -0000658581 00000 n -0000654542 00000 n -0000652507 00000 n -0000658153 00000 n -0000658215 00000 n -0000658276 00000 n -0000656694 00000 n -0000658337 00000 n -0000658398 00000 n -0000657724 00000 n -0000658459 00000 n -0000658520 00000 n -0000766765 00000 n -0000782832 00000 n -0000766827 00000 n -0000766888 00000 n -0000661375 00000 n -0000661574 00000 n -0000661807 00000 n -0000662039 00000 n -0000662238 00000 n -0000662436 00000 n -0000662607 00000 n -0000662840 00000 n -0000663072 00000 n -0000663271 00000 n -0000663469 00000 n -0000663640 00000 n -0000663871 00000 n -0000667278 00000 n -0000664617 00000 n -0000660931 00000 n -0000658867 00000 n -0000664069 00000 n -0000664131 00000 n -0000664253 00000 n -0000664314 00000 n -0000664375 00000 n -0000664435 00000 n -0000664496 00000 n -0000664556 00000 n -0000766950 00000 n -0000767013 00000 n -0000767076 00000 n -0000667510 00000 n -0000667743 00000 n -0000667941 00000 n -0000668141 00000 n -0000668374 00000 n -0000668607 00000 n -0000668804 00000 n -0000669003 00000 n -0000669174 00000 n -0000669407 00000 n -0000669607 00000 n -0000669806 00000 n -0000670001 00000 n -0000670232 00000 n -0000670857 00000 n -0000667026 00000 n -0000664877 00000 n -0000670429 00000 n -0000670491 00000 n -0000670552 00000 n -0000670613 00000 n -0000670674 00000 n -0000670735 00000 n -0000670796 00000 n -0000767139 00000 n -0000767202 00000 n -0000767264 00000 n -0000673436 00000 n -0000673607 00000 n -0000673840 00000 n -0000674073 00000 n -0000674306 00000 n -0000674506 00000 n -0000674705 00000 n -0000674905 00000 n -0000675103 00000 n -0000678628 00000 n -0000675786 00000 n -0000673232 00000 n -0000671143 00000 n -0000675300 00000 n -0000675362 00000 n -0000675423 00000 n -0000675484 00000 n -0000675545 00000 n -0000675605 00000 n -0000675666 00000 n -0000675727 00000 n -0000767325 00000 n -0000771732 00000 n -0000771794 00000 n -0000678861 00000 n -0000679060 00000 n -0000679260 00000 n -0000679493 00000 n -0000679692 00000 n -0000679892 00000 n -0000680290 00000 n -0000680523 00000 n -0000680723 00000 n -0000680956 00000 n -0000681155 00000 n -0000681553 00000 n -0000684876 00000 n -0000682296 00000 n -0000678376 00000 n -0000676046 00000 n -0000681750 00000 n -0000681812 00000 n -0000680092 00000 n -0000681873 00000 n -0000681934 00000 n -0000681995 00000 n -0000682117 00000 n -0000682177 00000 n -0000681355 00000 n -0000682237 00000 n -0001224012 00000 n -0000771919 00000 n -0000771856 00000 n -0000772107 00000 n -0000744805 00000 n -0000726605 00000 n -0000685109 00000 n -0000685308 00000 n -0000685707 00000 n -0000685940 00000 n -0000686140 00000 n -0000686539 00000 n -0000686772 00000 n -0000687005 00000 n -0000687205 00000 n -0000687405 00000 n -0000687605 00000 n -0000687804 00000 n -0000688001 00000 n -0000691472 00000 n -0000691672 00000 n -0000688685 00000 n -0000684616 00000 n -0000682582 00000 n -0000688196 00000 n -0000688258 00000 n -0000685508 00000 n -0000688319 00000 n -0000688380 00000 n -0000686340 00000 n -0000688441 00000 n -0000688502 00000 n -0000688563 00000 n -0000688624 00000 n -0000772169 00000 n -0000772229 00000 n -0000772292 00000 n -0000772355 00000 n -0000714773 00000 n -0000691870 00000 n -0000692103 00000 n -0000692302 00000 n -0000692501 00000 n -0000692900 00000 n -0000693131 00000 n -0000693330 00000 n -0000693530 00000 n -0000693763 00000 n -0000693963 00000 n -0000694865 00000 n -0000691236 00000 n -0000688957 00000 n -0000694194 00000 n -0000694256 00000 n -0000694317 00000 n -0000692701 00000 n -0000694378 00000 n -0000694439 00000 n -0000694500 00000 n -0000694621 00000 n -0000694682 00000 n -0000694743 00000 n -0000694804 00000 n -0000772417 00000 n -0000772479 00000 n -0000772668 00000 n -0000772792 00000 n -0000696644 00000 n -0000697060 00000 n -0000696504 00000 n -0000695137 00000 n -0000696877 00000 n -0000696939 00000 n -0000697000 00000 n -0000772730 00000 n +0000560932 00000 n +0000561163 00000 n +0000561396 00000 n +0000561629 00000 n +0000561860 00000 n +0000562092 00000 n +0000562558 00000 n +0000563021 00000 n +0000563252 00000 n +0000563484 00000 n +0000563682 00000 n +0000600935 00000 n +0000601334 00000 n +0000601533 00000 n +0000601733 00000 n +0000564487 00000 n +0000560696 00000 n +0000557360 00000 n +0000563880 00000 n +0000563942 00000 n +0000564003 00000 n +0000564124 00000 n +0000562325 00000 n +0000562791 00000 n +0000564185 00000 n +0000564307 00000 n +0000564426 00000 n +0000786114 00000 n +0000786052 00000 n +0000786177 00000 n +0000786240 00000 n +0000782982 00000 n +0000790441 00000 n +0000795469 00000 n +0000786303 00000 n +0000786365 00000 n +0000828449 00000 n +0000567044 00000 n +0000602174 00000 n +0000566872 00000 n +0000564759 00000 n +0000601931 00000 n +0000601135 00000 n +0000602053 00000 n +0000602114 00000 n +0000593413 00000 n +0000751793 00000 n +0000604909 00000 n +0000604484 00000 n +0000602462 00000 n +0000604604 00000 n +0000604726 00000 n +0000604848 00000 n +0000608524 00000 n +0000608697 00000 n +0000608921 00000 n +0000609102 00000 n +0000609306 00000 n +0000610062 00000 n +0000608352 00000 n +0000605168 00000 n +0000609514 00000 n +0000609636 00000 n +0000609697 00000 n +0001223217 00000 n +0000609819 00000 n +0000609880 00000 n +0000609941 00000 n +0000614197 00000 n +0000614639 00000 n +0000614057 00000 n +0000610322 00000 n +0000614396 00000 n +0000614458 00000 n +0000614580 00000 n +0000802894 00000 n +0000618004 00000 n +0000618325 00000 n +0000617864 00000 n +0000614899 00000 n +0000618203 00000 n +0001223902 00000 n +0000621438 00000 n +0000621698 00000 n +0000621298 00000 n +0000618572 00000 n +0000621636 00000 n +0000766291 00000 n +0000625635 00000 n +0000626261 00000 n +0000625495 00000 n +0000621932 00000 n +0000625835 00000 n +0001221815 00000 n +0000625897 00000 n +0000625958 00000 n +0000626019 00000 n +0000626080 00000 n +0000626201 00000 n +0000803019 00000 n +0000630011 00000 n +0000630189 00000 n +0000630367 00000 n +0000630566 00000 n +0000630766 00000 n +0000630965 00000 n +0000631199 00000 n +0000631412 00000 n +0000631646 00000 n +0000631858 00000 n +0000632057 00000 n +0000632256 00000 n +0000632456 00000 n +0000632653 00000 n +0000632946 00000 n +0000629767 00000 n +0000626560 00000 n +0000632824 00000 n +0000832854 00000 n +0000795718 00000 n +0000766479 00000 n +0000837997 00000 n +0000837872 00000 n +0000803144 00000 n +0000636683 00000 n +0000640004 00000 n +0000637065 00000 n +0000636543 00000 n +0000633193 00000 n +0000636882 00000 n +0000636944 00000 n +0000640628 00000 n +0000639864 00000 n +0000637312 00000 n +0000640204 00000 n +0000640266 00000 n +0000640387 00000 n +0000640507 00000 n +0000643593 00000 n +0000643793 00000 n +0000643993 00000 n +0000644193 00000 n +0000644393 00000 n +0000644593 00000 n +0000644793 00000 n +0000644993 00000 n +0000645225 00000 n +0000648982 00000 n +0000646215 00000 n +0000643389 00000 n +0000640875 00000 n +0000645421 00000 n +0000645543 00000 n +0000645604 00000 n +0000645726 00000 n +0000645848 00000 n +0000645970 00000 n +0000646093 00000 n +0000646154 00000 n +0001224020 00000 n +0000707625 00000 n +0000766542 00000 n +0000649182 00000 n +0000649381 00000 n +0000649580 00000 n +0000649780 00000 n +0000649980 00000 n +0000650378 00000 n +0000650577 00000 n +0000650810 00000 n +0000651010 00000 n +0000651244 00000 n +0000651443 00000 n +0000651643 00000 n +0000654761 00000 n +0000652180 00000 n +0000648738 00000 n +0000646487 00000 n +0000651874 00000 n +0000650180 00000 n +0000651936 00000 n +0000651997 00000 n +0000652058 00000 n +0000652119 00000 n +0000772817 00000 n +0000766604 00000 n +0000777447 00000 n +0000766667 00000 n +0000654961 00000 n +0000655195 00000 n +0000655428 00000 n +0000655627 00000 n +0000655825 00000 n +0000656057 00000 n +0000656256 00000 n +0000656455 00000 n +0000656852 00000 n +0000657085 00000 n +0000657285 00000 n +0000657484 00000 n +0000657882 00000 n +0000661134 00000 n +0000658540 00000 n +0000654501 00000 n +0000652466 00000 n +0000658112 00000 n +0000658174 00000 n +0000658235 00000 n +0000656653 00000 n +0000658296 00000 n +0000658357 00000 n +0000657683 00000 n +0000658418 00000 n +0000658479 00000 n +0000766729 00000 n +0000782794 00000 n +0000766791 00000 n +0000766852 00000 n +0000661334 00000 n +0000661533 00000 n +0000661766 00000 n +0000661998 00000 n +0000662197 00000 n +0000662395 00000 n +0000662566 00000 n +0000662799 00000 n +0000663031 00000 n +0000663230 00000 n +0000663428 00000 n +0000663599 00000 n +0000663830 00000 n +0000667239 00000 n +0000664576 00000 n +0000660890 00000 n +0000658826 00000 n +0000664028 00000 n +0000664090 00000 n +0000664212 00000 n +0000664273 00000 n +0000664334 00000 n +0000664394 00000 n +0000664455 00000 n +0000664515 00000 n +0000766914 00000 n +0000766977 00000 n +0000767040 00000 n +0000667471 00000 n +0000667704 00000 n +0000667902 00000 n +0000668102 00000 n +0000668335 00000 n +0000668568 00000 n +0000668765 00000 n +0000668964 00000 n +0000669135 00000 n +0000669368 00000 n +0000669568 00000 n +0000669767 00000 n +0000669962 00000 n +0000670193 00000 n +0000670818 00000 n +0000666987 00000 n +0000664836 00000 n +0000670390 00000 n +0000670452 00000 n +0000670513 00000 n +0000670574 00000 n +0000670635 00000 n +0000670696 00000 n +0000670757 00000 n +0000767103 00000 n +0000767166 00000 n +0000767228 00000 n +0000673397 00000 n +0000673568 00000 n +0000673801 00000 n +0000674034 00000 n +0000674267 00000 n +0000674467 00000 n +0000674666 00000 n +0000674866 00000 n +0000675064 00000 n +0000678589 00000 n +0000675747 00000 n +0000673193 00000 n +0000671104 00000 n +0000675261 00000 n +0000675323 00000 n +0000675384 00000 n +0000675445 00000 n +0000675506 00000 n +0000675566 00000 n +0000675627 00000 n +0000675688 00000 n +0000767289 00000 n +0000771695 00000 n +0000771757 00000 n +0000678822 00000 n +0000679021 00000 n +0000679221 00000 n +0000679454 00000 n +0000679653 00000 n +0000679853 00000 n +0000680251 00000 n +0000680484 00000 n +0000680684 00000 n +0000680917 00000 n +0000681116 00000 n +0000681514 00000 n +0000684837 00000 n +0000682257 00000 n +0000678337 00000 n +0000676007 00000 n +0000681711 00000 n +0000681773 00000 n +0000680053 00000 n +0000681834 00000 n +0000681895 00000 n +0000681956 00000 n +0000682078 00000 n +0000682138 00000 n +0000681316 00000 n +0000682198 00000 n +0001224138 00000 n +0000771882 00000 n +0000771819 00000 n +0000772070 00000 n +0000744768 00000 n +0000726566 00000 n +0000685070 00000 n +0000685269 00000 n +0000685668 00000 n +0000685901 00000 n +0000686101 00000 n +0000686500 00000 n +0000686733 00000 n +0000686966 00000 n +0000687166 00000 n +0000687366 00000 n +0000687566 00000 n +0000687765 00000 n +0000687962 00000 n +0000691433 00000 n +0000691633 00000 n +0000688646 00000 n +0000684577 00000 n +0000682543 00000 n +0000688157 00000 n +0000688219 00000 n +0000685469 00000 n +0000688280 00000 n +0000688341 00000 n +0000686301 00000 n +0000688402 00000 n +0000688463 00000 n +0000688524 00000 n +0000688585 00000 n +0000772132 00000 n +0000772192 00000 n +0000772255 00000 n +0000772318 00000 n +0000714735 00000 n +0000691831 00000 n +0000692064 00000 n +0000692263 00000 n +0000692462 00000 n +0000692861 00000 n +0000693092 00000 n +0000693291 00000 n +0000693491 00000 n +0000693724 00000 n +0000693924 00000 n +0000694826 00000 n +0000691197 00000 n +0000688918 00000 n +0000694155 00000 n +0000694217 00000 n +0000694278 00000 n +0000692662 00000 n +0000694339 00000 n +0000694400 00000 n +0000694461 00000 n +0000694582 00000 n +0000694643 00000 n +0000694704 00000 n +0000694765 00000 n +0000772380 00000 n +0000772442 00000 n +0000772631 00000 n +0000772755 00000 n +0000696607 00000 n +0000697023 00000 n +0000696467 00000 n +0000695098 00000 n +0000696840 00000 n +0000696902 00000 n +0000696963 00000 n +0000772693 00000 n 0000000954 00000 f 0000000955 00000 f 0000000956 00000 f 0000000957 00000 f 0000000958 00000 f 0000000962 00000 f -0000700396 00000 n -0000700596 00000 n -0000700796 00000 n +0000700360 00000 n +0000700560 00000 n +0000700760 00000 n 0000000963 00000 f 0000000965 00000 f -0000700996 00000 n +0000700960 00000 n 0000000966 00000 f 0000000967 00000 f 0000000968 00000 f 0000000971 00000 f -0000701195 00000 n -0000701395 00000 n +0000701159 00000 n +0000701359 00000 n 0000000972 00000 f 0000001183 00000 f -0000701595 00000 n -0000702465 00000 n -0000700208 00000 n -0000697306 00000 n -0000701794 00000 n -0000701917 00000 n -0000702099 00000 n -0000702160 00000 n -0000702221 00000 n -0000702282 00000 n -0000702343 00000 n -0000702404 00000 n -0000706417 00000 n -0000706616 00000 n -0000706779 00000 n -0000706940 00000 n -0000707140 00000 n -0000707340 00000 n -0000707844 00000 n -0000706237 00000 n -0000702711 00000 n -0000707539 00000 n -0000707723 00000 n -0001222410 00000 n -0001223236 00000 n -0000707784 00000 n -0000818570 00000 n -0000823316 00000 n -0000710853 00000 n -0000711013 00000 n -0000711175 00000 n -0000711375 00000 n -0000711572 00000 n -0000711806 00000 n -0000711998 00000 n -0000712195 00000 n -0000712391 00000 n -0000712624 00000 n -0000712820 00000 n -0000713017 00000 n -0000713214 00000 n -0000713449 00000 n -0000713645 00000 n -0000713842 00000 n -0000714041 00000 n -0000714275 00000 n -0000714509 00000 n -0000714898 00000 n -0000710546 00000 n -0000708145 00000 n -0000714709 00000 n -0000714835 00000 n -0001224130 00000 n -0000818880 00000 n -0000777548 00000 n -0000822939 00000 n -0000823190 00000 n -0000777421 00000 n -0000718266 00000 n -0000718466 00000 n -0000718667 00000 n -0000718868 00000 n -0000719068 00000 n -0000719269 00000 n -0000719469 00000 n -0000719670 00000 n -0000719869 00000 n -0000720069 00000 n -0000723951 00000 n -0000724350 00000 n -0000720520 00000 n -0000718040 00000 n -0000715187 00000 n -0000720269 00000 n -0000720333 00000 n -0000720457 00000 n -0000795879 00000 n -0000724551 00000 n -0000724752 00000 n -0000724951 00000 n -0000725152 00000 n -0000725353 00000 n -0000725550 00000 n -0000725751 00000 n -0000725950 00000 n -0000726150 00000 n -0000726315 00000 n -0000726793 00000 n -0000723698 00000 n -0000720809 00000 n -0000726478 00000 n -0000724152 00000 n -0000726542 00000 n -0000726667 00000 n -0000726730 00000 n -0000796006 00000 n -0000838060 00000 n -0000729766 00000 n -0000729929 00000 n -0000730128 00000 n -0000730328 00000 n -0000730528 00000 n -0000730727 00000 n -0000730927 00000 n -0000731127 00000 n -0000731327 00000 n -0000731525 00000 n -0000731725 00000 n -0000731925 00000 n -0000732159 00000 n -0000736735 00000 n -0000732859 00000 n -0000729513 00000 n -0000727108 00000 n -0000732357 00000 n -0000732483 00000 n -0000732546 00000 n -0000732609 00000 n -0000732672 00000 n -0000732796 00000 n -0000840060 00000 n -0000840312 00000 n +0000701559 00000 n +0000702429 00000 n +0000700172 00000 n +0000697269 00000 n +0000701758 00000 n +0000701881 00000 n +0000702063 00000 n +0000702124 00000 n +0000702185 00000 n +0000702246 00000 n +0000702307 00000 n +0000702368 00000 n +0000706380 00000 n +0000706579 00000 n +0000706742 00000 n +0000706903 00000 n +0000707103 00000 n +0000707303 00000 n +0000707807 00000 n +0000706200 00000 n +0000702675 00000 n +0000707502 00000 n +0000707686 00000 n +0001222536 00000 n +0001223362 00000 n +0000707747 00000 n +0000818697 00000 n +0000823443 00000 n +0000710815 00000 n +0000710975 00000 n +0000711137 00000 n +0000711337 00000 n +0000711534 00000 n +0000711768 00000 n +0000711960 00000 n +0000712157 00000 n +0000712353 00000 n +0000712586 00000 n +0000712782 00000 n +0000712979 00000 n +0000713176 00000 n +0000713411 00000 n +0000713607 00000 n +0000713804 00000 n +0000714003 00000 n +0000714237 00000 n +0000714471 00000 n +0000714860 00000 n +0000710508 00000 n +0000708108 00000 n +0000714671 00000 n +0000714797 00000 n +0001224256 00000 n +0000819007 00000 n +0000777510 00000 n +0000823066 00000 n +0000823317 00000 n +0000777383 00000 n +0000718227 00000 n +0000718427 00000 n +0000718628 00000 n +0000718829 00000 n +0000719029 00000 n +0000719230 00000 n +0000719430 00000 n +0000719631 00000 n +0000719830 00000 n +0000720030 00000 n +0000723912 00000 n +0000724311 00000 n +0000720481 00000 n +0000718001 00000 n +0000715149 00000 n +0000720230 00000 n +0000720294 00000 n +0000720418 00000 n +0000795843 00000 n +0000724512 00000 n +0000724713 00000 n +0000724912 00000 n +0000725113 00000 n +0000725314 00000 n +0000725511 00000 n +0000725712 00000 n +0000725911 00000 n +0000726111 00000 n +0000726276 00000 n +0000726754 00000 n +0000723659 00000 n +0000720770 00000 n +0000726439 00000 n +0000724113 00000 n +0000726503 00000 n +0000726628 00000 n +0000726691 00000 n +0000795970 00000 n +0000838186 00000 n +0000729727 00000 n +0000729890 00000 n +0000730089 00000 n +0000730289 00000 n +0000730489 00000 n +0000730688 00000 n +0000730888 00000 n +0000731088 00000 n +0000731288 00000 n +0000731486 00000 n +0000731686 00000 n +0000731886 00000 n +0000732120 00000 n +0000736697 00000 n +0000732820 00000 n +0000729474 00000 n +0000727069 00000 n +0000732318 00000 n +0000732444 00000 n +0000732507 00000 n +0000732570 00000 n +0000732633 00000 n +0000732757 00000 n 0000840186 00000 n 0000840438 00000 n -0000736906 00000 n -0000737105 00000 n -0000737305 00000 n -0000737703 00000 n -0000737901 00000 n -0000738072 00000 n -0000738273 00000 n -0000738473 00000 n -0000738678 00000 n -0000738878 00000 n -0000739078 00000 n -0000739593 00000 n -0000736482 00000 n -0000733160 00000 n -0000739278 00000 n -0000737506 00000 n -0000739342 00000 n -0000739467 00000 n -0000739530 00000 n -0000810408 00000 n -0000813360 00000 n -0000742941 00000 n -0000743141 00000 n -0000743341 00000 n -0000743542 00000 n -0000743741 00000 n -0000743941 00000 n -0000744141 00000 n -0000744341 00000 n -0000744542 00000 n -0000744993 00000 n -0000742724 00000 n -0000739921 00000 n -0000744741 00000 n -0000744867 00000 n -0000744930 00000 n -0000748807 00000 n -0000749006 00000 n -0000749207 00000 n -0000749408 00000 n -0000749608 00000 n -0000749807 00000 n -0000750006 00000 n -0000750185 00000 n -0000750364 00000 n -0000750563 00000 n -0000750764 00000 n -0000750965 00000 n -0000751165 00000 n -0000751365 00000 n -0000751566 00000 n -0000751954 00000 n -0000748536 00000 n -0000745282 00000 n -0000751766 00000 n -0000751891 00000 n -0001224255 00000 n -0000755403 00000 n -0000755604 00000 n -0000755805 00000 n -0000755982 00000 n -0000756182 00000 n -0000756381 00000 n -0000756559 00000 n -0000756773 00000 n -0000757008 00000 n -0000757222 00000 n -0000757423 00000 n -0000757637 00000 n -0000757872 00000 n -0000758086 00000 n -0000758287 00000 n -0000758500 00000 n -0000758734 00000 n -0000758948 00000 n -0000759149 00000 n -0000759328 00000 n -0000759528 00000 n -0000759728 00000 n -0000763396 00000 n -0000760053 00000 n -0000755069 00000 n -0000752243 00000 n -0000759926 00000 n -0000759990 00000 n -0000800801 00000 n +0000840312 00000 n +0000840564 00000 n +0000736868 00000 n +0000737067 00000 n +0000737267 00000 n +0000737665 00000 n +0000737863 00000 n +0000738034 00000 n +0000738235 00000 n +0000738435 00000 n +0000738640 00000 n +0000738840 00000 n +0000739040 00000 n +0000739555 00000 n +0000736444 00000 n +0000733121 00000 n +0000739240 00000 n +0000737468 00000 n +0000739304 00000 n +0000739429 00000 n +0000739492 00000 n +0000810535 00000 n +0000813487 00000 n +0000742904 00000 n +0000743104 00000 n +0000743304 00000 n +0000743505 00000 n +0000743704 00000 n +0000743904 00000 n +0000744104 00000 n +0000744304 00000 n +0000744505 00000 n +0000744956 00000 n +0000742687 00000 n +0000739883 00000 n +0000744704 00000 n +0000744830 00000 n +0000744893 00000 n +0000748770 00000 n +0000748969 00000 n +0000749170 00000 n +0000749371 00000 n +0000749571 00000 n +0000749770 00000 n +0000749969 00000 n +0000750148 00000 n +0000750327 00000 n +0000750526 00000 n +0000750727 00000 n +0000750928 00000 n +0000751128 00000 n +0000751328 00000 n +0000751529 00000 n +0000751917 00000 n +0000748499 00000 n +0000745245 00000 n +0000751729 00000 n +0000751854 00000 n +0001224381 00000 n +0000755367 00000 n +0000755568 00000 n +0000755769 00000 n +0000755946 00000 n +0000756146 00000 n +0000756345 00000 n +0000756523 00000 n +0000756737 00000 n +0000756972 00000 n +0000757186 00000 n +0000757387 00000 n +0000757601 00000 n +0000757836 00000 n +0000758050 00000 n +0000758251 00000 n +0000758464 00000 n +0000758698 00000 n +0000758912 00000 n +0000759113 00000 n +0000759292 00000 n +0000759492 00000 n +0000759692 00000 n +0000763360 00000 n +0000760017 00000 n +0000755033 00000 n +0000752206 00000 n +0000759890 00000 n +0000759954 00000 n +0000802767 00000 n 0000001184 00000 f 0000001185 00000 f 0000001186 00000 f @@ -17442,42 +17420,42 @@ xref 0000001213 00000 f 0000001214 00000 f 0000001251 00000 f -0000763596 00000 n -0000763795 00000 n -0000763996 00000 n -0000764197 00000 n -0000764398 00000 n -0000764599 00000 n -0000764800 00000 n -0000765000 00000 n -0000765200 00000 n -0000765400 00000 n -0000765599 00000 n -0000765800 00000 n -0000766001 00000 n -0000771066 00000 n -0000771267 00000 n -0000771468 00000 n -0000767387 00000 n -0000763134 00000 n -0000760314 00000 n -0000766201 00000 n -0000766389 00000 n -0000766452 00000 n -0000775614 00000 n -0000772914 00000 n -0000770903 00000 n -0000767648 00000 n -0000771668 00000 n -0000771980 00000 n -0000772043 00000 n -0000772541 00000 n -0000772604 00000 n -0000775814 00000 n -0000776012 00000 n -0000776226 00000 n -0000776426 00000 n -0000776604 00000 n +0000763560 00000 n +0000763759 00000 n +0000763960 00000 n +0000764161 00000 n +0000764362 00000 n +0000764563 00000 n +0000764764 00000 n +0000764964 00000 n +0000765164 00000 n +0000765364 00000 n +0000765563 00000 n +0000765764 00000 n +0000765965 00000 n +0000771029 00000 n +0000771230 00000 n +0000771431 00000 n +0000767351 00000 n +0000763098 00000 n +0000760278 00000 n +0000766165 00000 n +0000766353 00000 n +0000766416 00000 n +0000775576 00000 n +0000772877 00000 n +0000770866 00000 n +0000767612 00000 n +0000771631 00000 n +0000771943 00000 n +0000772006 00000 n +0000772504 00000 n +0000772567 00000 n +0000775776 00000 n +0000775974 00000 n +0000776188 00000 n +0000776388 00000 n +0000776566 00000 n 0000001252 00000 f 0000001253 00000 f 0000001254 00000 f @@ -17488,24 +17466,24 @@ xref 0000001259 00000 f 0000001260 00000 f 0000001279 00000 f -0000776766 00000 n -0000776967 00000 n -0000780581 00000 n -0000780816 00000 n -0000781286 00000 n -0000777612 00000 n -0000775406 00000 n -0000773174 00000 n -0000777167 00000 n -0000777231 00000 n -0000777294 00000 n -0000777357 00000 n -0000781487 00000 n -0000781687 00000 n -0000781885 00000 n -0000782099 00000 n -0000782299 00000 n -0000782477 00000 n +0000776728 00000 n +0000776929 00000 n +0000780543 00000 n +0000780778 00000 n +0000781248 00000 n +0000777574 00000 n +0000775368 00000 n +0000773137 00000 n +0000777129 00000 n +0000777193 00000 n +0000777256 00000 n +0000777319 00000 n +0000781449 00000 n +0000781649 00000 n +0000781847 00000 n +0000782061 00000 n +0000782261 00000 n +0000782439 00000 n 0000001280 00000 f 0000001281 00000 f 0000001282 00000 f @@ -17525,371 +17503,374 @@ xref 0000001296 00000 f 0000001297 00000 f 0000001298 00000 f -0000001497 00000 f -0000789006 00000 n -0000789241 00000 n -0000789476 00000 n -0000789709 00000 n -0000790179 00000 n -0000793198 00000 n -0000793433 00000 n -0000793667 00000 n -0000794136 00000 n -0000794371 00000 n -0000783083 00000 n -0000780355 00000 n -0000777860 00000 n -0000782641 00000 n -0000782705 00000 n -0000781051 00000 n -0000782769 00000 n -0000782894 00000 n -0000782957 00000 n -0000828637 00000 n -0000786466 00000 n -0000785712 00000 n -0000783357 00000 n -0000785836 00000 n -0000785900 00000 n -0000785964 00000 n -0000786027 00000 n -0001224380 00000 n -0000790540 00000 n -0000788816 00000 n -0000786687 00000 n -0000790414 00000 n -0000789944 00000 n -0000794839 00000 n -0000795039 00000 n -0000795240 00000 n -0000796322 00000 n -0000792972 00000 n -0000790814 00000 n -0000795441 00000 n -0000793901 00000 n -0000794605 00000 n -0000795567 00000 n -0000795630 00000 n -0000795816 00000 n -0000795943 00000 n -0000796070 00000 n -0000796133 00000 n -0000796197 00000 n -0000796260 00000 n -0000798421 00000 n -0000798656 00000 n -0000798827 00000 n -0000799062 00000 n -0000799233 00000 n -0000799468 00000 n -0000799639 00000 n -0000799873 00000 n -0000800862 00000 n -0000798213 00000 n -0000796596 00000 n -0000800042 00000 n -0000800106 00000 n -0000800169 00000 n -0000800233 00000 n -0000800296 00000 n -0000800360 00000 n -0001221978 00000 n -0000800423 00000 n -0000800486 00000 n -0000800549 00000 n -0000800612 00000 n -0000800675 00000 n -0000800738 00000 n -0000803271 00000 n -0000802517 00000 n -0000801125 00000 n -0000802641 00000 n -0000802705 00000 n -0000802830 00000 n -0000802955 00000 n +0000001499 00000 f +0000788969 00000 n +0000789204 00000 n +0000789439 00000 n +0000789672 00000 n +0000790142 00000 n +0000793162 00000 n +0000793397 00000 n +0000793631 00000 n +0000794100 00000 n +0000794335 00000 n +0000783045 00000 n +0000780317 00000 n +0000777822 00000 n +0000782603 00000 n +0000782667 00000 n +0000781013 00000 n +0000782731 00000 n +0000782856 00000 n +0000782919 00000 n +0000828763 00000 n +0000786428 00000 n +0000785674 00000 n +0000783319 00000 n +0000785798 00000 n +0000785862 00000 n +0000785926 00000 n +0000785989 00000 n +0001224506 00000 n +0000790503 00000 n +0000788779 00000 n +0000786649 00000 n +0000790377 00000 n +0000789907 00000 n +0000794803 00000 n +0000795003 00000 n +0000795204 00000 n +0000796286 00000 n +0000792936 00000 n +0000790777 00000 n +0000795405 00000 n +0000793865 00000 n +0000794569 00000 n +0000795531 00000 n +0000795594 00000 n +0000795780 00000 n +0000795907 00000 n +0000796034 00000 n +0000796097 00000 n +0000796161 00000 n +0000796224 00000 n +0000798384 00000 n +0000798619 00000 n +0000798790 00000 n +0000799025 00000 n +0000799196 00000 n +0000799431 00000 n +0000799602 00000 n +0000799836 00000 n +0000800825 00000 n +0000798176 00000 n +0000796560 00000 n +0000800005 00000 n +0000800069 00000 n +0000800132 00000 n +0000800196 00000 n +0000800259 00000 n +0000800323 00000 n +0001222104 00000 n +0000800386 00000 n +0000800449 00000 n +0000800512 00000 n +0000800575 00000 n +0000800638 00000 n +0000800701 00000 n +0000800764 00000 n +0000803397 00000 n +0000802516 00000 n +0000801088 00000 n +0000802640 00000 n +0000802704 00000 n +0000802831 00000 n +0000802956 00000 n 0000803081 00000 n -0000803144 00000 n -0000803208 00000 n -0000803815 00000 n -0000803627 00000 n -0000803519 00000 n -0000803751 00000 n -0000806410 00000 n -0000806615 00000 n -0000806820 00000 n -0000807021 00000 n -0000807226 00000 n -0000807430 00000 n -0000807635 00000 n -0000807840 00000 n -0000808045 00000 n -0000808250 00000 n -0000808455 00000 n -0000808655 00000 n -0000808861 00000 n -0000809064 00000 n -0000809270 00000 n -0000809474 00000 n -0000809672 00000 n -0000810078 00000 n -0000810658 00000 n -0000806103 00000 n -0000803964 00000 n -0000810282 00000 n -0000810533 00000 n -0000809875 00000 n -0001224505 00000 n -0000813612 00000 n -0000812982 00000 n -0000813108 00000 n -0000813738 00000 n -0000813486 00000 n -0000813864 00000 n -0000813234 00000 n +0000803207 00000 n +0000803270 00000 n +0000803334 00000 n +0000803941 00000 n +0000803753 00000 n +0000803645 00000 n +0000803877 00000 n +0000806537 00000 n +0000806742 00000 n +0000806947 00000 n +0000807148 00000 n +0000807353 00000 n +0000807557 00000 n +0000807762 00000 n +0000807967 00000 n +0000808172 00000 n +0000808377 00000 n +0000808582 00000 n +0000808782 00000 n +0000808988 00000 n +0000809191 00000 n +0000809397 00000 n +0000809601 00000 n +0000809799 00000 n +0000810205 00000 n +0000810785 00000 n +0000806230 00000 n +0000804090 00000 n +0000810409 00000 n +0000810660 00000 n +0000810002 00000 n +0001224631 00000 n +0000813739 00000 n +0000813109 00000 n +0000813235 00000 n +0000813865 00000 n +0000813613 00000 n +0000813991 00000 n +0000813361 00000 n +0000818573 00000 n +0000812782 00000 n +0000814053 00000 n +0000812637 00000 n +0000811071 00000 n +0000812983 00000 n +0000813172 00000 n +0000813298 00000 n +0000813424 00000 n +0000813550 00000 n +0000813676 00000 n +0000813802 00000 n +0000813928 00000 n +0000816663 00000 n +0000816860 00000 n +0000817055 00000 n +0000817252 00000 n +0000817449 00000 n +0000817650 00000 n +0000817848 00000 n +0000818045 00000 n +0000818246 00000 n +0000819133 00000 n +0000816446 00000 n +0000814314 00000 n 0000818446 00000 n -0000812655 00000 n -0000813926 00000 n -0000812510 00000 n -0000810944 00000 n -0000812856 00000 n -0000813045 00000 n -0000813171 00000 n -0000813297 00000 n -0000813423 00000 n -0000813549 00000 n -0000813675 00000 n -0000813801 00000 n -0000816536 00000 n -0000816733 00000 n -0000816928 00000 n -0000817125 00000 n -0000817322 00000 n -0000817523 00000 n -0000817721 00000 n -0000817918 00000 n -0000818119 00000 n -0000819006 00000 n -0000816319 00000 n -0000814187 00000 n -0000818319 00000 n -0000818383 00000 n -0000818509 00000 n -0000818694 00000 n -0000818943 00000 n -0000823064 00000 n -0000821291 00000 n -0000821491 00000 n -0000821690 00000 n -0000821888 00000 n -0000822084 00000 n -0000822283 00000 n -0000822481 00000 n -0000822679 00000 n -0000827338 00000 n -0000827537 00000 n -0000827736 00000 n -0000823505 00000 n -0000821083 00000 n -0000819280 00000 n -0000822875 00000 n +0000818510 00000 n +0000818636 00000 n +0000818821 00000 n +0000819070 00000 n +0000823191 00000 n +0000821418 00000 n +0000821618 00000 n +0000821817 00000 n +0000822015 00000 n +0000822211 00000 n +0000822410 00000 n +0000822608 00000 n +0000822806 00000 n +0000827464 00000 n +0000827663 00000 n +0000827862 00000 n +0000823632 00000 n +0000821210 00000 n +0000819407 00000 n 0000823002 00000 n -0000823127 00000 n -0000823253 00000 n -0000823442 00000 n -0000832603 00000 n -0000832351 00000 n +0000823129 00000 n +0000823254 00000 n +0000823380 00000 n +0000823569 00000 n +0000832729 00000 n 0000832477 00000 n -0000827936 00000 n -0000828698 00000 n -0000827166 00000 n -0000823779 00000 n -0000828135 00000 n -0000828385 00000 n -0000828448 00000 n +0000832603 00000 n +0000828062 00000 n +0000828824 00000 n +0000827292 00000 n +0000823906 00000 n +0000828261 00000 n 0000828511 00000 n 0000828574 00000 n -0000831003 00000 n -0000831202 00000 n -0000831401 00000 n -0000831600 00000 n -0000831813 00000 n -0000832026 00000 n -0000832977 00000 n -0000830813 00000 n -0000828959 00000 n -0000832224 00000 n -0000832288 00000 n +0000828637 00000 n +0000828700 00000 n +0000831129 00000 n +0000831328 00000 n +0000831527 00000 n +0000831726 00000 n +0000831939 00000 n +0000832152 00000 n +0000833103 00000 n +0000830939 00000 n +0000829085 00000 n +0000832350 00000 n 0000832414 00000 n 0000832540 00000 n -0000832665 00000 n -0000832852 00000 n -0000835628 00000 n -0000001498 00000 f -0000001499 00000 f +0000832666 00000 n +0000832791 00000 n +0000832978 00000 n +0000835754 00000 n 0000001500 00000 f 0000001501 00000 f 0000001502 00000 f 0000001503 00000 f 0000001504 00000 f +0000001505 00000 f 0000001506 00000 f -0000835828 00000 n +0000001508 00000 f +0000835954 00000 n 0000000000 00000 f -0000836028 00000 n -0000836228 00000 n -0000836429 00000 n -0000836629 00000 n -0000836828 00000 n -0000837025 00000 n -0000837224 00000 n -0000837422 00000 n -0000838310 00000 n -0000835402 00000 n -0000833251 00000 n -0000837620 00000 n -0000837808 00000 n +0000836154 00000 n +0000836354 00000 n +0000836555 00000 n +0000836755 00000 n +0000836954 00000 n +0000837151 00000 n +0000837350 00000 n +0000837548 00000 n +0000838436 00000 n +0000835528 00000 n +0000833377 00000 n +0000837746 00000 n 0000837934 00000 n -0000837997 00000 n -0000838185 00000 n -0001224630 00000 n -0000840564 00000 n -0000839810 00000 n -0000838584 00000 n -0000839934 00000 n -0000840123 00000 n +0000838060 00000 n +0000838123 00000 n +0000838311 00000 n +0001224756 00000 n +0000840690 00000 n +0000839936 00000 n +0000838710 00000 n +0000840060 00000 n 0000840249 00000 n 0000840375 00000 n 0000840501 00000 n -0000840905 00000 n -0000840931 00000 n -0000841267 00000 n -0000841293 00000 n -0000841329 00000 n -0000841717 00000 n -0000841743 00000 n -0000841770 00000 n -0000841794 00000 n -0001221259 00000 n -0000841818 00000 n -0000842319 00000 n -0000842828 00000 n -0000843326 00000 n -0000850466 00000 n -0000850701 00000 n -0000857718 00000 n -0000857954 00000 n -0000864965 00000 n -0000865191 00000 n -0000872302 00000 n -0000872537 00000 n -0000879594 00000 n -0000879825 00000 n -0000886938 00000 n -0000887172 00000 n -0001001184 00000 n -0001001647 00000 n -0001107858 00000 n -0001108433 00000 n -0001203256 00000 n -0001203685 00000 n -0001205369 00000 n -0001205597 00000 n -0001216194 00000 n -0001216778 00000 n -0001220967 00000 n -0001224719 00000 n -0001224840 00000 n -0001224948 00000 n -0001225021 00000 n -0001230007 00000 n -0001230176 00000 n -0001230361 00000 n -0001230657 00000 n -0001230932 00000 n -0001231296 00000 n -0001231758 00000 n -0001232194 00000 n -0001232640 00000 n -0001233100 00000 n -0001233347 00000 n -0001233920 00000 n -0001234493 00000 n -0001235066 00000 n -0001235641 00000 n -0001236316 00000 n -0001237160 00000 n -0001238004 00000 n -0001238849 00000 n -0001239692 00000 n -0001240535 00000 n -0001241383 00000 n -0001242228 00000 n -0001243073 00000 n -0001243567 00000 n -0001243929 00000 n -0001244174 00000 n -0001244345 00000 n -0001244515 00000 n -0001244686 00000 n -0001244859 00000 n -0001245033 00000 n -0001245210 00000 n -0001245385 00000 n -0001245562 00000 n -0001245741 00000 n -0001245945 00000 n -0001246140 00000 n -0001246337 00000 n -0001246534 00000 n -0001246736 00000 n -0001247060 00000 n -0001247677 00000 n -0001248219 00000 n -0001248744 00000 n -0001249281 00000 n -0001249684 00000 n -0001249922 00000 n -0001250165 00000 n -0001250408 00000 n -0001250661 00000 n -0001250944 00000 n -0001251230 00000 n -0001251513 00000 n -0001251796 00000 n -0001252083 00000 n -0001252372 00000 n -0001252664 00000 n -0001252958 00000 n -0001253247 00000 n -0001253536 00000 n -0001253825 00000 n -0001254114 00000 n -0001254403 00000 n -0001254593 00000 n -0001254794 00000 n -0001254983 00000 n -0001255176 00000 n -0001255327 00000 n -0001255525 00000 n -0001255775 00000 n -0001255989 00000 n -0001256126 00000 n -0001256245 00000 n -0001256419 00000 n -0001256599 00000 n -0001256738 00000 n -0001256882 00000 n -0001257014 00000 n -0001257089 00000 n -0001257210 00000 n -0001257331 00000 n -0001257415 00000 n +0000840627 00000 n +0000841031 00000 n +0000841057 00000 n +0000841393 00000 n +0000841419 00000 n +0000841455 00000 n +0000841843 00000 n +0000841869 00000 n +0000841896 00000 n +0000841920 00000 n +0001221385 00000 n +0000841944 00000 n +0000842445 00000 n +0000842954 00000 n +0000843452 00000 n +0000850592 00000 n +0000850827 00000 n +0000857844 00000 n +0000858080 00000 n +0000865091 00000 n +0000865317 00000 n +0000872428 00000 n +0000872663 00000 n +0000879720 00000 n +0000879951 00000 n +0000887064 00000 n +0000887298 00000 n +0001001310 00000 n +0001001773 00000 n +0001107984 00000 n +0001108559 00000 n +0001203382 00000 n +0001203811 00000 n +0001205495 00000 n +0001205723 00000 n +0001216320 00000 n +0001216904 00000 n +0001221093 00000 n +0001224845 00000 n +0001224966 00000 n +0001225074 00000 n +0001225147 00000 n +0001230133 00000 n +0001230302 00000 n +0001230487 00000 n +0001230783 00000 n +0001231058 00000 n +0001231422 00000 n +0001231884 00000 n +0001232320 00000 n +0001232766 00000 n +0001233226 00000 n +0001233473 00000 n +0001234046 00000 n +0001234619 00000 n +0001235192 00000 n +0001235768 00000 n +0001236409 00000 n +0001237253 00000 n +0001238097 00000 n +0001238942 00000 n +0001239785 00000 n +0001240628 00000 n +0001241475 00000 n +0001242321 00000 n +0001243166 00000 n +0001243736 00000 n +0001244079 00000 n +0001244353 00000 n +0001244524 00000 n +0001244694 00000 n +0001244865 00000 n +0001245038 00000 n +0001245215 00000 n +0001245389 00000 n +0001245563 00000 n +0001245740 00000 n +0001245916 00000 n +0001246122 00000 n +0001246317 00000 n +0001246514 00000 n +0001246711 00000 n +0001246912 00000 n +0001247150 00000 n +0001247767 00000 n +0001248317 00000 n +0001248841 00000 n +0001249343 00000 n +0001249788 00000 n +0001250025 00000 n +0001250268 00000 n +0001250511 00000 n +0001250754 00000 n +0001251037 00000 n +0001251322 00000 n +0001251605 00000 n +0001251888 00000 n +0001252174 00000 n +0001252463 00000 n +0001252754 00000 n +0001253051 00000 n +0001253340 00000 n +0001253629 00000 n +0001253918 00000 n +0001254207 00000 n +0001254496 00000 n +0001254721 00000 n +0001254919 00000 n +0001255111 00000 n +0001255304 00000 n +0001255413 00000 n +0001255564 00000 n +0001255762 00000 n +0001256012 00000 n +0001256232 00000 n +0001256362 00000 n +0001256481 00000 n +0001256655 00000 n +0001256835 00000 n +0001256974 00000 n +0001257118 00000 n +0001257250 00000 n +0001257334 00000 n 0001257455 00000 n -0001257587 00000 n +0001257576 00000 n +0001257660 00000 n +0001257700 00000 n +0001257832 00000 n trailer -<< /Size 1658 -/Root 1656 0 R -/Info 1657 0 R -/ID [<B4CE6449C046D3C641B9AE46B2BC2AFB> <B4CE6449C046D3C641B9AE46B2BC2AFB>] >> +<< /Size 1661 +/Root 1659 0 R +/Info 1660 0 R +/ID [<B4634E215C17C010A811AAA7A5D8BF57> <B4634E215C17C010A811AAA7A5D8BF57>] >> startxref -1257863 +1258108 %%EOF diff --git a/lib/vendor/Bosch/BSEC/meson.build b/lib/vendor/Bosch/BSEC/meson.build index fe1e1746de595f1486e6d5d9e2e41147c18bdedb..f2181e89f5396e93e2b2221523b3455d344244f4 100644 --- a/lib/vendor/Bosch/BSEC/meson.build +++ b/lib/vendor/Bosch/BSEC/meson.build @@ -3,13 +3,13 @@ cc = meson.get_compiler('c') libalgobsec = cc.find_library('libalgobsec', dirs: meson.current_source_dir() + '/algo/normal_version/bin/gcc/Cortex_M4') includes = include_directories( - 'examples/', + 'examples/bsec_iot_example/', 'algo/normal_version/inc/', 'config/' ) sources = files( - 'examples/bsec_integration.c', + 'examples/bsec_iot_example/bsec_integration.c', # 'config/generic_18v_3s_28d/bsec_serialized_configurations_iaq.c' ) diff --git a/lib/vendor/Bosch/BSEC/readme_API.txt b/lib/vendor/Bosch/BSEC/readme_API.txt new file mode 100644 index 0000000000000000000000000000000000000000..07c2e5ebd2f16c60bea5ab6cd252bdbf5c4faf21 --- /dev/null +++ b/lib/vendor/Bosch/BSEC/readme_API.txt @@ -0,0 +1,4 @@ +API link +https://github.com/BoschSensortec/BME680_driver/releases + +please use version v3.5.10 \ No newline at end of file diff --git a/lib/vendor/Bosch/BSEC/readme_BSEC_In_Arduino.txt b/lib/vendor/Bosch/BSEC/readme_BSEC_In_Arduino.txt new file mode 100644 index 0000000000000000000000000000000000000000..e3aeac8ae62fa73e4ceaa560e9fd9ae4432e05ba --- /dev/null +++ b/lib/vendor/Bosch/BSEC/readme_BSEC_In_Arduino.txt @@ -0,0 +1,2 @@ +please refer to github +https://github.com/BoschSensortec/BSEC-Arduino-library \ No newline at end of file