Unable to start flight in autonomous mode

We want to fly autonomously with our vehicle. After loading the waypoints on the vehicle, we go to an open area and wait for the GPS to reach enough satellites. then we put it in auto mode when the gps light turns green. A warning beep sounds and it does not switch to auto mode. After flying a little in stabilized mode, there is no problem when you switch to autonomous mode while in the air. We can’t fix the problem and we need help. I am attaching the flight logs at the bottom of the article. Our flight control board is Mro Pixrace Pro.

Your flight mode change fails because your vehicle still lacks position.

If you enable the circular fence around home, ardupilot will retrieve you a pre-arm message error until it consolidates home position, and may help you not arming without it.

1 Like

Pre-arm check for GPS, start in guided mode and then after takeoff have the code switch to auto mode.

The problem is we are participating in a competition and we have to take off and fly and land directly autonomously.

I meant ‘stabilize’ in my previous message, not ‘guided’. You cannot arm in auto mode.



Sure you can. You can also set it so you don’t have to raise the throttle to start the mission. But you still have to wait until EKF is using GPS.

Perhaps the AUTO_OPTIONS was set to zero, which I understand to mean you cannot arm in AUTO mode as is stated?

Perhaps I missed the point of your post. 0 is default and it will not Arm in Auto, right. But his problem is he was trying to switch to Auto before EKF was using GPS. Just because the GPS LED turns green, as he stated, doesn’t mean that a proper position estimate has occurred yet.


1 Like

Is there a param setting for the code to ensure EKF is happy to allow arming?

Set fence enable , then you can’t arm in any mode until Home can be set (good 3D fix). If you have the multicolor flight controller LED it will turn solid green.

1 Like

I think @BrunoBagarini suggestion is good by setting a Fence. I wait for the message to appear on my Transmitter before arming. I suppose the question @alperen_ozalp has is what can be done to speed up the process. I’m not sure what’s allowed in that Teknofest competition as far as powering the Craft before running the course.

1 Like

We waited for EKF, but it did not happen again. What do you think could be the problem? What should we try? log file in drive link.

Just a sanity check: Did you add a takeoff command before the first waypoint in your mission? Just before the initialization failed message you can see a missing takeoff cmd message.
I think you need to change the AUTO_OPTIONS parameter as well. If I remember correctly, in order to takeoff in auto without pilot input, you’re going to need to check the ‘Allow Takeoff Without Raising Throttle’ and ‘Allow Arming’ options.


As @airton_dep said you will get the Failed Initialization message w/o a Take-off command in the plan.

1 Like

Thank to all of you guys. Problem solved by changing AUTO_OPTIONS parameter from 0 to 1.

1 Like