Softivation

Choosing an autopilot? Check these four differences first

ArduPilot or PX4? Both can be installed on the same Pixhawk board, but mode names, parameter names, and waypoint mission support don't match. Look at four differences.

Furkan IŞIKAY 5 min read

Same board in your hands, but what you expected isn't there

You got the board, installed a firmware, and the mode you expected isn't on screen. Or you tried a friend's setting and that parameter doesn't show up for you.

The problem isn't the board but the autopilot software you installed. Both ArduPilot and PX4 can be installed on the same Pixhawk. Once installed, mode names, parameter names, and mission support don't match. There are four places to look before choosing.

Difference 1: mode names aren't shared

In ArduPilot the return-home mode is named RTL. In PX4 the same job is called Return, and in BetaFlight it's GPS Rescue.

All three take the vehicle to the takeoff point but they aren't the same thing. GPS Rescue is a rescue feature, put there to kick in when the link is lost.

Difference 2: autonomous mission support isn't at the same level

If you'll be flying routes, this is the deciding difference. Waypoint missions have been in production use for a long time in ArduPilot and PX4. INAV has them too; since version 4.0 it can store 120 waypoints.

On the BetaFlight side the waypoint infrastructure is new and the developers mark it as experimental. Their documentation says it shouldn't be used on a real vehicle. The sentence "BetaFlight now flies missions too" is incomplete for today.

The number of waypoints your mission needs determines the firmware choice. Jobs like mapping run to hundreds of points.

Difference 3: the bootloader doesn't change with the application

The board has two separate layers: the bootloader below and the application above. When you install firmware, only the application on top changes; the bootloader below stays in place.

The reason both firmwares can be installed on the same Pixhawk is that the two sides use the same board IDs: 9 for FMU_V3, 53 for FMU_V6X.

If you're writing to a blank board for the first time, you need to choose the version that includes the bootloader (_with_bl), otherwise the board is no longer recognized once unplugged from USB.

Difference 4: parameter names aren't fixed

If a setting you found on a forum doesn't appear for you, the parameter may not have been deleted; its name may have changed. With ArduPilot Copter 4.7, several parameters were both renamed and changed units.

Copter 4.6 and earlierCopter 4.7What changed
ARMING_CHECK = 1ARMING_SKIPCHK = 0meaning inverted
RTL_ALT = 1500 cmRTL_ALT_M = 15 munit cm → m
WPNAV_SPEED = 1000 cm/sWP_SPD = 10 m/sgroup prefix and unit
FS_THR_ENABLE = 1FS_THR_ENABLE = 1unchanged
BATT_LOW_VOLT = 10.5 VBATT_LOW_VOLT = 10.5 Vunchanged

The sneakiest one is the first row. Before, you selected the checks to perform; now you select the checks to skip. The meaning has flipped. If you enter a value from an old guide as is, you'll do exactly what you didn't want.

The most common mistake: when a parameter doesn't appear in the list, thinking "this firmware doesn't support it." First check whether the name has changed.

If you're writing a ground station, the raw mode number differs too

The mode difference shows up in the ground control station too. In telemetry, the raw equivalent of the mode is the custom_mode field in the HEARTBEAT message. In ArduPilot this is a plain number. PX4 splits the same information into two fields, main_mode and sub_mode, and packs them into one number.

ArduPilot modecustom_modePX4 equivalentmain / sub
STABILIZE0Manual1 / 0
ALT_HOLD2Altitude2 / 0
AUTO3Mission4 / 4
GUIDED4Offboard6 / 0
LOITER5Position3 / 0
RTL6Return4 / 5

If you put these modes in order in ArduPilot and read custom_mode in HEARTBEAT, you see the numbers on the left. For how PX4 turns two fields into a single number, see the return-home example in the figure.

Return-home mode in the custom_mode field of HEARTBEAT

In ArduPilot the RTL custom_mode value is 6, in the lowest byte. In PX4 Return mode, main_mode 4 is written to the bit 23-16 range and sub_mode 5 to the top byte, and the number becomes 84148224.
Where to look: the position of the filled boxes. ArduPilot puts the number in the lowest byte. PX4 places the main mode and sub mode in the top two bytes, so the raw value for the same job comes out completely different.

A field that appears with the same name on the same screen carries a different raw value in the two firmwares. If you're writing your own ground station code, you need to know which firmware you're connected to when decoding the mode from the number.

Example: In your C# ground station you coded the mode box to show "RTL" when custom_mode 6 arrives, and it works fine on your own drone. In a swarm flight, when a teammate's PX4 vehicle connects, the same return home arrives as 84,148,224 and your box stays empty. Without knowing which firmware you're connected to, you can't decode this number correctly.

Error Messages and Their Meanings

The following are messages that appear on screen in ArduPilot.

PreArm: GPS 1: Bad fix

The GPS module can't produce a position. ARM isn't permitted. Check, in order, the antenna's view of the sky, the satellite count, and the module's power supply.

Arm: GPS 1: Bad fix

Same check, different moment. The "PreArm:" prefix comes during the pre-arm scan, and the "Arm:" prefix comes the moment you give the ARM command. Reading the prefix tells you where the problem was caught.

PreArm: Need Position Estimate

The autopilot doesn't know where it is. Even with a GPS fix, the position estimate may not have settled yet; waiting a few seconds is often enough.

PreArm: High GPS HDOP

The satellite count is sufficient but the satellites' spread across the sky is poor. Moving to an open area helps more than increasing the satellite count.

MAV_CMD_DO_MOTOR_TEST was denied

The motor test was rejected. The most common cause for people moving from PX4 to ArduPilot is that the frame type was never defined. In this case you need to redo the setup from scratch.

In PX4 the same information comes with a different prefix, for example Preflight Fail: ekf2 missing data. In PX4 this text is the secondary channel; the primary channel is the event ID. Knowing that the prefix changes with the firmware shortens your search time when you look up an error.

More in the course

Which firmware the board runs, in what order the prearm check chain runs, and which line of the firmware the message you see comes from are covered step by step in the course.

See the course: Basic Drone Course: From Sensors to Flight

Was this article helpful?

Free resourcePixhawk and ArduPilot error message glossaryThe messages in this article and similar ones are in the glossary: what they mean, why they appear, what to check first.