03-15-2022 08:48 AM
Hi, I'm using the BME688 sensor for a new project with Nordik nRF52832. I find on github the API for using the sensor. The problem is that API's files include the library coines that I'm not able to find anywhere. I would like to ask you if you have it or if you have a structure of the library to implement (because I do not understand what the various functions do). Thanks for your helps
03-16-2022 11:05 PM
Here is my answer for below your question.
coines_config_i2c_bus(COINES_I2C_BUS_0, COINES_I2C_STANDARD_MODE);
- Set I2C communication. This function is to set i2c for our platform.
coines_set_shuttleboard_vdd_vddio_config(3300, 3300); (both in the interface_init function)
- coines_set_shuttleboard_vdd_vddio_config handles our board power source. In your case, no need to apply.
coines_soft_reset(); - Please remove it. bme68x_coines_deinit is not necessary for test.
coines_delay_msec(1000); - mili second delay function.
Thank you.
coines_close_comm_intf(COINES_COMM_INTF_USB);
03-18-2022 09:45 AM - edited 03-18-2022 09:46 AM
Thanks for helping.
Now I try to adapt the code.
One further question. If I have already initialized the I2C communication in my project (I use it with other sensors), does I need to use this command coines_config_i2c_bus(COINES_I2C_BUS_0, COINES_I2C_STANDARD_MODE);
or can I avoid it?
03-21-2022 06:46 PM
No you don't have to do.
It's our i2c configuration code, so you don't need it 🙂
03-23-2022 12:10 PM
Thanks again for the answer.
I have a last (I hope) question.
I was looking the API code and I saw that a lot of functions refer to SPI comunication (for example in get_regs function there is a mask called BME68X_SPI_RD_MSK even though in the previous if the condition is I2C interface). I use I2C comunication, does it create a problem?
Thanks again
03-24-2022 12:29 AM
Hi Rosso,
You should do use I2C or SPI without any problem in BME688 API.
All SPI functions should be called only if you select BME68X_SPI_INTF.
Please let me know if you have any questions.
Thank you.