EKF Variance Optical Flow Mode

Hi All,

I was out doing an auto Optical Flow calibration and it seemed to complete ok based on the logs.

I am using the following hardware:

  • Pixhawk Cube
  • Lightware SF/11C Range Finder (connected to GPS1 I2C)
  • PX4Flow (connected to I2C port)

I switched the drone into Optical Flow Loiter instead of GPS and it was okay for a couple of seconds until I was getting an “EKF Variance” error where it then entered failsafe mode and landed.

I have been fighting this issue for quite some time now. My suspicion is this:

My range finder seems to be glitching out jumping to 140m range every couple of seconds. I tried to combat this by adding a voltage regulator and powring directly from the board instead of the Pixhawk (no luck). The light ware software doesn’t seem to have an issue reading the data from the device so im kind of lost at this point.

If anyone has any ideas I would love to hear them, thank you!!!

Below is the log file and config parameters.

cube_2022-5-29.param (17.7 KB)

More information here, could this be an issue with Cube Orange? Sure it isnt an issue rather than config param that needs to get changed because of the setup with Cube Orange.

@aniforatos,

Thanks for the report and giving the optical flow calibration a try.

I agree that the issue is most likely the rangefinder which seems to be losing it’s ability to track the ground very often even at relatively low altitudes.

Thank you for the response! I set up a support ticket with Lightware.

It’s strange that this range finder worked with my other setup (Navio 2) and it also works in the Lightware studio when I plug in via USB. I’m not sure if I’m too convinced that it is the range finder.

@rmackay9 that makes many issues related to I2C lidars on H7
Read mine

1 Like

@rmackay9 is this your post ?
http://forum.chibios.org/viewtopic.php?t=5441

@ppoirier,

Txs for the report, I’ve added it to the 4.2 issues list.

That’s not my report although the person’s name is very close to mine which is weird but possible it seems.

@ppoirier and @rmackay9 should the issue also include range finder type 7 for Lightware I2C?

Just sifting through some of the code and I may try and comment this out and try to re-flash the flight controller.

1 Like

Just an update here… Tried to comment that block out and re-built arducopter with that change and it effected nothing; Still had the jumps to max distance every second or so.

I did however find myself a workaround:

  • Bought Voltage Regulators
  • Powered both my PX4Flow and SF11/C from this instead of the Cube.
  • Connected the range finder via Serial on Telem1 port.

Here is a screenshot of the plot:

This seems to be working for me, however, the I2C is a different story; I spoke with Lightware and they are going to investigate on their end as well.

More to come!