Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 4 of 4

Thread: Issues with compile failure: twi.h: No such file or directory

Threaded View

  1. #1
    Junior Member
    Join Date
    Feb 2020
    Farmington Hills (Detroit suburb), Michigan, USA

    Issues with compile failure: twi.h: No such file or directory

    I am using the Arduino 1.8.11 IDE + the Teensyduino 1.50 on a Windows 10 machine.

    I was using an Arduino UNO to interface with an MPU-6050 and the Keuwlsoft Bluetooth Electronics Android app. I quickly ran out of RAM and cast about looking for something with more memory. The Teensy 3.2 looked like an incredible value in a small size so I picked one up. Got the Blink program running along with interface to the Android and took the next step of setting up the I2C interface with the MPU-6050 (GY-521 'board). This is where my my elation and joy over finding such a nice part to work with came to a screeching halt- I continually get errors when compiling with the wire.h library. To simplify my request for assistance I pared the program down to its most basic form so as to focus on the issue at hand:

    #include <Wire.h>
    void setup(){}
    void loop(){}

    This yielded the following compiler output. The verbose output is also attached if it's of any help:

    Multiple libraries were found for "Wire.h"
    C:\Users\codew\Documents\Arduino\libraries\Wire\ut ility\twi.c:25:24: fatal error: compat/twi.h: No such file or directory

    Used: C:\Users\codew\Documents\Arduino\libraries\Wire
    compilation terminated.

    Not used: C:\Program
    Error compiling for board Teensy 3.2 / 3.1.

    I read MogaRaghu's post on a similar issue ( but I couldn't find a clear solution to my compile issue. I also did multiple internet searches but to no avail. Including/replacing with the i2c_t3.h library did not yield code which would compile either. For what its worth I have no problem compiling and running code which uses the wire.h library on the 'UNO, although this is not entirely surprising either. Any help which could be offered would be greatly appreciated!
    Attached Files Attached Files

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts