Jump to content
I2Cdevlib Forums


  • Posts

  • Joined

  • Last visited

andrewic's Achievements


Newbie (1/14)



  1. Answering my own question... The order of events in the code was wrong, the offsets were being loaded and then overwritten by a reset. Andrew
  2. Hello, I am having some trouble with offsets.... I can run the calibration script, have it converge, get some sensible offsets, plug them into the RAW sketch and then get good results (i.e. close to zero on X, Y accels and on all 3 gyros) using getMotion6(). So far so good. But my real application is interrupt driven, and I'm basing it closely on the DMP6 sketch. I plug my offsets into my version of that sketch, which loads the FIFO on interrupt with getFIFOBytes(), and then uses dmpGetAccel() and dmpGetGyro() to read the raw values from the FIFO packet. And when I do that, the results are rubbish, my X accel goes from close to zero to ~200. Same sensor, same Arduino, firmly fixed and unmoved on the same desk. Switch back to the RAW script, all is good again. Any ideas what I might be doing wrong? (What I want to get to eventually is a sketch which runs a self-calibration of the X axis accel offset at startup, and sets the offset accordingly, because in my eventual use case setting up the sensor and clamping it accurately horizontal will be difficult. I only really care about the X-axis accel and gyro.). Thanks for any tips! Andrew
  • Create New...