Yep, another [I2cdev.h: No such file or directory] issue

Greetings,

I recently got rid of Microsoft Cloud storage and moved everything onto my computer. I followed the instructions explicitly for copying the I2Cdev.h folder and it appears in my libraries. When I attempt to compile, the file is not recognized. Following are the operative snippets of code and, following that, the verbose error messages. I am using a Seeeduino XIAO and the error messages do not reveal much.

I appreciate any help that may be presented. I am certain someone else has been here. I understand that some of the included directories may be superfluous but I do not believe they create conflict.

Respectfully - Baran

#include "I2cdev.h"
#include "MPU6050_6Axis_MotionApps20.h"
#include "MPU9250.h";
#include "MPU9250_asukiaaa.h";
MPU9250_asukiaaa mySensor;
#include "Wire.h"
#include "Seeed_BME280.h";
BME280 bme280;
MPU6050 mpu;


// ================================================================
// ===                      i2c SETUP Items                     ===
// ================================================================

void i2cSetup() {
  // join I2C bus (I2Cdev library doesn't do this automatically)
#if I2CDEV_IMPLEMENTATION == I2CDEV_ARDUINO_WIRE
  Wire.begin();
//  TWBR = 24; // 400kHz I2C clock (200kHz if CPU is 8MHz)
#elif I2CDEV_IMPLEMENTATION == I2CDEV_BUILTIN_FASTWIRE
  Fastwire::setup(400, true);
#endif
}

// ================================================================
// ===                         Setup                            ===
// ================================================================
void setup() {
  
  Serial.begin(115200); //115200
  i2cSetup();
  MPU6050Connect();
  pinMode(LED_PIN, OUTPUT);
   if (!bme280.init()) {Serial.println("Device error!");}
  pinMode(resetButton, INPUT_PULLUP);     // Initialize the pushbutton pin as an input pullup . . .
}

VERBOSE COMPILE ERROR MESSAGES

Arduino: 1.8.15 (Windows 10), Board: "Seeeduino XIAO, Arduino, On"

C:\Program Files (x86)\Arduino\arduino-builder -dump-prefs -logger=machine -hardware C:\Program Files (x86)\Arduino\hardware -hardware C:\Users\Baran\AppData\Local\Arduino15\packages -tools C:\Program Files (x86)\Arduino\tools-builder -tools C:\Program Files (x86)\Arduino\hardware\tools\avr -tools C:\Users\Baran\AppData\Local\Arduino15\packages -built-in-libraries C:\Program Files (x86)\Arduino\libraries -libraries C:\Users\Baran\sketchbook\libraries -fqbn=Seeeduino:samd:seeed_XIAO_m0:usbstack=arduino,debug=on -vid-pid=2886_802F -ide-version=10815 -build-path C:\Users\Baran\AppData\Local\Temp\arduino_build_93932 -warnings=none -build-cache C:\Users\Baran\AppData\Local\Temp\arduino_cache_297686 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.openocd.path=C:\Users\Baran\AppData\Local\Arduino15\packages\arduino\tools\openocd\0.10.0-arduino7 -prefs=runtime.tools.openocd-0.10.0-arduino7.path=C:\Users\Baran\AppData\Local\Arduino15\packages\arduino\tools\openocd\0.10.0-arduino7 -prefs=runtime.tools.bossac.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\bossac\1.7.0-arduino3 -prefs=runtime.tools.bossac-1.8.0-48-gb176eee.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\bossac\1.8.0-48-gb176eee -prefs=runtime.tools.arm-none-eabi-gcc.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\7-2017q4 -prefs=runtime.tools.arm-none-eabi-gcc-7-2017q4.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\7-2017q4 -prefs=runtime.tools.bossac-1.7.0-arduino3.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\bossac\1.7.0-arduino3 -prefs=runtime.tools.CMSIS-Atmel.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS-Atmel\1.2.1 -prefs=runtime.tools.CMSIS-Atmel-1.2.1.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS-Atmel\1.2.1 -prefs=runtime.tools.arduinoOTA.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\arduinoOTA\1.2.1 -prefs=runtime.tools.arduinoOTA-1.2.1.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\arduinoOTA\1.2.1 -prefs=runtime.tools.CMSIS.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\5.7.0 -prefs=runtime.tools.CMSIS-5.7.0.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\5.7.0 -verbose C:\Users\Baran\sketchbook\SuperFinalBB2_Ordered_31_July\SuperFinalBB2_Ordered_31_July.ino

C:\Program Files (x86)\Arduino\arduino-builder -compile -logger=machine -hardware C:\Program Files (x86)\Arduino\hardware -hardware C:\Users\Baran\AppData\Local\Arduino15\packages -tools C:\Program Files (x86)\Arduino\tools-builder -tools C:\Program Files (x86)\Arduino\hardware\tools\avr -tools C:\Users\Baran\AppData\Local\Arduino15\packages -built-in-libraries C:\Program Files (x86)\Arduino\libraries -libraries C:\Users\Baran\sketchbook\libraries -fqbn=Seeeduino:samd:seeed_XIAO_m0:usbstack=arduino,debug=on -vid-pid=2886_802F -ide-version=10815 -build-path C:\Users\Baran\AppData\Local\Temp\arduino_build_93932 -warnings=none -build-cache C:\Users\Baran\AppData\Local\Temp\arduino_cache_297686 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.openocd.path=C:\Users\Baran\AppData\Local\Arduino15\packages\arduino\tools\openocd\0.10.0-arduino7 -prefs=runtime.tools.openocd-0.10.0-arduino7.path=C:\Users\Baran\AppData\Local\Arduino15\packages\arduino\tools\openocd\0.10.0-arduino7 -prefs=runtime.tools.bossac.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\bossac\1.7.0-arduino3 -prefs=runtime.tools.bossac-1.8.0-48-gb176eee.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\bossac\1.8.0-48-gb176eee -prefs=runtime.tools.arm-none-eabi-gcc.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\7-2017q4 -prefs=runtime.tools.arm-none-eabi-gcc-7-2017q4.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\7-2017q4 -prefs=runtime.tools.bossac-1.7.0-arduino3.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\bossac\1.7.0-arduino3 -prefs=runtime.tools.CMSIS-Atmel.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS-Atmel\1.2.1 -prefs=runtime.tools.CMSIS-Atmel-1.2.1.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS-Atmel\1.2.1 -prefs=runtime.tools.arduinoOTA.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\arduinoOTA\1.2.1 -prefs=runtime.tools.arduinoOTA-1.2.1.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\arduinoOTA\1.2.1 -prefs=runtime.tools.CMSIS.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\5.7.0 -prefs=runtime.tools.CMSIS-5.7.0.path=C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\5.7.0 -verbose C:\Users\Baran\sketchbook\SuperFinalBB2_Ordered_31_July\SuperFinalBB2_Ordered_31_July.ino

Using board 'seeed_XIAO_m0' from platform in folder: C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.8.2

Using core 'arduino' from platform in folder: C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.8.2

Detecting libraries used...

"C:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\arm-none-eabi-gcc\7-2017q4/bin/arm-none-eabi-g++" -mcpu=cortex-m0plus -mthumb -c -g -Os -w -std=gnu++14 -ffunction-sections -fdata-sections -fno-threadsafe-statics -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions "-D__SKETCH_NAME__="""SuperFinalBB2_Ordered_31_July.ino"""" -w -x c++ -E -CC -DF_CPU=48000000L -DARDUINO=10815 -DARDUINO_SEEED_XIAO_M0 -DARDUINO_ARCH_SAMD -DARDUINO_SAMD_ZERO -D__SAMD21__ -D__SAMD21G18A__ -DARM_MATH_CM0PLUS -DSEEED_XIAO_M0 -DUSB_VID=0x2886 -DUSB_PID=0x802F -DUSBCON -DUSB_CONFIG_POWER=100 "-DUSB_MANUFACTURER="Seeed"" "-DUSB_PRODUCT="Seeed XIAO M0"" -g -DDEBUG=1 "-IC:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.8.2\cores\arduino/TinyUSB" "-IC:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.8.2\cores\arduino/TinyUSB/Adafruit_TinyUSB_ArduinoCore" "-IC:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.8.2\cores\arduino/TinyUSB/Adafruit_TinyUSB_ArduinoCore/tinyusb/src" -g -DDEBUG=1 -DARDUINO_SAMD_ZERO -D__SAMD21__ -D__SAMD21G18A__ -DARM_MATH_CM0PLUS -DSEEED_XIAO_M0 -DUSB_VID=0x2886 -DUSB_PID=0x802F -DUSBCON -DUSB_CONFIG_POWER=100 "-DUSB_MANUFACTURER="Seeed"" "-DUSB_PRODUCT="Seeed XIAO M0"" -g -DDEBUG=1 "-IC:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.8.2\cores\arduino/TinyUSB" "-IC:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.8.2\cores\arduino/TinyUSB/Adafruit_TinyUSB_ArduinoCore" "-IC:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.8.2\cores\arduino/TinyUSB/Adafruit_TinyUSB_ArduinoCore/tinyusb/src" "-IC:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\5.7.0/CMSIS/Core/Include/" "-IC:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS\5.7.0/CMSIS/DSP/Include/" "-IC:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\tools\CMSIS-Atmel\1.2.1/CMSIS-Atmel/CMSIS/Device/ATMEL/" "-IC:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.8.2\cores\arduino" "-IC:\Users\Baran\AppData\Local\Arduino15\packages\Seeeduino\hardware\samd\1.8.2\variants\XIAO_m0" "C:\Users\Baran\AppData\Local\Temp\arduino_build_93932\sketch\SuperFinalBB2_Ordered_31_July.ino.cpp" -o nul

Alternatives for I2cdev.h: SuperFinalBB2_Ordered_31_July:43:10: fatal error: I2cdev.h: No such file or directory

ResolveLibrary(I2cdev.h)

      ^~~~~~~~~~

-> candidates: compilation terminated.

exit status 1

I2cdev.h: No such file or directory

Even though the Windows file system is not case sensitive, the Arduino IDE's library dependency resolution system is. The correct file name is I2Cdev.h, but the filename you specified via your #include directive is I2cdev.h. Note the different case of the "C" between the two filenames.

So you can fix this problem by changing this line of your sketch:

#include "I2cdev.h"

to this:

#include "I2Cdev.h"
1 Like

Thank you so much. I woke up this morning and easily compiled another sketch and said "huh?" so I copy and pasted and it worked. I then realized the blindingly obvious mistake I made. I truly appreciate your swift response.

You're welcome. I'm glad to hear it's working now. Enjoy!
Per