user3592: I am using an Arduino Leonardo together with a GY-521 breakout board (like this one, schematic) for an MPU 6050.
I am currently trying to get the DMP Version of the examples from Mr Rowberg to work. 
For all my tests, I use these connections:

GY-521 ->  Leonardo 
VCC -> 5V (3.3V has the same behaviour)
SDA -> SDA 
SCL -> SCL 
GND -> GND

The "raw" sketch works fine, I can read out the sensor data. For the DMP version I think I need to connect the INT pin to pin 3 on the leonardo, to allow the MPU6050 to trigger an interrupt. 
But as soon as I connect INT to anything (pins 0 through 3), the sketches do not find the MPU6050 any more. (They report ""MPU6050 connection failed").
Is my wiring off, or is my chip defective, and even more important, how could I figure that out on my own in the future? =)
Edit: 
The example source code says
/* =========================================================================
   NOTE: In addition to connection 3.3v, GND, SDA, and SCL, this sketch
   depends on the MPU-6050's INT pin being connected to the Arduino's
   external interrupt #0 pin. On the Arduino Uno and Mega 2560, this is
   digital I/O pin 2.
 * ========================================================================= */

The example does nothing (that I can see) to configure this pin.
Edit again:
I've borrowed an oscilloscope. SDA and SCL sit on 3.3V during normal communication, and I can see packets being exchanged. As soon as I connect the INT pin to any input pin on my Leonardo, both SDA and SCL go to ground. This means nothing to me, but maybe to someone else.

user186: possible problem: level mismatch
I speculate that maybe some output on this Arduino is trying to push close to 5.0 V into your gyro, which is well outside the specifications of your gyro.
You are lucky that anything worked at all.
According to page 12 of the MPU-6050 gyroscope datasheet,
the gyroscope is designed to operate from a power supply of VDD = 2.375V to 3.46V.
You might think that is already taken care of by the 3.3V regulator on your breakout board.
However, a VDD of 3.3 also implies that the gyro expects all of its inputs to be in the range 0 V to 3.3 V, and the gyro will drive its outputs in the range 0 V to 3.3 V.
Page 358 of the ATmega32u4 datasheet says that the ATmega32u4 is designed work with any power supply in the range 2.7V to 5.5V.
There is a 3.3V regulator on the Arduino Leonardo and another one on the GY-521 breakout board.
So the GY-521 breakout board should have its VCC connected to 5V and its GND connected to the Arduino GND so that regulator can power the gyro chip with 3.3.
Unfortunately for you, the Arduino Leonardo is designed to power the ATmega32u4 with VCC = 5.0 V.
What to do about level mismatch
Perhaps it would work better if we connect things the way they were designed to be used.
If I were you, I would try to keep signal levels within specifications by any one of:

Use a level converter, perhaps a I2C-compatible level converter for each data connection between the 3.3V I/O pins of the gyro and the 5.0V I/O pins of the Arduino Leonardo. (a) (b) (c) Or,
Somehow tweak the Arduino Leonardo to connect 3.3 V to the VCC pin of the ATmega32u4. (Does this require cutting traces on the PCB?). Or,
Use some other Arduino configured to run the processor at 3.3V (LilyPad Arduino USB; Arduino Fio; Arduino Zero; Arduino Due; Arduino TRE; some versions of Arduino Pro Mini; some versions of Arduino Pro; etc.) or easily connected to 3.3V (LilyPad Arduino SimpleSnap;  LilyPad Arduino Simple; LilyPad Arduino; etc.)


user186: Possible problem: pin interference

But as soon as I connect INT to anything (pins 0 through 3), the
  sketches do not find the MPU6050 any more. (They report ""MPU6050
  connection failed").
Is my wiring off, or is my chip defective, and even more important,
  how could I figure that out on my own in the future? =)

If I'm reading the Arduino Leonardo schematic correctly,
Arduino D0 is Rx, Arduino D1 is Tx,
Arduino D2 is the I2C_SDA, and Arduino D3 is the I2C_SCL.
You're already using the I2C_SDA and I2C_SCL as bidirectional I2C communication;
connecting some other output pin (such as the MPU6050 INT pin) to either of those pins is going to disrupt that communication and then things won't work.
On most Arduinos, Serial.println() and Serial.read() and the reprogramming process use the Rx and Tx pins.
Perhaps connecting the MPU6050 INT pin to either of those pins also causes some sort of problem leading to things that don't work.
(Although the Arduino Leonardo actually uses its USB_D- and USB_D+ pins for both Serial.println() and reprogramming, so maybe it isn't really a problem for the Leonardo?).
I would avoid using those pins for anything other than serial communication, even though I'm not at all sure that would actually cause a problem on the Arduino Leonardo.

The example source code says
  ... this sketch depends on the MPU-6050's INT pin being connected to
  the Arduino's external interrupt #0 pin. ...
  The example does nothing (that I can see) to configure this pin.

I assume you're using https://github.com/jrowberg/i2cdevlib/blob/master/Arduino/MPU6050/Examples/MPU6050_DMP6/MPU6050_DMP6.ino , right?
Interrupts are configured a little differently than I/O.
(In particular, "volatile" is critical to getting interrupts working right).
The part that configures that interrupt is in the setup() function:
void setup() {
    // ...

        // enable Arduino interrupt detection
        Serial.println(F("Enabling interrupt detection (Arduino external interrupt 0)..."));
        attachInterrupt(0, dmpDataReady, RISING);
    // ...
}

The "attachInterrupt(0, dmpDataReady, RISING)" line
configures the interrupt vector table and the configuration bits so that when something drives Arduino pin D2 (i.e., external interrupt source 0) from a low to a high, no matter what the Arduino is in the middle of doing, the Arduino puts that on hold, executes the dmpDataReady() function, and then the Arduino resumes where it left off.
I don't see how that ever worked, since "external interrupt 0" comes from pin D2, which on the Arduino Leonardo is connected to I2C_SDA, which we're using for I2C communication, so we can't use it for watching the gyro interrupt pin.
However, since the "attachInterrupt()" gets run long after the "MPU6050 connection failed" message gets printed out on your screen, a software bug in how the example code uses attachInterrupt() doesn't explain why you get that "fail" message printed on your screen.
what to do about pin interference
I would try either using some other pin, or try getting it to work without hooking that pin to the Arduino at all.
Using some other pin
I would try to assign a dedicated pin on the Arduino to the MPU6050 INT pin.
Maybe D9 would work?
I'm guessing on the Arduino Leonardo, the interrupt should be set up something more like:
// warning: untested code.
#include <PinChangeInt.h>
#include <PinChangeIntConfig.h>

// connect MPU6050 interrupt to Arduino D9
#define MPU6050_INT D9

void setup(){
    // ...
    // pin change interrupt
    pinMode(MPU6050_INT, INPUT);
    PCintPort::attachInterrupt(MPU6050_INT, dmpDataReady, RISING);
    // ...
}

Getting it to work without hooking INT to the Arduino
It's not at all clear that the Arduino really needs to be connected to the MPU6050 INT pin.
It appears that another option is for the Arduino to occasionally use the I2C communication to read the status of the MPU6050, which includes the current state of that pin.
That simplifies the hardware -- simply leave the MPU6050 INT pin unconnected.

3592: <p>I am using an Arduino Leonardo together with a GY-521 breakout board (like <a href="http://www.amazon.de/Arduino-GY-521-MPU-6050-gyroscope-accelerometer/dp/B00AZH43JC" rel="nofollow">this one</a>, <a href="http://playground.arduino.cc/uploads/Main/MPU6050-V1-SCH.jpg" rel="nofollow">schematic</a>) for an <a href="http://playground.arduino.cc/Main/MPU-6050" rel="nofollow">MPU 6050</a>.</p>

<p>I am currently trying to get the DMP Version of <a href="https://github.com/jrowberg/i2cdevlib/tree/master/Arduino/MPU6050" rel="nofollow">the examples from Mr Rowberg</a> to work. </p>

<p>For all my tests, I use these connections:</p>

<ul>
<li>GY-521 ->  Leonardo </li>
<li>VCC -> 5V (3.3V has the same behaviour)</li>
<li>SDA -> SDA </li>
<li>SCL -> SCL </li>
<li>GND -> GND</li>
</ul>

<p>The "raw" sketch works fine, I can read out the sensor data. For the DMP version I think I need to connect the INT pin to pin 3 on the leonardo, to allow the MPU6050 to trigger an interrupt. </p>

<p>But as soon as I connect INT to anything (pins 0 through 3), the sketches do not find the MPU6050 any more. (They report ""MPU6050 connection failed").</p>

<p>Is my wiring off, or is my chip defective, and even more important, how could I figure that out on my own in the future? =)</p>

<p><strong>Edit:</strong> 
The example source code says</p>

<pre><code>/* =========================================================================
   NOTE: In addition to connection 3.3v, GND, SDA, and SCL, this sketch
   depends on the MPU-6050's INT pin being connected to the Arduino's
   external interrupt #0 pin. On the Arduino Uno and Mega 2560, this is
   digital I/O pin 2.
 * ========================================================================= */
</code></pre>

<p>The example does nothing (that I can see) to configure this pin.</p>

<p><strong>Edit again:</strong></p>

<p>I've borrowed an oscilloscope. SDA and SCL sit on 3.3V during normal communication, and I can see packets being exchanged. As soon as I connect the INT pin to any input pin on my Leonardo, both SDA and SCL go to ground. This means nothing to me, but maybe to someone else.</p>
 186: <h2>possible problem: level mismatch</h2>

<p>I speculate that maybe some output on this Arduino is trying to push close to 5.0 V into your gyro, which is well outside the specifications of your gyro.
You are lucky that anything worked at all.</p>

<p>According to page 12 of <a href="http://www.invensense.com/mems/gyro/documents/PS-MPU-6000A-00v3.4.pdf" rel="nofollow">the MPU-6050 gyroscope datasheet</a>,
the gyroscope is designed to operate from a power supply of VDD = 2.375V to 3.46V.</p>

<p>You might think that is already taken care of by the 3.3V regulator on your breakout board.</p>

<p>However, a VDD of 3.3 also implies that the gyro expects all of its inputs to be in the range 0 V to 3.3 V, and the gyro will drive its outputs in the range 0 V to 3.3 V.</p>

<p>Page 358 of the <a href="http://www.atmel.com/Images/Atmel-7766-8-bit-AVR-ATmega16U4-32U4_Datasheet.pdf" rel="nofollow">ATmega32u4 datasheet</a> says that the ATmega32u4 is designed work with any power supply in the range 2.7V to 5.5V.</p>

<p>There is a 3.3V regulator on the Arduino Leonardo and another one on the <a href="http://playground.arduino.cc/Main/MPU-6050" rel="nofollow">GY-521 breakout board</a>.
So the GY-521 breakout board <em>should</em> have its VCC connected to 5V and its GND connected to the Arduino GND so that regulator can power the gyro chip with 3.3.</p>

<p>Unfortunately for you, the <a href="http://arduino.cc/en/Main/arduinoBoardLeonardo" rel="nofollow">Arduino Leonardo</a> is designed to power the ATmega32u4 with VCC = 5.0 V.</p>

<h2>What to do about level mismatch</h2>

<p>Perhaps it would work better if we connect things the way they were designed to be used.</p>

<p>If I were you, I would try to keep signal levels within specifications by any one of:</p>

<ul>
<li>Use a level converter, perhaps a <a href="http://playground.arduino.cc/Main/I2CBi-directionalLevelShifter" rel="nofollow">I2C-compatible level converter</a> for each data connection between the 3.3V I/O pins of the gyro and the 5.0V I/O pins of the Arduino Leonardo. <a href="http://www.adafruit.com/product/757" rel="nofollow">(a)</a> <a href="https://www.sparkfun.com/products/12009" rel="nofollow">(b)</a> <a href="https://www.sparkfun.com/products/11771" rel="nofollow">(c)</a> Or,</li>
<li>Somehow tweak the Arduino Leonardo to connect 3.3 V to the VCC pin of the ATmega32u4. (Does this require cutting traces on the PCB?). Or,</li>
<li>Use some other Arduino configured to run the processor at 3.3V (LilyPad Arduino USB; Arduino Fio; Arduino Zero; Arduino Due; Arduino TRE; some versions of Arduino Pro Mini; some versions of Arduino Pro; etc.) or easily connected to 3.3V (LilyPad Arduino SimpleSnap;  LilyPad Arduino Simple; LilyPad Arduino; etc.)</li>
</ul>
 186: <h2>Possible problem: pin interference</h2>

<blockquote>
  <p>But as soon as I connect INT to anything (pins 0 through 3), the
  sketches do not find the MPU6050 any more. (They report ""MPU6050
  connection failed").</p>
  
  <p>Is my wiring off, or is my chip defective, and even more important,
  how could I figure that out on my own in the future? =)</p>
</blockquote>

<p>If I'm reading the <a href="http://arduino.cc/en/Main/ArduinoBoardPro" rel="nofollow noreferrer">Arduino Leonardo</a> <a href="http://arduino.cc/en/uploads/Main/arduino-leonardo-schematic_3b.pdf" rel="nofollow noreferrer">schematic</a> correctly,
Arduino D0 is Rx, Arduino D1 is Tx,
Arduino D2 is the I2C_SDA, and Arduino D3 is the I2C_SCL.</p>

<p>You're already using the I2C_SDA and I2C_SCL as bidirectional I2C communication;
connecting some other output pin (such as the MPU6050 INT pin) to either of those pins is going to disrupt that communication and then things won't work.</p>

<p>On most Arduinos, Serial.println() and Serial.read() and the reprogramming process use the Rx and Tx pins.
Perhaps connecting the MPU6050 INT pin to either of those pins also causes some sort of problem leading to things that don't work.
(Although the Arduino Leonardo actually uses its USB_D- and USB_D+ pins for both Serial.println() and reprogramming, so maybe it isn't really a problem for the Leonardo?).
I would avoid using those pins for anything other than serial communication, even though I'm not at all sure that would actually cause a problem on the Arduino Leonardo.</p>

<blockquote>
  <p>The example source code says
  ... this sketch depends on the MPU-6050's INT pin being connected to
  the Arduino's external interrupt #0 pin. ...
  The example does nothing (that I can see) to configure this pin.</p>
</blockquote>

<p>I assume you're using <a href="https://github.com/jrowberg/i2cdevlib/blob/master/Arduino/MPU6050/Examples/MPU6050_DMP6/MPU6050_DMP6.ino" rel="nofollow noreferrer">https://github.com/jrowberg/i2cdevlib/blob/master/Arduino/MPU6050/Examples/MPU6050_DMP6/MPU6050_DMP6.ino</a> , right?</p>

<p>Interrupts are configured a little differently than I/O.
(In particular, "volatile" is critical to getting interrupts working right).</p>

<p>The part that configures that interrupt is in the setup() function:</p>

<pre><code>void setup() {
    // ...

        // enable Arduino interrupt detection
        Serial.println(F("Enabling interrupt detection (Arduino external interrupt 0)..."));
        attachInterrupt(0, dmpDataReady, RISING);
    // ...
}
</code></pre>

<p>The "attachInterrupt(0, dmpDataReady, RISING)" line
configures the interrupt vector table and the configuration bits so that when something drives Arduino pin D2 (i.e., external interrupt source 0) from a low to a high, no matter what the Arduino is in the middle of doing, the Arduino puts that on hold, executes the dmpDataReady() function, and then the Arduino resumes where it left off.</p>

<p>I don't see how that ever worked, since "external interrupt 0" comes from pin D2, which on the Arduino Leonardo is connected to I2C_SDA, which we're using for I2C communication, so we can't use it for watching the gyro interrupt pin.</p>

<p>However, since the "<a href="http://arduino.cc/en/Reference/AttachInterrupt" rel="nofollow noreferrer">attachInterrupt()</a>" gets run long <em>after</em> the "MPU6050 connection failed" message gets printed out on your screen, a software bug in how the example code uses attachInterrupt() doesn't explain why you get that "fail" message printed on your screen.</p>

<h2>what to do about pin interference</h2>

<p>I would try either using some other pin, or try getting it to work without hooking that pin to the Arduino at all.</p>

<h2>Using some other pin</h2>

<p>I would try to assign a dedicated pin on the Arduino to the MPU6050 INT pin.
Maybe D9 would work?</p>

<p>I'm guessing on the Arduino Leonardo, the interrupt should be set up something more like:</p>

<pre><code>// warning: untested code.
#include &lt;PinChangeInt.h&gt;
#include &lt;PinChangeIntConfig.h&gt;

// connect MPU6050 interrupt to Arduino D9
#define MPU6050_INT D9

void setup(){
    // ...
    // pin change interrupt
    pinMode(MPU6050_INT, INPUT);
    PCintPort::attachInterrupt(MPU6050_INT, dmpDataReady, RISING);
    // ...
}
</code></pre>

<h2>Getting it to work without hooking INT to the Arduino</h2>

<p>It's not at all clear that the Arduino really <em>needs</em> to be connected to the MPU6050 INT pin.
It appears that another option is for the Arduino to occasionally use the I2C communication to read the status of the MPU6050, which includes the current state of that pin.
That simplifies the hardware -- simply leave the MPU6050 INT pin unconnected.</p>
