# ESP32-S2 not building with I2C library that worked with ESP32 development board.

**URL:** <https://community.sparkfun.com/t/esp32-s2-not-building-with-i2c-library-that-worked-with-esp32-development-board/42087>\
**Category:** Wifi\
**Created:** [May 3, 2021, 8:57pm UTC](https://community.sparkfun.com/t/esp32-s2-not-building-with-i2c-library-that-worked-with-esp32-development-board/42087 "2021-05-03T20:57:51Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![keithco](https://avatars.discourse-cdn.com/v4/letter/k/e9a140/32.png) [@keithco](https://community.sparkfun.com/u/keithco)\
**Post date:** [May 3, 2021, 8:57pm UTC](https://community.sparkfun.com/t/esp32-s2-not-building-with-i2c-library-that-worked-with-esp32-development-board/42087/1 "2021-05-03T20:57:51Z")

</div>

Hello,

I just started working with the ESP32-S2. I am getting this error message while trying to build my Arduino project.

I’m using a BME680 sensor board that works fine with any of my ESP32 development boards.

-Keith

Arduino: 1.8.13 (Windows 10), Board: “SparkFun ESP32-S2 Thing Plus, UART0, Disabled, Default 4MB with spiffs (1.2MB APP/1.5MB SPIFFS), 240MHz (WiFi), QIO, 80MHz, 4MB (32Mb), 921600, None”

E:\Home Assistant Files\ESP32 ARDUINO FIRMWARE ROOM SENSORS\SB-1\sketch\_april-8\_SB-1\sketch\_april-8\_SB-1.ino: In function ‘void setup()’:

sketch\_april-8\_SB-1:125:8: error: ‘bme’ was not declared in this scope

if (!bme.begin(0x76))

^~~

E:\Home Assistant Files\ESP32 ARDUINO FIRMWARE ROOM SENSORS\SB-1\sketch\_april-8\_SB-1\sketch\_april-8\_SB-1.ino:125:8: note: suggested alternative: ‘time’

if (!bme.begin(0x76))

^~~

time

sketch\_april-8\_SB-1:132:3: error: ‘bme’ was not declared in this scope

bme.setTemperatureOversampling(BME680\_OS\_8X);

^~~

E:\Home Assistant Files\ESP32 ARDUINO FIRMWARE ROOM SENSORS\SB-1\sketch\_april-8\_SB-1\sketch\_april-8\_SB-1.ino:132:3: note: suggested alternative: ‘time’

bme.setTemperatureOversampling(BME680\_OS\_8X);

^~~

time

E:\Home Assistant Files\ESP32 ARDUINO FIRMWARE ROOM SENSORS\SB-1\sketch\_april-8\_SB-1\sketch\_april-8\_SB-1.ino: In function ‘void loop()’:

sketch\_april-8\_SB-1:189:13: error: ‘bme’ was not declared in this scope

if (! bme.performReading()) {

^~~

E:\Home Assistant Files\ESP32 ARDUINO FIRMWARE ROOM SENSORS\SB-1\sketch\_april-8\_SB-1\sketch\_april-8\_SB-1.ino:189:13: note: suggested alternative: ‘time’

if (! bme.performReading()) {

^~~

time

sketch\_april-8\_SB-1:196:21: error: ‘bme’ was not declared in this scope

temperature = bme.temperature;

^~~

E:\Home Assistant Files\ESP32 ARDUINO FIRMWARE ROOM SENSORS\SB-1\sketch\_april-8\_SB-1\sketch\_april-8\_SB-1.ino:196:21: note: suggested alternative: ‘time’

temperature = bme.temperature;

^~~

time

Used: C:\Users\Keith\Documents\Arduino\libraries\Wire

Used: C:\Users\Keith\Documents\Arduino\libraries\SPI

Multiple libraries were found for “WiFi.h”

Used: C:\Users\Keith\Documents\Arduino\hardware\espressif\esp32\libraries\WiFi

Not used: C:\Program Files (x86)\Arduino\libraries\WiFi

exit status 1

‘bme’ was not declared in this scope

This report would have more information with

“Show verbose output during compilation”

option enabled in File → Preferences.

---

<div class="post-metadata">

**Author:** ![YellowDog](https://yyz1.discourse-cdn.com/sparkfun/user_avatar/community.sparkfun.com/yellowdog/32/1782_2.png) [@YellowDog](https://community.sparkfun.com/u/YellowDog)\
**Post date:** [May 3, 2021, 9:24pm UTC](https://community.sparkfun.com/t/esp32-s2-not-building-with-i2c-library-that-worked-with-esp32-development-board/42087/2 "2021-05-03T21:24:49Z")

</div>

This might sound dumb, but are you sure you have the BME680 library installed?
