Community news, upcoming events and general discussions
Threads: 36 Posts: 88
Get technical support from the community
Threads: 1407 Posts: 7538
Threads: 18 Posts: 64
Tell us how to make XDK better!
Threads: 36 Posts: 119
Share and discuss community member projects
Threads: 78 Posts: 343
I'm using the Bosch BME680 and implementing an I2C communication. Files .c and .h are available on Github.com. My doubt is, in order to work with such a sensor, is it necessary to include these files in the XDK project file?
Or, does the comunication between XDK and this sensor work by using the extension bus example/functions only...without including external files?
Thanks for your help.
i do not think the extesnion bus example will be able to communicate correctly with the BME680 sensor. The programm is just a simple example to show the general use of the I2C interface of the XDK.
In order to communicate with the sensor you have to look into the data sheet. Usually these sensors work with the same basic concept. So i would assume you have to do some configuration (writing bit patterns to defined registeres of the sensor) like the rate the sensor should refresh the data or the accuracy.
To get data from the sensor you could programm a hard or software timer with a handling function which reads data from the sensor.
I hope this was helpfull.
Hi Bruno, The official driver is available in https://github.com/BoschSensortec/BME680_driver In order to evaluate it, you need to copy the source and interface files into your project and integrate them into the makefile. Furthermore you will need to write/adapt the read, write and delayms callbacks in order to read from the external bus (here is the point where you can use the read/write functions from the external bus).