Unexpected behaviour in Precision Landing (with Raspberry Pi 3)

Hello everyone,
I’m actually trying to perform precision landing with a companion computer (RaspberryPi 3B) and a camera searching ArUco markers.
I managed to send MAVLink landing_target messages to the Pixhawk with a python script inspired in this example, and I have verified that the messages are OK with MAVLink Inspector.

However, when I tried to attempt the precision landing in the field, the drone started shaking and flying away the marker very quicly. After searching in the community, I repeated the takeoff and land with different parameters sets, changing PLND_EST_TYPE and PLND_ACC_P_NSE, even changing LAND_REPOSITION with no success in any case.

The logs show that the PL.Heal is always 1 and the target is acquired, but the drone start moving very fast with almost 200 deg/sec pitch rate.

The general setup is a quadcopter
Pixhawk 4 , Arducopter 4.0.5
Tarot X4
Raspberry Pi 3 B v1.2 with RaspiCam

It’s important to say that a couple months ago I had the same type of problem with an old IR-Lock, reason why I started to work in the Raspberry PrecLanding.

Here you can find the LogFiles

I have not used precision landing but I’m interested,
Is there any orientation of sensor setting that has to be set/checked, was just thinking it sounds like it sees the marker but then moves the wrong way to close on the target? Just a guess. Is there any way you can check the direction of the behavior of the precision landing corrections by moving the copter above the marker by hand?

I have the same issues using IR-Lock. Precision Landing is broken I advice DO NOT USE PLND AT ALL or you will risk a crash, grave injury, or death.

Hi @Scott_Nunan! In my case the camera has the same orientation as the Pixhawk, and yes, I could read the landing_target message in Mission Planner moving the copter by hand and the messages are fine. The measure has less than 5 degrees of error, indeed, and I also checked the translation to radians (just in case).
Once the copter gets the information about the position of the marker the next steps are done by the Ardupilot.

@JimmyU do you know which was the last release that could correctly perform the PLND?

From my reading here on the board the last time PLND worked correctly was version Arducopter 3.5. Since the 3.6 update PLND has been broken and it’s been reported over and over on this board. I just tried using it recently, should have searched more beforehand.

That makes sense, because I tried downgrading the copter to 3.6.7 yesterday, with the same results than 4.0.5. Unfortunately Arducopter 3.5 isn’t available for Pixhawk 4, so i’m running out of ideas.