Skip to content

Commit

Permalink
fixed wire begin overload bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Gitshaoxiang committed Jan 25, 2022
1 parent 3f701eb commit 6fc5dd1
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
.DS_Store
.vscode/*
2 changes: 1 addition & 1 deletion examples/ATOM_BASE/ATOM_FLY/AtomFly.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ AtomFly::~AtomFly()

void AtomFly::begin()
{
Wire1.begin(25, 21, 10000);
Wire1.begin(25, 21, 100000UL);

_bmp = new Adafruit_BMP280(&Wire1);

Expand Down
2 changes: 1 addition & 1 deletion src/M5Atom.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ void M5Atom::begin(bool SerialEnable, bool I2CEnable, bool DisplayEnable)

if (I2CEnable)
{
Wire.begin(25, 21, 100000);
Wire.begin(25, 21, 100000UL);
}
if (SerialEnable)
{
Expand Down
2 changes: 1 addition & 1 deletion src/utility/MPU6886.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ int MPU6886::Init(void){
unsigned char tempdata[1];
unsigned char regdata;

Wire1.begin(25,21,100000);
Wire1.begin(25,21,100000UL);

I2C_Read_NBytes(MPU6886_ADDRESS, MPU6886_WHOAMI, 1, tempdata);
Serial.printf("%02X\r\n",tempdata[0]);
Expand Down

0 comments on commit 6fc5dd1

Please sign in to comment.