# What does percent output actually mean?

For example, what does the motor controller actually output when I set it to 0.5 (or any other number)? Is it just a duty cycle, or are there other things involved?

And, is it the same for Talons and Spark Maxs?

1 Like

â€śPercentâ€ť is a misnomer. Itâ€™s fractional duty cycle.

6 Likes

Which, in FRC, roughly equates to a percentage of the input voltage.

2 Likes

Okay, thank you!

1 Like

Plus or minus a factor of a hundred, I guess.

People messing up percent vs fraction in variable naming causes tons of mistakes even in industry.

4 Likes

If you want to dig into things a bit further, this is not a bad overview.

The â€śpercent outputâ€ť aspect of this is that PWM modulation is applied to effectively vary the applied voltage from -1.0 * full battery voltage to +1.0 * full battery voltage.

With this approach, things are always either fully â€śonâ€ť or fully â€śoffâ€ť, but the time-averaged voltage is varied across this full range. The reason for doing this is efficiency. Power is either applied to the motor, or it is dissipated as heat. The way to get the highest efficiency is to do the fully on/off thing. This is all combined with the need to apply voltage to different coils of wire inside the motor at different points in time.

2 Likes

Or times or divided, heh.

Iâ€™ve been trying to figure out how to refer to this for several years now. There are several closed threads on StackExchange where people ask what to call it, since there are names for various other ratios (percent, parts-per-million, parts-per-trillion, etcâ€¦). These always seem to end in â€śwell, just call it a fraction/proportion?â€ť

Nothing bothers me more than when it gets referred to as â€śspeedâ€ť, though.

1 Like

Wikipedia seems to want to call this a dimensionless or quantity of dimension one? But neither of those really feel right.

It doesnâ€™t describe the necessary aspect of the number as a parameter to a speed controllerâ€™s method/member function, which is that the range is -1.0 to 1.0, and that it is a multiplier for Vbus (or Vbatt), and that product results in a voltage that is applied to the motor.

In the past, there were a few places in libraries that referred to â€śpercentVbusâ€ť; maybe there still are. As @Oblarg pointed out, â€śpercentVbusâ€ť would technically refer to a number between -100 and 100 that is then divided by 100 and multiplied by Vbus to get the voltage applied to the motor.

I could see something like â€śproportionVbusâ€ť being a semi-adequate description, but, IMO, â€śdimensionlessQuantityVbusâ€ť does not convey the necessary info.

1 Like

`fractionalOutput` or `fractionalDutyCycle` would both be adequate, imo.

3 Likes

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.