RC AND MOT parameters - looking for full explanation

Hi.
My setting is
X-frame quadcopter, Pixhawk-2 controller, U3 motors with 12’ props, Alpha-T-Motor ESC.
I am interested in using the full envelope of my motors . After I measured the motors output in a lab, I found that the full envelope (according to the motor’s spec-s) may be achieved when MOT_PWM_MAX is set to 2200, however it is usually limited by 2000 (this is what is written in Mission Planer).

So, I am looking for an extended explanation on motors and rc. Questions:

  1. When I perform the Radio Control Calibration do I set the RC_MIN and RC_MAX PWM values or I calibrate the radio control within these values?
  2. What happens if I change the above values in Mission Planner parameters tree after the calibration?
  3. As I know, If I do not define values for MOT_PWM_MIN and MOT_PWM_MAX, the controller will use the appropriate RC_MIN and RC_Max values. What happens if I do define these values? Do I have to set the RC values accordingly or re-calibrate the radio control.
  4. If the ESC has been calibrated after radio calibration and then I set the MOT_PWM_MIN and MOT_PWM_MAX - do I need to re-calibrate the ESC? What may happen If I do not?
    Thanks

I’ll answer the questions in order, but first I’ll describe how an RC input is transformed into throttle output. This will give a high level view that will inform the answers to your questions:

  1. RC PWM input is received. It is interpreted as a control effort from 0% to 100%, based on on where the incoming PWM falls in the RC_MIN and RC_MAX range.
  2. The flight controller decides how that control effort will affect motor outputs. Long story, but each motor gets a demanded thrust effort from 0% to 100%.
  3. The thrust demand is translated back into a PWM value, based on where the % effort falls on the MOT_PWM_MIN and MOT_PWM_MAX range (same as step 1, but backwards). This PWM value is sent to the ESC.

So, the short version is this:

  • Set the RC_ values to be equal to the PWMs that the radio transmits. The RC calibration procedure does this for you.
  • Set the MOT_PWM_ values to be equal to the PWMs that the ESC’s are expecting. Performing an ESC calibration will make the ESC’s expect the PWM values that your radio sends during the calibration. Ostensibly, this will be the same as the values set during the RC calibration, so the ranges will match.

Now to answer the questions directly:

  1. The calibration sets those parameters. These parameters are what create the mapping between PWM input and throttle setting.
  2. Your radio will still be outputting the original range. If you set the RC parameters to be a larger range than the radio can send, then you will never achieve 100% control effort. If you set them to be a smaller range, the command will saturate at 100% before the RC stick moves its full range.
  3. The MOT_PWM parameters define the PWM range that are sent to the ESC. Setting them to be different than the RC_ parameters simply allows the RC input PWM range and the ESC output PWM range to be different, but still allow access to the full control range. This is useful for certain ESC’s such as DJI, which cannot be calibrated.
  4. The parameters don’t affect the ESC calibration, as that simply sends your RC inputs directly to the ESC’s (passthrough) to set their expected range. You don’t need to recalibrate as long as your MOT_PWM_ values match the the PWM range that you sent to the ESC’s with your transmitter during calibration. This is why those parameters default to 0, because RC calibration sets them to be equal to the PWM range of your transmitter.
1 Like

By the way, since you mentioned wanting to get the most out of your motors, here’s a few things I thought of that might interest you:

First, you said you get the most thrust at 2200 PWM. This should only be true if the ESC is calibrated to expect up to that value, which is pretty uncommon. If, for example, it is calibrated for a PWM range of 1000-2000, then any PWM input higher than 2000 will be the same as 2000, since the ESC is calibrated to map that value to be 100% throttle. You CAN set the MOT_PWM_MAX to 2200 if you use the full parameter list/tree in MP, however I am actually not certain if the hardware is capable of outputting that high (probably can).

Second, you can expand the throttle range that the flight controller can utilize by setting your MOT_SPIN_ARM and MOT_SPIN_MIN parameters. The defaults are pretty conservative, so there’s usually some room to be gained. Try lowering your _ARM parameter - it should be set high enough that the motors reliably start up when you arm the drone. Then, you can set the _SPIN parameter to be a bit higher than that. For example, I use 0.07 and 0.09 instead of the defaults of 0.1 and 0.15.

Last, you should take a look at the MOT_THST_EXPO parameter. This parameter tells Arducopter what the thrust vs. PWM curve looks like, so it maps control effort to thrust requirement correctly. The default value of 0.65 works for most ESC’s, however, some manufacturers such as T-Motor and KDE are known to apply a thrust linearization curve to their ESC outputs, meaning that the thrust curve is atypically linear. Experiments by various users have found T-Motors to ideally have a MOT_THST_EXPO value of between 0.2 to 0.3. I’m not sure if it applies to all T-Motor ESC’s, but if your thrust data looks suspiciously linear, then it probably does.

Thanks Rick for the detailed explanation.
From your explanation I understand that there is no need to “touch” the MOT_PWM_MAX and MIN parameters. There must be some reason to have these parameters… When may this need arise?

There are cases where the PWM range that must be sent to your ESCs is different than the range your transmitter puts out. DJI ESCs are an example of this, as they they expect a particular PWM range and cannot be calibrated.

Thanks again.
I’ve looked at the ArduCopter code, and as I see MOT_THST_EXPO have no effect when performing motor test. Any way to measure its effect??

Yeah, the motor tests just pass through PWMs directly to the ESCs without the flight controller applying any transformations.

To measure it, you’d have to arm the flight controller as if you were flying the drone. I think it will work if you fasten it down to a level surface and then throttle up in Stabilize mode without touching the pitch, roll, or yaw sticks.