mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
[wpilib] Rename NormalizeWheelSpeeds to DesaturateWheelSpeeds (#3791)
This commit is contained in:
@@ -153,7 +153,7 @@ public final class StateSpaceUtil {
|
||||
}
|
||||
|
||||
/**
|
||||
* Normalize all inputs if any excedes the maximum magnitude. Useful for systems such as
|
||||
* Renormalize all inputs if any exceeds the maximum magnitude. Useful for systems such as
|
||||
* differential drivetrains.
|
||||
*
|
||||
* @param u The input vector.
|
||||
@@ -161,7 +161,7 @@ public final class StateSpaceUtil {
|
||||
* @param <I> The number of inputs.
|
||||
* @return The normalizedInput
|
||||
*/
|
||||
public static <I extends Num> Matrix<I, N1> normalizeInputVector(
|
||||
public static <I extends Num> Matrix<I, N1> desaturateInputVector(
|
||||
Matrix<I, N1> u, double maxMagnitude) {
|
||||
double maxValue = u.maxAbs();
|
||||
boolean isCapped = maxValue > maxMagnitude;
|
||||
|
||||
Reference in New Issue
Block a user