Skip to content

Commit

Permalink
patch
Browse files Browse the repository at this point in the history
  • Loading branch information
sabas1080 committed Dec 18, 2023
1 parent 09495a5 commit 9a7033a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
5 changes: 0 additions & 5 deletions src/MPU6050_6Axis_MotionApps612.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -339,11 +339,6 @@ const unsigned char dmpMemory[MPU6050_DMP_CODE_SIZE] PROGMEM = {
0xA6, 0xD9, 0x00, 0xD8, 0xF1, 0xFF,
};

// this divisor is pre configured into the above image and can't be modified at this time.
#ifndef MPU6050_DMP_FIFO_RATE_DIVISOR
#define MPU6050_DMP_FIFO_RATE_DIVISOR 0x01 // The New instance of the Firmware has this as the default
#endif

// 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
Expand Down
5 changes: 5 additions & 0 deletions src/MPU6050_6Axis_MotionApps612.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,11 @@ THE SOFTWARE.

#include "MPU6050.h"

// this divisor is pre configured into the above image and can't be modified at this time.
#ifndef MPU6050_DMP_FIFO_RATE_DIVISOR
#define MPU6050_DMP_FIFO_RATE_DIVISOR 0x01 // The New instance of the Firmware has this as the default
#endif

class MPU6050_6Axis_MotionApps612 : public MPU6050_Base {
public:
MPU6050_6Axis_MotionApps612(uint8_t address=MPU6050_DEFAULT_ADDRESS, void *wireObj=0) : MPU6050_Base(address, wireObj) { }
Expand Down
2 changes: 1 addition & 1 deletion src/MPU6050_9Axis_MotionApps41.h
Original file line number Diff line number Diff line change
Expand Up @@ -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);
Expand Down

0 comments on commit 9a7033a

Please sign in to comment.