Will it work ? MPU6050 Gyro etc. etc. module
Code would normally look like this

#include &lt;MPU6050.h&gt;
#include &lt;Wire.h&gt;

MPU6050 mpu;

void setup() {
  Serial.begin(115200);
  Wire.begin();
  mpu.initialize();
}

void loop() {

  //what is this doing for you?
  mpu.getWaitForExternalSensorEnabled();

  if(mpu.getIntDataReadyStatus() == 1) { 
        float X = mpu.getRotationX();
        float Y = mpu.getRotationY();
        float Z = mpu.getRotationZ();
        Serial.print("X:");
        Serial.println(X);
        Serial.print("Y:");
        Serial.println(Y);
        Serial.print("Z:");
        Serial.println(Z);    
  } else
  {
        Serial.println("MPU not ready");    
  }


}