Softivation

Why a new Pixhawk won't arm: the frame class warning

If the Pixhawk won't arm and Messages says PreArm: Motors: Check frame class and type, the autopilot doesn't recognize the motors. How to fix it, and the warnings that come next.

Furkan IŞIKAY 5 min read

You flashed the firmware and finished the calibrations, and now you're trying to arm with the transmitter, but the drone doesn't respond at all. A red warning sits on Mission Planner's HUD. When you look at the Messages tab, you see the line starts with Motors:.

This warning says the autopilot doesn't know how many motors it has or which pins to drive them from. On a new board, its most common form is the PreArm: Motors: Check frame class and type line. Once you fix it, another Motors: line may appear after it; that's normal too.

Why the warning won't clear

Before allowing arming, the autopilot checks the motor settings in order: the frame type, whether each motor has an output, the thresholds at which the motors start spinning, and the PWM limits. It stops at the first check that fails and shows only that one on screen.

On a new Pixhawk, the frame class comes undefined (0). If you haven't selected your frame on the Initial Setup > Mandatory Hardware > Frame Type screen, the autopilot can't build the motor mix and the first check always gets stuck here.

The most common mistake: trying to get past it by turning off the arming checks. The Motors: lines ignore the ARMING_SKIPCHK setting (ARMING_CHECK in older versions). Even if you enter -1, the drone won't arm until the frame and output settings are fixed.

Motor4 warning after plugging in the payload servo

You're building a payload drop mechanism for TEKNOFEST. The frame is quad X, the four ESCs are on MAIN OUT 1-4, and the drone arms without trouble. You plug the servo into AUX OUT 4 and, thinking "fourth output", set SERVO4_FUNCTION to Gripper (28) in Mission Planner.

On the next arming attempt, PreArm: Motors: no SERVOx_FUNCTION set to Motor4 appears in Messages, and the servo doesn't move either. The SERVO number counts the board's output order: on the Pixhawk 2.4.8, MAIN OUT 1-8 are SERVO1-8, while AUX OUT 1-6 are SERVO9-14.

Pixhawk 2.4.8 output rail and SERVOn_FUNCTION values

Pixhawk MAIN OUT 1-8 SERVO1-8, AUX OUT 1-6 SERVO9-14. Motors on MAIN 1-4, payload servo on AUX 4, UBEC on AUX 6
Look at the red-framed MAIN OUT 4 column: it must stay 36. The 28 goes in the AUX OUT 4 box (S12).

In the figure, look at the red-framed MAIN OUT 4 column: that column's FUNCTION box must stay 36 (Motor4). AUX OUT 4, where the payload servo is plugged in, is SERVO12, so write 28 on the SERVO12_FUNCTION line. The Pixhawk doesn't power the servo rail. A separate 5V UBEC, plugged into the + and − pins of an empty column, powers the rail.

Basic setup for Quad X

Save the lines below to a text file named quadx.param. In Mission Planner, open the file with Load from File on the CONFIG > Full Parameter List screen, press Write Params and reboot the board.

Parameter filequadx.param
FRAME_CLASS 1
FRAME_TYPE 1
SERVO1_FUNCTION 33
SERVO2_FUNCTION 34
SERVO3_FUNCTION 35
SERVO4_FUNCTION 36
MOT_SPIN_ARM 0.1
MOT_SPIN_MIN 0.15
MOT_PWM_MIN 1000
MOT_PWM_MAX 2000
  • Enter: load the file, press Write Params and reboot the board. If your frame is +, set the FRAME_TYPE line to 0.
  • You'll see: the Motors: line disappears from Messages, and an arming attempt shows Arming motors.
  • If not: read the new Motors: line in Messages and find its match in the Error Messages list below.

If you're building a hexa or an octa, the values change: you need as many SERVOn_FUNCTION lines as there are motors, and the payload servo goes on an output the motors don't use.

One warning goes, a new one appears

Because the checks run in order, if there's more than one error, only the first is shown each time. With frame class 0, SERVO4_FUNCTION 28 and MOT_SPIN_ARM 0.2 (default 0.1), if you press ARM after each fix, you'll see these lines in Messages in order:

Output
PreArm: Motors: Check frame class and type
PreArm: Motors: no SERVOx_FUNCTION set to Motor4
PreArm: Motors: MOT_SPIN_ARM > MOT_SPIN_MIN
Arming motors

If the line changes, the previous check passed and the next one got stuck. If the same line stays, you may have skipped the Write Params step. Re-read the parameter's value on the board with Refresh Params.

Error messages and their meanings

During an arming attempt, the same text also comes once with the Arm: prefix. Both come from the same check.

PreArm: Motors: Check frame class and type

FRAME_CLASS is still 0, or FRAME_TYPE doesn't match the frame class (10 on a quad, i.e. Y6B). Select your frame on the Frame Type screen. If the values look right but the line stays, the installed firmware may not include that frame. In custom builds and on some F4 boards, octaquad isn't included by default.

PreArm: Motors: no SERVOx_FUNCTION set to Motor4

The motor with the number in the line has no output. The function values of Motor1-4 are 33-36. Find the missing value in the SERVOn_FUNCTION list and write it to the output that motor's ESC is plugged into.

PreArm: Motors: MOT_SPIN_ARM > MOT_SPIN_MIN

The idle at arming is higher than the threshold at which the motors start producing thrust. The defaults are 0.1 and 0.15. Lower MOT_SPIN_ARM below MOT_SPIN_MIN.

PreArm: Motors: MOT_SPIN_MIN too high 0.35 > 0.3

The first number in the line is your value. Anything above 0.3 isn't accepted. Lower the value and redo the motor range setup from the start.

PreArm: Motors: Check MOT_PWM_MIN and MOT_PWM_MAX

MOT_PWM_MIN is less than 1, or equal to or greater than MOT_PWM_MAX. Set them to 1000 and 2000, then repeat the ESC calibration.

More in the course

You'll find which firmware file these lines come from, the board-specific differences, and the classification table to use when you have a log in the Troubleshooting section of the Basic Drone Course: From Sensors to Flight.

Was this article helpful?

Free resourceTEKNOFEST UAV software readiness checklistCheck off your team's software readiness stage by stage on a printable list.