jdvr1994 / MPU9250PhotonLibrary

This is a library of MPU9250 devices (Inertial and Magnetic Array Sensors) for Particle Photon
GNU General Public License v3.0
2 stars 1 forks source link

Not compiling for Argon #1

Open rpgrunwald opened 4 years ago

rpgrunwald commented 4 years ago

:::: COMPILING APPLICATION

Creating f:/Lifter/Example/target/1.4.4/argon/platform_user_ram.ld ... In file included from f:/Lifter/Example/src/readsensor.ino:3:0: f:/Lifter/Example/lib/MPU9250_I2C/src/MPU9250.h:86:0: warning: "INFO" redefined

define INFO 0x01

^ In file included from ../services/inc/debug.h:1:0, from ../wiring/inc/spark_wiring.h:38, from ./inc/application.h:40, from ./inc/Particle.h:5, from f:/Lifter/Example/lib/MPU9250_I2C/src/MPU9250.h:7, from f:/Lifter/Example/src/readsensor.ino:3: ../services/inc/service_debug.h:69:0: note: this is the location of the previous definition

define INFO(fmt, ...) LOG(INFO, fmt, ##__VA_ARGS__)

^ In file included from f:/Lifter/Example/src/readsensor.ino:3:0: f:/Lifter/Example/lib/MPU9250_I2C/src/MPU9250.h:96:0: warning: "ST1" redefined

define ST1 0x09

^ f:/Lifter/Example/lib/MPU9250_I2C/src/MPU9250.h:87:0: note: this is the location of the previous definition

define ST1 0x02

^ f:/Lifter/Example/src/readsensor.ino: In function 'void setup()': f:/Lifter/Example/src/readsensor.ino:33:16: error: request for member 'begin' in 'margSensor', which is of non-class type 'MPU9250()' margSensor.begin(); ^ f:/Lifter/Example/src/readsensor.ino:36:16: error: request for member 'setGyroOffsetX' in 'margSensor', which is of non-class type 'MPU9250()' margSensor.setGyroOffsetX(0); ^ f:/Lifter/Example/src/readsensor.ino:37:16: error: request for member 'setGyroOffsetY' in 'margSensor', which is of non-class type 'MPU9250()' margSensor.setGyroOffsetY(0); ^ f:/Lifter/Example/src/readsensor.ino:38:16: error: request for member 'setGyroOffsetZ' in 'margSensor', which is of non-class type 'MPU9250()' margSensor.setGyroOffsetZ(0); ^ f:/Lifter/Example/src/readsensor.ino:39:16: error: request for member 'setAccelOffsetX' in 'margSensor', which is of non-class type 'MPU9250()' margSensor.setAccelOffsetX(0); ^ f:/Lifter/Example/src/readsensor.ino:40:16: error: request for member 'setAccelOffsetY' in 'margSensor', which is of non-class type 'MPU9250()' margSensor.setAccelOffsetY(0); ^ f:/Lifter/Example/src/readsensor.ino:41:16: error: request for member 'setAccelOffsetZ' in 'margSensor', which is of non-class type 'MPU9250()' margSensor.setAccelOffsetZ(0); ^ f:/Lifter/Example/src/readsensor.ino:50:16: error: request for member 'setGyroScale' in 'margSensor', which is of non-class type 'MPU9250()' margSensor.setGyroScale(3);// +-2000 dps ^ f:/Lifter/Example/src/readsensor.ino:59:16: error: request for member 'setAccelScale' in 'margSensor', which is of non-class type 'MPU9250()' margSensor.setAccelScale(1);// +-4g ^ f:/Lifter/Example/src/readsensor.ino:73:16: error: request for member 'setAccelDLPF' in 'margSensor', which is of non-class type 'MPU9250()' margSensor.setAccelDLPF(2); ^ f:/Lifter/Example/src/readsensor.ino: In function 'void loop()': f:/Lifter/Example/src/readsensor.ino:77:16: error: request for member 'Read9Axis' in 'margSensor', which is of non-class type 'MPU9250()' margSensor.Read9Axis(dataSensor); ^ make[3]: [../build/module.mk:277: ../build/target/user/platform-12-m/Example/src/readsensor.o] Error 1 make[2]: [../../../build/recurse.mk:12: user] Error 2 make[1]: [../build/recurse.mk:12: modules/argon/user-part] Error 2 make: [C:\Users\Paul.particle\toolchains\buildscripts\1.8.0\Makefile:54: compile-user] Error 2 The terminal process terminated with exit code: 2

JoniRinta-Kahila commented 1 year ago

If you are using the example from this library, replace the line MPU9250 margSensor(); to this MPU9250 margSensor;