Q_TILT_MASK & Misc. VTOL Questions

Hi everyone,

I am working on integrating a Pixhawk 2 into a tilt-wing VTOL aircraft. Below is a picture of the layout. I am wondering how to determine the value of the Q_TILT_MASK parameter. I am running Arduplane 3.8.4 firmware.

As the image shows, motors 1 and 2 do not rotate (they are permanently mounted vertically), motors 3 through 8 all rotate between 0 degrees angle of attack and 90 degrees angle of attack. Motors 1 and 2 are on a single channel, motors 3 and 4 are on a single channel, motors 5 and 6 are on a single channel, and motors 7 and 8 are on a single channel. This essentially forms a Quad+ type frame when in the vertical flight configuration. Currently, here are my channel layouts:

Channel 1: aileron
Channel 2: whole moving stabilator/tail rotation mechanism
Channel 3: skipped
Channel 4: rudder
Channel 5: right wing motors
Channel 6: left wing motors
Channel 7: forward boomed motors
Channel 8: tail motors

These channel outputs are in Pixhawk 2 outputs M1 through M8, respectively. the six AUX ports are currently unused.

If anyone has any knowledge of how to determine the Q_TILT_MASK parameter’s value, it would be greatly appreciated! Additional recommendations for Pixhawk configuration are welcome too!


Seabrook Whyte
Oklahoma State University
B.S. Aerospace Engineering
M.S. Candidate

1 Like

First off, I think you’re a Q_FRAME_CLASS = 2 (hexa)
Your Q_FRAME_TYPE should be = 1 (X frame)

For Hexa-x, look here: http://ardupilot.org/copter/docs/frame-type-configuration.html.

It looks like you will have all motors except 3 and 5 tilting. Masks are based off of

Since 1,2,4, and 6 are tilt motors, set Q_TILT_MASK +1+2+8+32 = 43… I think

I actually have all motors tilting except for motors 1 and 2. The front of the aircraft is at the top of the picture.

Also, the orange 1, 2, 3, and 4 represent a Y-harness between motors. I chose the Quad+ layout to drop all 8 of my motors to 4 channels so I have the option to test the KK2.1.5 flight controller as well since it can only output 8 channels. Although, I am not 100% sure if the Quad+ layout is the best choice, but it is an option I decided I could try.

Hi Seabrook,

Perhaps I am looking at it differently than Nathan but I see a Quad + frame setup or Q_FRAME_CLASS=1.

For hovering, I see the M1 and M2 as the “front” motor and M5 and M6 as the “back” motor. Then M3 and M4 would be the “left” motor, while M7 and M8 are the “right” motor.

Does this work as a starting point? Once we have the frame class, maybe Nathan can explain the tilt mask further. I am having difficulty figuring out the tilt mask.

Note that the diagram below represents the Motor Order Diagram for APM. It determines the Pixhawk Main Out number (add 5 for QuadPlanes) and prop rotation.


Greg is right - you’re in a quad+ configuration. 1, 2, and 4 are all tiltable then.


So use +1+2+8 = 11

Oh, that’s how the mask works! Thanks, Nathan!

Awesome! Thank you both very much! So, let’s say I had all 8 motors rotating (obviously not the case), how would it be figured then? That is, how are you getting the values 4=+8, for example?

Also, with the Pixhawk, do you know if it’s even possible to get motors 1, 2, and 4 to rotate and stay spinning while simply turning off motor 1 as it transitions to horizontal flight?

That’s another issue I haven’t fully figured out yet.


The number on the left is the APM motor inside the Motor Order Diagram. The number on the right is the bit weight (or position) in the mask. So in Nathan’s example, he showing how the bit weights get added up.

That is taken care of in the APM Plane firmware when you have the QuadPlane feature enabled (Q_ENABLE=1) and simply change flight modes from a copter mode like QSTABILIZE to a plane mode like FBWA.

Oh, wait, that was dumb lol. I get it now. it’s simply in order 1, 2, 4, 8, 16, 32, 64, 128, etc… for motors 1, 2, 3, etc…
And ok, thanks!

Ok, so hopefully these will be simple questions, and the last two!

Now, how would one go about assigning SERVO2_FUNCTION to both elevator AND wing tilt? So far I have the parameter SERVO9_FUNCTION = 41 as the main wing rotation mechanism. However, my horizontal stabilizer doubles as an all moving stabilator and rotates 90 degrees for VTOL operations. I could do some mixing in the Futaba 14SG and have that mixing be on the same switch as the mode change switch, but i think that it would be difficult to get the timing right on the speed of rotation, whereas the Pixhawk might have an easier time with it.

Second question: on the Futaba side of things, channels 5 through 8, what should I assign them in the Futaba FUNCTION menu? I know the Pixhawk Parameter side of things (SERVO5_FUNCTION = 33, etc…but would it simply be:
Channel 5: aileron
Channel 6: elevator
Channel 7: throttle
Channel 8: rudder
As if it were setting up a quadcopter on the first four channels on a Futaba radio?


I picked the second question first as it is easier to answer in a short time before work. :slight_smile:

No need to set up anything on the Futaba other than maybe mixing a few switches for more than 2 or 3 flight modes. The channels are already reserved so you simply do a radio calibration in Mission Planner. Follow the Wiki’s step-by-step setup from frame choice to flight modes.

Many of us use the FrSky Taranis X9D+ or newer models with OpenTX firmware. There is a 6-position knob switch on top of the transmitter used for changing flight modes.

With the current ardupilot code, your current proposal won’t work the best for a number of reasons.

  • You cannot assign multiple functions to a servo based on flight mode - motor tilt during vtol, but elevator during fixed-wing mode.
  • During your transition, your tail may be providing a very strong pitch down torque until the transition is complete. Considering your wings are also pivoting, it may help your case, but it will be difficult to control.
  • Stabilators typically need relatively fine, precise movement. By having it pitch 90 degrees or more, you’ll probably run into a challenge with finite pitch tuning/control.
  • Manual control from a transmitter will be difficult with a dynamically changing system
  • Considering the above factors, I would recommend adding a separately controlled elevator surface to your tail stabilator if you intend to use it with ardupilot.

Dang, ok, so I can easily add the extra elevator channel. The servos for the elevator (as well as the control surface itself) are already in the aircraft, I just have them disabled. I did, however fly the aircraft in the CTOL configuration and performed STOL testing by manually rotating the wing in increments (before the Pixhawk was installed), and the whole moving stabilator controlled the aircraft fine when I limited it’s throw, and used about 30% expo. But if the code doesn’t allow this double function, then I will have to scratch the dual purpose thing anyway.

Additionally, I tried some static testing last night, and I was able to get my motors to arm and spin up in the manual configuration (except for the permanently mounted motors, of course), but when i switched the aircraft to QHOVER mode, the motors would turn off and the wing would not rotate. the parameters I have entered (changed from default) are as follow:

Q_THR_MD = 500
SERVO9_FUNCTION = 41 (this is my wing tilting mechanism (one linear actuator that uses PWM input)
SERVO9_MIN = 1000
SERVO9_MAX = 2000
ARMING_RUDDER = 0 (have also tried 2 with no luck)

I also setup the mode switch to channel 10 (and have confirmed it actually switches modes). The modes I have assigned (in order) are: QHOVER, FWBA, MANUAL.

I have also disabled all available arming checks. Basically, I made it so it will allow the aircraft to arm no matter what.

I’m assuming there’s probably something simple that I’m missing, but I’m just not sure what. I followed all of the steps in the quadplane setup and the tilt-rotor/wing setup on this website.

Thanks again for all of your help!

Thank you very much for your input! I think I might have access to a Taranis, but our lab mostly uses the Futaba 14FG.

Q_TILT_TYPE: 0? I’m not much help here…

Use QSTABILIZE instead of QHOVER for your initial tests. This eliminates issues due to the BARO and GPS. Once the craft hovers and controls nicely, then you can test QHOVER and QLOITER before your first transition to forward flight. Also, when testing QHOVER and QLOITER, make sure your Arming checks are enabled.

Here is what I am thinking your setup should be. Did you mention that your rear motors (M5 and M6) had a yaw tilt mechanism on them? If so, it is not needed as the wings motors will be used for yaw control when hovering.

Q_TILT_TYPE=2 (Vectored)

Pixhawk Outputs
Main1: aileron
Main2: elevator
Main3: throttle
Main4: rudder
Main5: right wing motors
Main6: left wing motors
Main7: forward boomed motors
Main8: tail motors
Aux1: Left Motor Tilt (SERVOn_FUNCTION=75)
Aux2: Right Motor Tilt (SERVOn_FUNCTION=76)
Aux3: Tail Motor Tilt (SERVOn_FUNCTION=41)

Thanks for the reply, but I’m not so sure I’ve successfully described the aircraft quite right. Both of the wings rotate together one the same actuator (cannot be controlled separately for yaw), and the whole horizontal stabilizer rotates together (the motors on the stabilizer cannot be pitched differently from each other).

Unless I’m just not reading your reply correctly.

I will post a youtube link as soon as I get a chance. That may clear up some confusion on how things rotate.

Ok, I see now. This is not a typical setup and I do not think you will have yaw control during hover.

I see that Q_TILT_TYPE should be 0 (Continuous) now. What is missing is either individual tilt capability on each wing or a rear motor that can move left or right like on the CL-84 R/C VTOL.

Also, there seems to be added complexity from the front motor. It does not need to be a quad frame but rather a tri-copter. Although either frame should work, it seems that the front motor could be removed and replaced with a larger battery or camera.

So the two front motors were boomed out for added stability and for CG purposes. Since the motors are too small to lift the extra nose weight needed to balance the aircraft. Keeping in mind this is only a first rev concept. Not quite where I want the plane to be (nor enough time to change the design concept).

As for yaw control, I don’t care about that as much, but 2 possibilities are the ailerons for yaw control or just the differential in torque as with a typical multirotor.

So given this information, any ideas why I can’t get the wing to rotate automatically?