diff --git a/src/MPU6050_6Axis_MotionApps20.cpp b/src/MPU6050_6Axis_MotionApps20.cpp index 2b01b28..913650f 100644 --- a/src/MPU6050_6Axis_MotionApps20.cpp +++ b/src/MPU6050_6Axis_MotionApps20.cpp @@ -269,7 +269,7 @@ static const unsigned char dmpMemory[MPU6050_DMP_CODE_SIZE] PROGMEM = { #endif // I Simplified this: -uint8_t dmpInitialize(uint8_t rateDivisor = MPU6050_DMP_FIFO_RATE_DIVISOR, uint8_t mpuAddr = 0x68){ +uint8_t MPU6050_6Axis_MotionApps20::dmpInitialize() { // reset device DEBUG_PRINTLN(F("\n\nResetting MPU6050...")); reset(); @@ -613,4 +613,4 @@ uint16_t MPU6050_6Axis_MotionApps20::dmpGetFIFOPacketSize() { uint8_t MPU6050_6Axis_MotionApps20::dmpGetCurrentFIFOPacket(uint8_t *data) { // overflow proof return(GetCurrentFIFOPacket(data, dmpPacketSize)); -} +} \ No newline at end of file diff --git a/src/MPU6050_6Axis_MotionApps20.h b/src/MPU6050_6Axis_MotionApps20.h index 8995ad4..3da7070 100644 --- a/src/MPU6050_6Axis_MotionApps20.h +++ b/src/MPU6050_6Axis_MotionApps20.h @@ -47,7 +47,7 @@ class MPU6050_6Axis_MotionApps20 : public MPU6050_Base { public: MPU6050_6Axis_MotionApps20(uint8_t address=MPU6050_DEFAULT_ADDRESS, void *wireObj=0) : MPU6050_Base(address, wireObj) { } - uint8_t dmpInitialize(uint8_t rateDivisor = MPU6050_DMP_FIFO_RATE_DIVISOR, uint8_t mpuAddr = 0x68); + uint8_t dmpInitialize(); bool dmpPacketAvailable(); uint8_t dmpSetFIFORate(uint8_t fifoRate); @@ -150,4 +150,4 @@ class MPU6050_6Axis_MotionApps20 : public MPU6050_Base { typedef MPU6050_6Axis_MotionApps20 MPU6050; -#endif /* _MPU6050_6AXIS_MOTIONAPPS20_H_ */ +#endif /* _MPU6050_6AXIS_MOTIONAPPS20_H_ */ \ No newline at end of file diff --git a/src/MPU6050_6Axis_MotionApps612.cpp b/src/MPU6050_6Axis_MotionApps612.cpp index bea9e8c..4a60436 100644 --- a/src/MPU6050_6Axis_MotionApps612.cpp +++ b/src/MPU6050_6Axis_MotionApps612.cpp @@ -341,7 +341,7 @@ const unsigned char dmpMemory[MPU6050_DMP_CODE_SIZE] PROGMEM = { // this is the most basic initialization I can create. with the intent that we access the register bytes as few times as needed to get the job done. // for detailed descriptins of all registers and there purpose google "MPU-6000/MPU-6050 Register Map and Descriptions" -uint8_t MPU6050::dmpInitialize(uint8_t rateDivisor = 0x04, uint8_t mpuAddr = 0x68) { // Lets get it over with fast Write everything once and set it up necely +uint8_t MPU6050::dmpInitialize(uint8_t rateDivisor, uint8_t mpuAddr) { // Lets get it over with fast Write everything once and set it up necely uint8_t val; uint16_t ival; // Reset procedure per instructions in the "MPU-6000/MPU-6050 Register Map and Descriptions" page 41 diff --git a/src/MPU6050_9Axis_MotionApps41.cpp b/src/MPU6050_9Axis_MotionApps41.cpp index 2c99495..a6ca5ac 100644 --- a/src/MPU6050_9Axis_MotionApps41.cpp +++ b/src/MPU6050_9Axis_MotionApps41.cpp @@ -334,7 +334,7 @@ const unsigned char dmpUpdates[MPU6050_DMP_UPDATES_SIZE] PROGMEM = { 0x00, 0x60, 0x04, 0x00, 0x40, 0x00, 0x00 }; -uint8_t dmpInitialize(uint8_t rateDivisor = MPU6050_DMP_FIFO_RATE_DIVISOR, uint8_t mpuAddr = 0x68){ +uint8_t MPU6050_9Axis_MotionApps41::dmpInitialize() { // reset device DEBUG_PRINTLN(F("\n\nResetting MPU6050...")); reset(); @@ -884,4 +884,4 @@ uint8_t MPU6050_9Axis_MotionApps41::dmpReadAndProcessFIFOPacket(uint8_t numPacke // void MPU6050_9Axis_MotionApps41::dmpOverrideQuaternion(long *q); uint16_t MPU6050_9Axis_MotionApps41::dmpGetFIFOPacketSize() { return dmpPacketSize; -} +} \ No newline at end of file diff --git a/src/MPU6050_9Axis_MotionApps41.h b/src/MPU6050_9Axis_MotionApps41.h index 24ce1e9..f9569e9 100644 --- a/src/MPU6050_9Axis_MotionApps41.h +++ b/src/MPU6050_9Axis_MotionApps41.h @@ -47,7 +47,7 @@ class MPU6050_9Axis_MotionApps41 : public MPU6050_Base { public: MPU6050_9Axis_MotionApps41(uint8_t address=MPU6050_DEFAULT_ADDRESS, void *wireObj=0) : MPU6050_Base(address, wireObj) { } - uint8_t dmpInitialize(uint8_t rateDivisor = MPU6050_DMP_FIFO_RATE_DIVISOR, uint8_t mpuAddr = 0x68); + uint8_t dmpInitialize(); bool dmpPacketAvailable(); uint8_t dmpSetFIFORate(uint8_t fifoRate); @@ -150,4 +150,4 @@ class MPU6050_9Axis_MotionApps41 : public MPU6050_Base { typedef MPU6050_9Axis_MotionApps41 MPU6050; -#endif /* _MPU6050_6AXIS_MOTIONAPPS41_H_ */ +#endif /* _MPU6050_6AXIS_MOTIONAPPS41_H_ */ \ No newline at end of file