Air Quality And Weather Tracker Based On Bme680.
About the project
Using an the BME680 sensor it is possible to measure variables from the environment like temperature, air pressure, humidity and some gases to obtain the surrounding air quality.
Items used in this project
Software apps and online services
Hand tools and fabrication machines
The first step in this project is get to know the development board iMXRT1020, its development environment and get some insights the software implementation bringing live an environmental sensor the BME680 together with an RTC PCF85063.
For this purpose was followed the getting started library.
The IDE MCUXpresso was downloaded and installed. Also the board SDK which contain several project examples to get an insight with the HAL and SW utilities provided by the manufacturer.
Additional documents were required like the processor reference manual IMXRX1020RM which can be downloaded after logging from the NXP webpage. The board hardware guide and the MIMXRT1020-EVK-Design-Files were required.
- Getting hands on the I2C
Taking as a reference the board hardware guide was looked or the inertial sensor FXOS8700CQ which accord to the documentation is connected.
Which is directly connected to the LPI2C4 peripheral in the processor
And accord to the reference manual this pins are
This sensor was not included from factory in the board received
Flow change to connect and interact with the PCF85063 connected to the LPI2C1
This sensor answer to the address 0x51 and get the raw information
For purposes to create a fast project template some available drivers from the SDk were used but they were not completly implimented in the source tree of the project.
Initialization for I2C pins and GPIO pins for the leds, has to be included in the file pin_mux.c and pin_mux.h.
At the end of this report the project is trying to integrate the BME68x library API with some bugs in the I2C driver and the interaction with the library.
The datasheet of the BME680 can be found in https://www.bosch-sensortec.com/media/boschsensortec/downloads/datasheets/bst-bme680-ds001.pdf
The actual sensor use is commercially available soldered and mounted by for example Adafruit breakout board. https://learn.adafruit.com/adafruit-bme680-humidity-temperature-barometic-pressure-voc-gas/pinouts
This project keeps under CI in the project git repository. The main aims are to create a library for the RTC PCF85063 and get a clean run of the BME680. A better understanding of the API layers for the Ethernet has to be taken in the future in order to implement an MQTT client.