Pages: [1]   Go Down
Author Topic: Problem with files  (Read 584 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 27
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset



Currently trying out the work of jrowberg that he has provided in this link:
https://github.com/jrowberg/i2cdevlib/tree/master/Arduino/MPU6050

However these are the errors that I am getting:
Quote
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp: In static member function 'static int8_t I2Cdev::readBytes(bool, uint8_t, uint8_t, uint8_t, uint8_t*, uint16_t)':
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp:190: error: 'Wire' was not declared in this scope
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp:217: error: 'SPI' was not declared in this scope
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp: In static member function 'static int8_t I2Cdev::readWords(bool, uint8_t, uint8_t, uint8_t, uint16_t*, uint16_t)':
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp:254: error: 'Wire' was not declared in this scope
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp:299: error: 'SPI' was not declared in this scope
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp: In static member function 'static bool I2Cdev::writeBytes(bool, uint8_t, uint8_t, uint8_t, uint8_t*)':
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp:466: error: 'Wire' was not declared in this scope
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp:488: error: 'SPI' was not declared in this scope
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp: In static member function 'static bool I2Cdev::writeWords(bool, uint8_t, uint8_t, uint8_t, uint16_t*)':
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp:525: error: 'Wire' was not declared in this scope
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev\I2Cdev.cpp:549: error: 'SPI' was not declared in this scope
Logged

Offline Offline
Sr. Member
****
Karma: 9
Posts: 254
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You probably need to include the SPI and Wire libraries in your main sketch file.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 27
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Okay, after including it in just like what you said, these are now the errors that I got.

Quote
DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\MPU6050\MPU6050.cpp:1354: error: no matching function for call to 'I2Cdev::readBit(uint8_t&, int, int, uint8_t [14])'
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev/I2Cdev.h:84: note: candidates are: static int8_t I2Cdev::readBit(bool, uint8_t, uint8_t, uint8_t, uint8_t*, uint16_t)
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\MPU6050\MPU6050.cpp: In member function 'void MPU6050::setInterruptLatch(bool)':
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\MPU6050\MPU6050.cpp:1364: error: no matching function for call to 'I2Cdev::writeBit(uint8_t&, int, int, bool&)'
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev/I2Cdev.h:93: note: candidates are: static bool I2Cdev::writeBit(bool, uint8_t, uint8_t, uint8_t, uint8_t)
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\MPU6050\MPU6050.cpp: In member function 'bool MPU6050::getInterruptLatchClear()':
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\MPU6050\MPU6050.cpp:1373: error: no matching function for call to 'I2Cdev::readBit(uint8_t&, int, int, uint8_t [14])'
D:\NEW DOWNLOADS\arduino-1.0.4-windows\arduino-1.0.4\libraries\I2Cdev/I2Cdev.h:84: note: candidates are: static int8_t I2Cdev::readBit(bool, uint8_t, uint8_t, uint8_t, uint8_t*, uint16_t)
Logged

Offline Offline
Sr. Member
****
Karma: 9
Posts: 254
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

It looks like there may be some problems with that library. You could try going through and fixing some of those function calls.
Logged

Pages: [1]   Go Up
Jump to: