When I attached Grove IMU sensor (MPU9250) with Wio terminal,
it shows that the errors and not compiled at all.
Example codes are starting as follows;
#include “Wire.h”
// I2Cdev and MPU9250 must be installed as libraries, or else the .cpp/.h files
// for both classes must be in the include path of your project
#include “I2Cdev.h”
#include “MPU9250.h”
#include “BMP280.h”
// class default I2C address is 0x68
// specific I2C addresses may be passed as a parameter here
// AD0 low = 0x68 (default for InvenSense evaluation board)
// AD0 high = 0x69
MPU9250 accelgyro;
I2Cdev I2C_M;
and the results are as follows;
C:\Users\user\Documents\Arduino\libraries\Grove_IMU_10DOF_v2.0-master\I2Cdev.cpp: In static member function ‘static int8_t I2Cdev::readBytes(uint8_t, uint8_t, uint8_t, uint8_t*, uint16_t)’:
C:\Users\user\Documents\Arduino\libraries\Grove_IMU_10DOF_v2.0-master\I2Cdev.cpp:276:62: error: ‘BUFFER_LENGTH’ was not declared in this scope
for (uint8_t k = 0; k < length; k += min(length, BUFFER_LENGTH)) {
^~~~~~~~~~~~~
C:\Users\user\Documents\Arduino\libraries\Grove_IMU_10DOF_v2.0-master\I2Cdev.cpp:276:62: note: suggested alternative: ‘REG_DSU_LENGTH’
for (uint8_t k = 0; k < length; k += min(length, BUFFER_LENGTH)) {
^~~~~~~~~~~~~
REG_DSU_LENGTH
C:\Users\user\Documents\Arduino\libraries\Grove_IMU_10DOF_v2.0-master\I2Cdev.cpp: In static member function ‘static int8_t I2Cdev::readWords(uint8_t, uint8_t, uint8_t, uint16_t*, uint16_t)’:
C:\Users\user\Documents\Arduino\libraries\Grove_IMU_10DOF_v2.0-master\I2Cdev.cpp:416:70: error: ‘BUFFER_LENGTH’ was not declared in this scope
for (uint8_t k = 0; k < length * 2; k += min(length * 2, BUFFER_LENGTH)) {
^~~~~~~~~~~~~
C:\Users\user\Documents\Arduino\libraries\Grove_IMU_10DOF_v2.0-master\I2Cdev.cpp:416:70: note: suggested alternative: ‘REG_DSU_LENGTH’
for (uint8_t k = 0; k < length * 2; k += min(length * 2, BUFFER_LENGTH)) {
^~~~~~~~~~~~~
REG_DSU_LENGTH