Loiter mode pitch drift with marvelmind

Hello!
While testing Marvelmind for Indoor GPS, I’ve found a problem with loiter mode.
I started from Stabilize Mode and all seems good. When I changed to Loiter Mode, the Desired Pitch drift to the opposite side of my pitch command (see the first picture).
I also tried to lift the drone without touching the pitch-stick of the RC but when I selected the Loiter Mode, then the desired pitch start drift again (see the second picture)…
Does anyone knows how to fix this problem? Thankyou in advance

I suspect it must be that Loiter’s position target is drifting, or that the drone’s position is drifting away from the target, which may indicate something wrong with the Marvelmind beacon navigation. Check NTUN.PosX and DPosX.

Also upload your flight logs so we can take a look.

Thakyou for your reply!
I checked the NTUN.Posx and NTUN.DPosX: as you can see in the picture, they are drifting in opposite directions.

Here you can find the flight-log…
flightlog.zip (718.9 KB)

Ah yes, so what you observed is certainly caused by an incorrect position estimate, which I would guess might be caused by your Marvelmind setup. Unfortunately, I don’t have any experience with beacon navigation like the Marvelmind or Pozyx, so I’m not sure how much I can help. That the PosX diverges more quickly over time might mean that you have the orientation backwards, causing the drone to fly away faster as it gets farther away from the target.