Takeoff with multirotor from a metal platform

I’m trying to takeoff with a multirotor from a metal platform that causes magnetic interference to the compass.
I can see a difference of ~20degrees azimuth from what it should be on the ground.

EK3_MAG_CAL is set to 3

EK3_MAG_CAL = 3 uses heading fusion on the ground and 3-axis fusion after the first in-air field and yaw reset has completed, and is the default for copters.

Is there an option to set the heading manually (The UAV takeoff azimuth is fixed) before takeoff, ignore the compass, and use it only after takeoff?
Or, there is any other way to overcome this issue?


The default is designed to cater for your use case so I am told (people taking off from cars).

@danielm1199 Does this seem to be working for you?
@andyp1per are there other parameters that would affect this?

Yes, as @andyp1per said, this is the default, I’ve tested it by takeoff from a metal plate (on the ground 40 degrees difference) and the UAV took off, did yaw compass reset, and flew normally with no problems.