Understanding motor numbering

I understand that you’re using an X frame. The default ArduPilot X motor order is what we derived.

Many ESCs intended for use with Betaflight are numbered like yours, intended to be connected like you’ve done, and so the motor order becomes very easy when you set BETAFLIGHT X as the frame type.

If you want to prove this, change FRAME_TYPE to 12 and renumber the outputs to 1-4, sequentially. You’ll get the same result that you have right now (with no other impacts).

Run Motor test.
Write down the order it is running when the A-D buttons are pressed.
It’s wrong. So re-factor the Servo functions until it’s right.
Move on to the next step in configuration.

This procedure had been effective for people that know nothing about Arducopter. There are 4 outputs with a proscribed order that you can define with the frame_type parameter. Just do it. You could do it by trial and error and get it right eventually.

Dave, I am still not sure I have this correct.
Question.

In motor test, when I press A does that activate servo 1? Likewise if I press B does it activate servo 2, C activates servo 3, and D activates servo 4?

Is this correct?

Negative. For the default X order, A operates whatever output is assigned to Motor1, B operates the output assigned Motor4, etc.

For example, on a Cube autopilot, you typically connect the ESC to servo outputs 9-12. So your Copter’s servo outputs would look like this on a Cube (if wired similarly):
Servo9=Motor4
Servo10=Motor1
Servo11=Motor2
Servo12=Motor3

Or, using FRAME_TYPE=12 on a Cube:
Servo9=Motor1
Servo10=Motor2
Servo11=Motor3
Servo12=Motor4

My concern is whether or not the Yaw is working correctly. I have Roll ,Pitch, and Throttle working properly.

So, If i move hte left stick the the left, I would expect a CCW rotation of the drone. Will this happen based on the motor spin directions? I would think that for a CCW yaw I would want motors 3-4 active (D,B).

I think if the motors are turning CW, then the drone would turn CCW. Right??

I best check this.

That’s not how multirotor yaw works. Yaw is achieved by creating a torque moment on the frame by slowing 2 motors rotating the same direction and increasing motor speed on the opposite 2.

If the motor test is correct, and your yaw stick decreases PWM output when moving it left, then the Copter should behave properly.

Again, your static ground tests will be inconclusive because the control loops are interrupted by erroneous gyro output. I suppose I can stop repeating myself because you are bound and determined to ignore it.

Before your first flight, be sure to use this page to set the initial tuning parameter set:

I have an issue with this page you just displayed. I have tried to change the prop length from 9 to 10, but it always comes back to 9 again. There is no save button here. Do I have to set it to 10, then disconnect, and then reconnect???

First, I do think I can determine proper motor operation on my bench.

If I arm the drone, turn the throttle to just barely turning, then raise the back of the drone, the gyro should detect the tilt and then turn on the front motors. This is what happens. The same thing can be done with roll.

As to yaw, when the drone is banalanced, i.e. stable, then all motors should turn equally. However, if I now turn the drone CCW (looking from the top) the twist is detected and motors 3 and 4 activate to counter the yaw. This is normal and repeatable.I can twist the drone ccw then cw the ccw and etc and the motors will change first 3-4, then 1-2.

If the faster motors are turning CW, then the resulting twist on the drone woujld be to twist it in the opposite direction. I think this is the case with our final configurations but I will test further.

I woujld like to know what happens when I press the TestA button? what is activated? It has to be something, yes, what? Servo 1??

You set all of the values, then click “Calculate Initial Parameters.” That is, in essence, the save button.

I won’t entertain further discussion regarding invalid ground tests. NOWHERE IN ANY DOCUMENTATION are you led to do so. Everything we are doing for initial calibration and setup is to avoid the need to make such (foolish) attempts.

And for the last time, as directly as I can put it:
You set SERVO outputs to Motor functions.
You click “A” on the motor test page.
The SERVO output assigned to Motor function 1 is activated.
You click “B” on the motor test page.
The SERVO output assigned to Motor function 4 is activated.
And so on…

I really don’t understand how you cannot simply follow the procedure outlined in the Wiki for using Motor Test, where an illustration of an X-quad is shown, and set the Servo outputs so it’s correct. There is nothing more to say about that. Set the outputs until it’s correct and move on ,this step has been beaten to death.

Or is this just trolling?

Dave ,Yuri. The reason I question the procedures is because I am interested in knowing the details of what is happening. I be in school, you guys were “just plug into the formula” kind of people. I on the other hand did not use formulas because I understood the basics of the situation.

If I just wanted a drone, I would have just bought one, flew it, crashed it, and tossed it. I am going to keep trying to learn as much as possible about the mapping of the servos and why they are the way they are.

If you do not like my continued asking of questions and why things are like they are, then just do not respond in the future, OK? Hopefully someone else will.

I understand that you’re new. And I understand a thirst for knowledge. You have me pegged completely wrong (as you’ll likely see if you look at the other topics where I am involved).

Your repeated asking of the same question and subsequent lack of answering direct questions intended to guide you to your solutions has now frustrated 3 experienced users to the point of exasperation. I’m reasonably certain that all 3 of us have contributed directly to the underlying codebase and have a fairly deep understanding. Ignoring (or appearing to ignore) the sound advice you’re given results in the frustration you’re seeing displayed here.

ArduPilot is wildly flexible, with the same codebase and hardware capable of controlling everything from a tiny sub-250g copter all the way up to large scale aircraft of several hundred (or more) kg. With that flexibility comes complexity, where new user frustration lies.

That said, stick with it. None of us want to see you fail, or we wouldn’t have invested the time it took to get this far.

1 Like

Well, some of your comments just don’t sit well with me. For example.“.I won’t entertain further discussion regarding invalid ground tests.” Well, I did entertain the tests ande they went well. My only concern is the yaw actikon and I think I know the answer to that. If the motor turns one way, the drone is going to turn the other way. Simple acyion-reaction physics.

As far a more ground testing, I will probably connect the drone to a short string when i first start and let the drone fly say 2-3 feet and see if the sticks respond properly. I have done this with my other drone and it worked nicely.

I find the mapping of the A,B,C,D, the servo numbers, the motor numberss, and etc confusing. Surely there must be a better way.

All of us told you multiple times that testing in that manner is invalid, despite your observation of apparent validity. Yet you continued. That’s what I mean by ignoring advice. Thus I worded the same advice more strongly.

Tethering is also a poor idea, as it produces the same erroneous gyro data and can result in destabilization that can cause more harm than good.

Your first flight should be in stabilize mode, brief, and at low altitude. I have yet to crash a first flight, even on my very first, likely ill informed build.

With all the trouble I have been having, there is no way I would start the drone and assume it wont run away. A tether is going to happen!

Now if you want to continue to help, tell me why when I enter 10 into the “length of propeller” and hit the calculate button, the 10 goes eventually goes back to 9?? I have no faith that hitting the calculate button did anything.

Don’t know about you but it is bed time here.

Manana my friend.

I suggest you use the search function on the forum here for “motor order” and try to engage others that have had the same question.

Prop size isn’t a saved parameter, but rather used to calculate other actual parameters. 9 is the default value for the page. If you navigate away from the page and then come back, it will show the default value again. As long as you click through the resulting prompts, the initial tuning values will be set and saved.

To avoid fly-aways, you can temporarily set an RC channel to “Motor Emergency Stop” (31), which you can successfully ground test by arming the Copter, seeing that the props begin turning, and then activating the assigned switch and observing the e-stop behavior. I recommend this for the initial testing phase but then removing the option once some confidence is gained such that you don’t accidentally toggle it during a longer, higher flight.

I know motor mapping is confusing. That’s why I created a topic on the subject and engage in the conversation whenever I see it. Your primary source of confusion seemed to be an over-reliance on the ESC labels rather than focusing on the outputs and functions assigned.

There is a lot of beauty to ArduPilot’s admittedly confusing motor matrix scheme(s). It allows for that aforementioned flexibility and a degree of predictability once you’re familiar with it.

The Initial parameters calculator does not read in your parameters first, so it always starts with those same default/common values.
You put in you prop size and battery cell count - it produces a bunch of new params and you get a window comparing your params with the new calculated ones and you can accept them all, or individually deselect some if you need to - generally you should accept everything it offers.

Once this is done you dont need to revisit the Initial Parameters calc unless you changed something or made a mistake. If you run it again and get NO list of parameters to change, then they are already good!

I looked at the flight modes in AP. I did not see an “emergency stop” 31 listed???

I assume I should start with stabilize, yes maybe Alt hold?

So, in Stabilize, what should happen as I start increasing the thrust?

Does the drone rise forever? Do I control the rising and falling with the throttle?
Is the throttle basically an altitude control?

And what about Alt hold? Do I rise to a certain point and hit alt hold and it sits there with the throttle disengaged?

Are these actions explained in the wiki?

Just wondering as I am just about to fly my drone and don’t want to be surprised.

Motor Emergency Stop is an RCx_OPTION, not a flight mode.

Stabilize mode gives you nearly direct throttle control. Alt Hold hovers at the throttle trim point and climbs/descends with throttle above/below the trim point.

Alt Hold may not even work without a GPS/Compass. Loiter definitely will not.

All in the wiki:
https://ardupilot.org/copter/docs/flight-modes.html

Start in Stabilize, also per the wiki:
https://ardupilot.org/copter/docs/ac_tipsfornewpilots.html