Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add MPU6050 library and sample code #2655

Merged
merged 21 commits into from
Nov 9, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix typos
  • Loading branch information
xeonqq committed Nov 8, 2023
commit 850afe0ce493ac4d1276af123d4f4ee4fa84a223
2 changes: 1 addition & 1 deletion Sming/Libraries/MPU6050/MPU6050.cpp
Original file line number Diff line number Diff line change
@@ -6,7 +6,7 @@
// Changelog:
// ... - ongoing debug release

// NOTE: THIS IS ONLY A PARIAL RELEASE. THIS DEVICE CLASS IS CURRENTLY
// NOTE: THIS IS ONLY A PARTIAL RELEASE. THIS DEVICE CLASS IS CURRENTLY
// UNDERGOING ACTIVE DEVELOPMENT AND IS STILL MISSING SOME IMPORTANT FEATURES.
// PLEASE KEEP THIS IN MIND IF YOU DECIDE TO USE THIS PARTICULAR CODE FOR
// ANYTHING.
4 changes: 2 additions & 2 deletions Sming/Libraries/MPU6050/MPU6050.h
Original file line number Diff line number Diff line change
@@ -2,7 +2,7 @@
// (RM-MPU-6000A-00)
// Based On https://github.com/jrowberg/i2cdevlib

// NOTE: THIS IS ONLY A PARIAL RELEASE. THIS DEVICE CLASS IS CURRENTLY
// NOTE: THIS IS ONLY A PARTIAL RELEASE. THIS DEVICE CLASS IS CURRENTLY
// UNDERGOING ACTIVE DEVELOPMENT AND IS STILL MISSING SOME IMPORTANT FEATURES.
// PLEASE KEEP THIS IN MIND IF YOU DECIDE TO USE THIS PARTICULAR CODE FOR
// ANYTHING.
@@ -3427,7 +3427,7 @@ template <typename T> T MPU6050::readReg(uint8_t regAddr)

const auto sz = sizeof(T);
uint8_t buffer[sz] = {0};
//data follow big endien convention
//data follow big endian convention
I2Cdev::readBytes(devAddr, regAddr, sz, buffer);

T result{};
Loading