Main Content

BME68x Gas Sensor

Measure barometric air pressure, relative humidity, ambient temperature, IAQ, eCO2, and bVOC from BME68x sensor

  • Library:
  • Simulink Support Package for Arduino Hardware / Sensors

  • block icon for BME680 Gas Sensor

Description

The BME68x Gas Sensor block measures barometric air pressure, relative humidity, ambient temperature, index for air quality (IAQ), index for air quality status (IAQStatus), equivalent carbon dioxide concentration (eCO2), and breath volatile organic compound concentration (bVOC) using the BME68x Gas sensor interfaced with the Arduino® Mega 2560 boards.

Note

The BME68x Gas sensor supports reading data only from Arduino Mega 2560 boards.

Note

The BME68x Gas Sensor takes around 5 minutes to output the values for index for air quality (IAQ).

Ports

Output

expand all

The block outputs barometric air pressure in Pascal (Pa).

Dependencies

This output port appears only if you select the Pressure (Pa) parameter.

Data Types: single

The block outputs the ambient temperature in ℃.

Dependencies

This output port appears only if you select the Temperature (℃) parameter.

Data Types: single

The block outputs the relative humidity in %.

Dependencies

This output port appears only if you select the Humidity (%) parameter.

Data Types: single

The block outputs the index for indoor air quality in parts per million (ppm).

Dependencies

This output port appears only if you select the IAQ parameter.

Data Types: single

The block outputs the status of index for indoor air quality measurement. 0 indicates that the IAQ data read is new, 1 indicates that the IAQ data read is not new.

Dependencies

This output port appears only if you select IAQ and IAQStatus parameters.

Data Types: uint8

The eCO2 port outputs the value for equivalent CO2 of indoor air in parts per million (ppm).

Dependencies

This output port appears only if you select the eCO2 parameter.

Data Types: single

The bVOC port outputs the equivalent breadth volatile organic compound concentration of indoor air in parts per million (ppm).

Dependencies

This output port appears only if you select the bVOC parameter.

Data Types: single

Parameters

expand all

The I2C addresses to communicate with the peripheral on the BME68x sensor are decided by the state of the SD0 pin on the Arduino Mega 2560 board. This table provides the I2C addresses corresponding to the pin and their state.

Pin NamePin StateI2C address
SD000x76
10x77

Select the power mode of the sensor based on the power supply you have.

Select this parameter to set Pressure as one of the output ports.

Select this parameter to set Temperature as one of the output ports.

Select this parameter to set Humidity as one of the output ports.

Select this parameter to set IAQ as one of the output ports.

Select this parameter to set IAQStatus as one of the output ports.

Select this parameter to set eCO2 as one of the output ports.

Select this parameter to set bVOC as one of the output ports.

Specify how often this block reads the data from the BME68x sensor. When you set this parameter to -1, Simulink determines the best sample time for the block based on the block context within the model.

Version History

Introduced in R2022b