#include<Wire.h>
const int MPU_addr=0x68; // I2C address of the MPU-6050
int16_t AcX,AcY,AcZ,Tmp,GyX,GyY,GyZ;
void setup(){
Wire.begin();
Wire.beginTransmission(MPU_addr);
Wire.write(0x6B); // PWR_MGMT_1 register
Wire.write(0); // set to zero (wakes up the MPU-6050)
Wire.endTransmission(true);
Serial.begin(9600);
}
I'm trying to define which wires I want to use for an MPU6050 (3 axis acceleromater/ gryo and thermistor) in order to clean up a project. Using wire.h, I'm using A5, A4 and D2 on the arduino which causes a lot of cross wires and I'm hoping to switch it to A6, A7 and D13 to keep them all on one side of the board. Is that possible or is there a way I can modify the "MPU_addr" to use the pins I want?