Phoebe Is Losing Gravity Readings; Integration’s Mauled Zoe
Sorry it’s been quiet for a few days; I’ve been trying to get to the bottom of the manic leap-into-the-air problems I’ve had with Phoebe and Zoe. It’s not solved yet, but I’m getting a better idea of why it might be happening. The symptoms are the same, but I believe the cause is different.
With Zoe, the manic climb only happened when I put on the carbon props; with the floppy props all was ok. She was running with the accelerometer scale set to ±2g. The flexibility of the floppy props softened vertical acceleration sufficiently to prevent any peaks above 2g during ascent. My speculation is that with the carbon props, she did breach the 2g limit. That means she’d be under reading acceleration leading to the integrated vertical velocity being lower than it actually was, meaning the PIDs turned up the props speeds, and off she shot. However, I’ve not had the chance to test this theory as I’ve been waiting for some replacement parts – props, arm, slimline set of connectors and a new MPU to build a much sleeker HoG for her. I’ll post again when this is done, and hopefully be able to show off the improvement.
Phoebe’s case is different; for her she’s getting FIFO overflows. At the start of the flight, she gets one good read of data, and then every further read is shifted by 4 bytes so the codes believes each FIFO data batch consists of ax, ay, az, gx, gy, gz, but what it’s actually getting is az, gx, gy, gz, ax, ay. I now have lots of error checking to ignore such batches and this has revealed that I only get one good batch of sample data before the code spots the next batch is corrupt and aborts the flight. It seems the code isn’t running fast enough to stop the FIFO overflowing; I’ve been doing various tweaks to the code to ensure the code is synchronized with the sensors, and that time usage is optimized – calls to time.time() have gone, as are a lot of the diagnostics. The one remaining thing is that the FIFO is filled at the sampling rate, not the register update rate; Phoebe’s been running at 500Hz but her sampling is 1kHz. With Zoe, both are set to 1kHz. Next step is to try that and see what happens.
I’ll update you when there’s something worth sharing about both Phoebe and Zoes’ progress.