Dear All,
I have added libraries of sensor BME680 to Segger Embedded Studio (IDE) successfully. But, I need help in displaying the sensor data on Serial Monitor (Using nRF52840-DK Microcontroller).
Dear All,
I have added libraries of sensor BME680 to Segger Embedded Studio (IDE) successfully. But, I need help in displaying the sensor data on Serial Monitor (Using nRF52840-DK Microcontroller).
Hello,
By Serial Monitor, do you mean the debug view in Segger Embedded Studio? Or do you need to output it via UART to an external terminal?
Depending on what project you started with, there may or may not be some logging in the project. Do you see any logging information from your application? If not, do you see the definition NRF_LOG_ENABLED in your sdk_config.h file?
Best regards,
Edvin
Hi Edvin,
Not in debug view. I want output via UART. NRF_LOG_ENABLED is already enabled in sdk_config.h file. I added drivers successfully and printing device address in serial monitor using UART. Now I wanted to print the temperature, pressure, humidity and air pressure on monitor.
Vins said:I added drivers successfully and printing device address in serial monitor using UART
So you are seeing data on UART now? If so, how do you print to uart? Using NRF_LOG_INFO("")? printf()? Or do you use app_uart_put()?
Regardless, are you able to get the data from your sensor using your driver? If so, you can forward the data to the UART the way you are already doing.
It is not clear to me what you are really asking here.
Vins said:I added drivers successfully and printing device address in serial monitor using UART
So you are seeing data on UART now? If so, how do you print to uart? Using NRF_LOG_INFO("")? printf()? Or do you use app_uart_put()?
Regardless, are you able to get the data from your sensor using your driver? If so, you can forward the data to the UART the way you are already doing.
It is not clear to me what you are really asking here.
Vins said:In Bosch drivers they have written it for SPI. I wanted to communicate with I2C.
Does the sensor even support I2C? (ok, I see from the link that it does).
If the driver isn't working, then you need to ask Bosch. We have not written these libraries/drivers, and I don't know any more than you how they work, unfortunately.
General tip: Check the return values in all function that you are using that have return values, such as twi_init() and so on. The return values will tell you whether the called function executed successfully or if something is missing.