i2cdevlib icon indicating copy to clipboard operation
i2cdevlib copied to clipboard

MPU6050 AND ARDUINO UNO

Open reut10 opened this issue 12 years ago • 5 comments

hello! I bought an arduino uno and sparkfun mpu6050. I try to download your library: https://github.com/jrowberg/i2cdevlib/tree/master/Arduino/MPU6050 I dont know why but I can't. How to download?

reut10 avatar Feb 19 '14 13:02 reut10

You can download the complete repository by going to the root folder here: https://github.com/jrowberg/i2cdevlib You can find the download link on the bottom right hand side - Download as Zip.

udawat avatar Feb 19 '14 14:02 udawat

thank you!!! The link is great, but it's not compiling!!! :(

that's what the arduino write to me: C:\Users\רעותי\Documents\Arduino\libraries\I2Cdev\I2Cdev.cpp: In static member function 'static int8_t I2Cdev::readBytes(bool, uint8_t, uint8_t, uint8_t, uint8_t_, uint16_t)': C:\Users\רעותי\Documents\Arduino\libraries\I2Cdev\I2Cdev.cpp:217: error: 'SPI' was not declared in this scope C:\Users\רעותי\Documents\Arduino\libraries\I2Cdev\I2Cdev.cpp: In static member function 'static int8_t I2Cdev::readWords(bool, uint8_t, uint8_t, uint8_t, uint16_t_, uint16_t)': C:\Users\רעותי\Documents\Arduino\libraries\I2Cdev\I2Cdev.cpp:299: error: 'SPI' was not declared in this scope C:\Users\רעותי\Documents\Arduino\libraries\I2Cdev\I2Cdev.cpp: In static member function 'static bool I2Cdev::writeBytes(bool, uint8_t, uint8_t, uint8_t, uint8_t_)': C:\Users\רעותי\Documents\Arduino\libraries\I2Cdev\I2Cdev.cpp:488: error: 'SPI' was not declared in this scope C:\Users\רעותי\Documents\Arduino\libraries\I2Cdev\I2Cdev.cpp: In static member function 'static bool I2Cdev::writeWords(bool, uint8_t, uint8_t, uint8_t, uint16_t_)': C:\Users\רעותי\Documents\Arduino\libraries\I2Cdev\I2Cdev.cpp:549: error: 'SPI' was not declared in this scope

I need to download ,another library? I'm sorry that I'm asking a lot this is my first time with arduino for school project. thank you again! reut

On Wed, Feb 19, 2014 at 4:12 PM, udawat [email protected] wrote:

You can download the complete repository by going to the root folder here: https://github.com/jrowberg/i2cdevlib You can find the download link on the bottom right hand side - Download as Zip.

— Reply to this email directly or view it on GitHubhttps://github.com/jrowberg/i2cdevlib/issues/60#issuecomment-35502073 .

reut10 avatar Feb 19 '14 21:02 reut10

I'm getting the same error, although I'm getting it when a different program calls this library. Reut, did you ever find a solution?

Thanks, David

dherlihy avatar Jun 11 '14 07:06 dherlihy

Hi David!! Just put all the liberies that you need in the same folder. Tell me if it doesn't work.. Reut

‏בתאריך יום רביעי, 11 ביוני 2014, dherlihy [email protected] כתב:

I'm getting the same error, although I'm getting it when a different program calls this library. Reut, did you ever find a solution?

Thanks, David

— Reply to this email directly or view it on GitHub https://github.com/jrowberg/i2cdevlib/issues/60#issuecomment-45709976.

reut10 avatar Jun 11 '14 07:06 reut10

On Arduino IDE you need to put #includes for each of the libraries you want it to pull in. Just include a header file in library directory with the same name as the directory. So for SPI you would have #include "SPI.h" in your .ino file.

tsimon57 avatar Sep 29 '14 22:09 tsimon57