semtex Posted May 26, 2016 Report Share Posted May 26, 2016 in this code there is a boolean (mpuIntStatus & 0x02) mpuIntStatus = mpu.getIntStatus(); // get current FIFO count fifoCount = mpu.getFIFOCount(); // check for overflow (this should never happen unless our code is too inefficient) if ((mpuIntStatus & 0x10) || fifoCount == 1024) { // reset so we can continue cleanly mpu.resetFIFO(); Serial.println(F("FIFO overflow!")); // otherwise, check for DMP data ready interrupt (this should happen frequently) } else if (mpuIntStatus & 0x02) when i look at the register where mpu.getIntStatus() gets his value ...Register 58 – Interrupt Status mpu6050 .. I see bit 1 is empty (has no purpose) soo i dont understand the boolean (mpuIntStatus & 0x02) ... witch seem to do a logic AND operation with this bit i must be seeing something wrong ... could anybody help me explaining the boolean (mpuIntStatus & 0x02 ?? grtz Ido lapedNok 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.