Cannot takeoff using mavlink

Hello,
I’m trying to start an automatic mission from my custom software.
I have two problems:

1- then I load a mission, lets say a 6 steps mission, ardupilot correctlry asks gor steps 0,1,2,3,4,5 and then a mission success message is sent
However, the first step (step 0) is not listend in the mission when loaded by mission planner

2- I cannot takeoff! or better… I can set AUTO mode, the I issue a MAV_CMD_COMPONENT_ARM_DISARM, but then the drone disarms
I try to arm from mission planner and a preflight impossible to arm is returned… I force arm but no takeoff.
The only way to takeoff is using the “resume mission” from mission control with step=1, but I have no idea of the messages it produces.
I sent a MAV_CMD_NAV_TAKEOFF and MAV_CMD_MISSION_START, both fails I have no idea why

Can anyone guide me in the correct sequence of mavlink commands to send to ardupilot to takeoff?

Set mode to guided
then send arm and after a second a takeoff.
If you reached 15m altitude, then you can switch to auto

Really?
So I have to reach 15 meters…
It’s strange, beacause if I run “resume mission” from mission planner it works and the whole mission is under 5 meters…
however thank you very much… I’ll try tomorrow.

It’s not about the altitude.
Commanded takeoff is only possible in guided mode.
You can start auto anytime after takeoff is started.