SparkFun Electronics will be closed in observance of memorial day on Monday, May 29th. We will resume normal business hours on Tuesday, May 30th. Any orders placed after 2pm Mountain Time on Friday, May 26th will process and ship out on Tuesday, May 30th.

Member #77074

Member Since: July 22, 2009

Country: United States

  • For anyone that is struggling to get this sensor to work with an Arduino Leonardo using the libraries provided the example code link, I was able to get it to work by doing the following:

    First, the Leonardo I2C interface is detailed here: http://arduino.cc/en/Main/arduinoBoardLeonardo SDA -> Digital Pin 2 SCL -> Digital Pin 3

    Second, the Leonardo interrupt setup is detailed here: http://arduino.cc/en/Reference/AttachInterrupt The DMP6_test is setup to use interrupt 0 which is Digital Pin 2 on the Leonardo. I changed the line:

    attachInterrupt(0, dmpDataReady, RISING);


    attachInterrupt(4, dmpDataReady, RISING);

    And connected the interrupt to Digital pin 7.

    The DMP6_test and Processing sketch now works like a charm! I hope this helps anyone else that was struggling with the Leonardo setup.

No public wish lists :(