I have a PXFmini on a Pi3 running the escarlata image, and I'm having an issue where the quadcopter flips over on takeoff. I have set the RC map correctly and calibrated the accelerometer, but when I give the quad throttle, it just tries to tip forward. I've ruled out any issues with the motors by flipping which direction was forward, and recallibrating the accelerometer, after which the quad would tip towards its new "forward". Before each of these tests, I connected to the quad with APM planner and confirmed that the level horizon moved as expected when I tilted the quad, and that the RC channels were mapped correctly. In addition, I've tried to takeoff in acro, stabilize, and loiter flight modes and all three have had the same problem. My current guess is that the gyros are oriented differently from the accelerometer, but I can't find any variable to change that. Any thoughts would be appreciated.