<p>Once you've performed the necessary resource remapping commands to assign the extra motor functions (<em>e.g. M5, and M6</em>) to alternative pads on your flight controller, you can then set up custom mixer rules to tell Betaflight what to do with the additional motors.</p>

<p>However, if one of the <a href="https://github.com/betaflight/betaflight/blob/master/docs/Mixer.md#supported-mixer-types" rel="nofollow noreferrer">predefined mixer types</a> works for your build, you can just load it using the Betaflight Configurator or via the CLI by sending the command <code>mmix load &lt;name&gt;</code> where <code>&lt;name&gt;</code> is one of the mixer types from the link above.</p>

<p>Otherwise, you'll need to configure your own mixer rules. Following the <a href="https://github.com/betaflight/betaflight/blob/master/docs/Mixer.md#custom-motor-mixing" rel="nofollow noreferrer">instructions from the Betaflight Wiki</a>, you'll need to use the CLI in the Betaflight Configurator to formulate and send <code>mmix</code> commands.</p>

<ol>
<li>First, you'll need to send <code>mixer custom</code> to enable custom mixing.</li>
<li>Send the <code>mmix reset</code> command to remove any existing mixer rules.</li>
<li>For each of the motors you need (<em>starting with <code>M1</code> and ending with <code>M6</code> for your hexacopter</em>) send an <code>mmix</code> command with the following space-separated parameters:

<ul>
<li>Motor number for the rule (<em>in the range 0-5, so subtract one from the M motor port number</em>).</li>
<li>Number from 0.0 to 1.0 indicating how much <em>throttle</em> should be mixed into this motor. If this motor shouldn't be affected by the throttle, enter 0.0.</li>
<li>Number from -1.0 to 1.0 indicating how much <em>roll</em> should be mixed into this motor, where positive numbers mean that a roll command over 1500µs should increase the motor's power and vice versa. If this motor shouldn't be affected by the roll axis, enter 0.0.</li>
<li>Number from -1.0 to 1.0 indicating how much <em>pitch</em> should be mixed into this motor. This value obeys the same conventions as the roll axis parameter.</li>
<li>Number from -1.0 to 1.0 indicating how much <em>yaw</em> should be mixed into this motor. This value obeys the same conventions as the roll axis parameter.</li>
<li>An example <code>mmix</code> command is: <code>mmix 0 1.0 0.0 -1.0 -1.0</code></li>
</ul></li>
<li>Remember to send the <code>save</code> command to save your new mixer configuration.</li>
</ol>

<p>This is all quite confusing, so here's an example from <a href="https://github.com/betaflight/betaflight/blob/master/docs/Mixer.md#custom-motor-mixing" rel="nofollow noreferrer">the same Betaflight Wiki page</a> showing what the mixer commands would be like to use the <code>M1</code>, <code>M2</code>, <code>M3</code>, and <code>M5</code> ports if te <code>M4</code> port were broken on your flight controller.</p>

<pre><code>mixer custom
mmix reset
mmix 0 1.0, -1.0, 1.0, -1.0
mmix 1 1.0, -1.0, -1.0,  1.0
mmix 2 1.0, 1.0, 1.0, 1.0
mmix 3 1.0, 0.0, 0.0, 0.0
mmix 4 1.0, 1.0, -1.0, -1.0
save
</code></pre>

CC BY-SA 4.0
2020-05-06T10:11:16.393Z
This is an excellent, explanation, thank you.
Drones and Whatnot
CC BY-SA 4.0
2020-05-06T16:23:57.493Z
No problem, @DronesAndWhatnot ! Sorry again about the confusion on the above question.
ifconfig
CC BY-SA 4.0
2020-05-06T22:11:34.170Z
no worries, glad we got it cleared up :)
Drones and Whatnot
CC BY-SA 4.0
2020-05-06T00:57:29.080Z
2020-05-06T00:57:29.080Z
ifconfig
<p>First, whilst this post is mainly about how to program in Betaflight, it also involves ESC layout so I feel it is appropriate for this Stack Exchange.</p>

<p>For example, I intend to create a frame that is in a dead cat format with the front two arms spread further apart, but in the form of a hexacopter. I assume this process will be the same for copters with other numbers of motors.</p>

<p>I also need to configure the six ESCs for the motors, however I am using an F7 flight controller (in this case an Omnibus F7 Pro) and as such only have 4 motor outputs.</p>

<p>I know that I need to map 2 motor outputs to timer-equipped pads, however once I have done that I need to add a custom motor mix for the frame I have designed, using the two motors I have remapped. How can this be done using Betaflight?</p>

CC BY-SA 4.0
2020-05-05T23:50:35.953Z
I think this question is too broad. What I hear is how can I configure a multirotor with X motors on any given F4 or F7 FC board. I think one or both of those would need to be specified further.
ifconfig
CC BY-SA 4.0
2020-05-05T23:51:09.763Z
@ifconfig I’ll edit it to make it more specific
Drones and Whatnot
CC BY-SA 4.0
2020-05-05T23:59:09.943Z
I meant specifying *which* FC you're using. Instructions will likely differ based on what pads yours has broken out and where.
ifconfig
CC BY-SA 4.0
2020-05-06T00:01:29.250Z
@ifconfig I’ve edited it to make it more specific
Drones and Whatnot
CC BY-SA 4.0
2020-05-06T00:15:41.373Z
Oh, how wrong I was. After looking into it, it appears that this can actually be agnostic of motor quantity and FC board as long as you are only asking about the mixer setup. You can remove your edits if you'd like. I apologize for the confusion.
ifconfig
CC BY-SA 4.0
2020-05-06T10:12:11.970Z
@ifconfig no worries - thank you for coming back and saying when you were wrong - that virtue is increasingly rare on the internet! I’ll edit my post to make it more generalised, but not completely revert it.
Drones and Whatnot
<betaflight><esc>
How can I set up appropriate motor mixing for a frame of a custom layout?
Drones and Whatnot
# How can I set up appropriate motor mixing for a frame of a custom layout?

(Asked by: username_0 on 2020-05-05)

First, whilst this post is mainly about how to program in Betaflight, it also involves ESC layout so I feel it is appropriate for this Stack Exchange.

For example, I intend to create a frame that is in a dead cat format with the front two arms spread further apart, but in the form of a hexacopter. I assume this process will be the same for copters with other numbers of motors.

I also need to configure the six ESCs for the motors, however I am using an F7 flight controller (in this case an Omnibus F7 Pro) and as such only have 4 motor outputs.

I know that I need to map 2 motor outputs to timer-equipped pads, however once I have done that I need to add a custom motor mix for the frame I have designed, using the two motors I have remapped. How can this be done using Betaflight?

**Tags:** betaflight, esc
> **Comments:**
> **username_1**: I think this question is too broad. What I hear is how can I configure a multirotor with X motors on any given F4 or F7 FC board. I think one or both of those would need to be specified further.  
> **username_0**: @ifconfig I’ll edit it to make it more specific  
> **username_1**: I meant specifying *which* FC you're using. Instructions will likely differ based on what pads yours has broken out and where.  
> **username_0**: @ifconfig I’ve edited it to make it more specific  
> **username_1**: Oh, how wrong I was. After looking into it, it appears that this can actually be agnostic of motor quantity and FC board as long as you are only asking about the mixer setup. You can remove your edits if you'd like. I apologize for the confusion.  
> **username_0**: @ifconfig no worries - thank you for coming back and saying when you were wrong - that virtue is increasingly rare on the internet! I’ll edit my post to make it more generalised, but not completely revert it.  

---

## 1 answers

### Answer by username_1 on 2020-05-06. Score: 3

Once you've performed the necessary resource remapping commands to assign the extra motor functions (e.g. M5, and M6) to alternative pads on your flight controller, you can then set up custom mixer rules to tell Betaflight what to do with the additional motors.
However, if one of the predefined mixer types works for your build, you can just load it using the Betaflight Configurator or via the CLI by sending the command mmix load  where  is one of the mixer types from the link above.
Otherwise, you'll need to configure your own mixer rules. Following the instructions from the Betaflight Wiki, you'll need to use the CLI in the Betaflight Configurator to formulate and send mmix commands.

First, you'll need to send mixer custom to enable custom mixing.
Send the mmix reset command to remove any existing mixer rules.
For each of the motors you need (starting with M1 and ending with M6 for your hexacopter) send an mmix command with the following space-separated parameters:


Motor number for the rule (in the range 0-5, so subtract one from the M motor port number).
Number from 0.0 to 1.0 indicating how much throttle should be mixed into this motor. If this motor shouldn't be affected by the throttle, enter 0.0.
Number from -1.0 to 1.0 indicating how much roll should be mixed into this motor, where positive numbers mean that a roll command over 1500µs should increase the motor's power and vice versa. If this motor shouldn't be affected by the roll axis, enter 0.0.
Number from -1.0 to 1.0 indicating how much pitch should be mixed into this motor. This value obeys the same conventions as the roll axis parameter.
Number from -1.0 to 1.0 indicating how much yaw should be mixed into this motor. This value obeys the same conventions as the roll axis parameter.
An example mmix command is: mmix 0 1.0 0.0 -1.0 -1.0

Remember to send the save command to save your new mixer configuration.

This is all quite confusing, so here's an example from the same Betaflight Wiki page showing what the mixer commands would be like to use the M1, M2, M3, and M5 ports if te M4 port were broken on your flight controller.
mixer custom
mmix reset
mmix 0 1.0, -1.0, 1.0, -1.0
mmix 1 1.0, -1.0, -1.0,  1.0
mmix 2 1.0, 1.0, 1.0, 1.0
mmix 3 1.0, 0.0, 0.0, 0.0
mmix 4 1.0, 1.0, -1.0, -1.0
save

> **Comments:**
> **username_0**: This is an excellent, explanation, thank you.  
> **username_1**: No problem, @DronesAndWhatnot ! Sorry again about the confusion on the above question.  
> **username_0**: no worries, glad we got it cleared up :)  

---

