sensor-bme280 and Adafruit_Sensor.h

I use the library emiliosancheza/bme280-sensor/sensor-bme280. When I run the project I get an error

Generating C++ code for simulation…
/ws/sketchbook/f067fc25bccdee58bc4d550b70da0bbb4673edc9e916315127e31c9e4e6aac9c/sketch/sketch.ino:980:10: fatal error: ‘Adafruit_Sensor.h’ file not found

The file was found on GitHub adafruit/Adafruit_Sensor.
How to get rid of the error?

While XOD allows you to simulate microcontroller boards, it doesn’t have the capability to simulate additional hardware devices such as your bme280 sensor.

Thanks for the answer.
But how to connect an additional library?
Where to put the files

Where is it written how to collect the HOD code?
I’m just getting started with the platform.

Instructions for using libraries can be found here:

Adafruit_Sensor.cpp and Adafruit_Sensor.h should have been installed automatically when you added the emiliosancheza/bme280-sensor library to the XOD IDE. The simulator cannot “see” these files (that’s why you received an error), but they should be present if the library installation was successful.

Try uploading the patch called example-test-sensor-bme280 to your microcontroller board. Remember to tick the checkbox “Debug after upload” so that you can see the sensor readings in the watch nodes.

If you’re new to XOD I’d recommend working through the built-in tutorials. Another useful resource for self-paced learning is:
Rapid Prototyping

Thanks for the answers.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.