Class MotorOutputConfigs
- All Implemented Interfaces:
ParentConfiguration,ISerializable,Cloneable
Includes motor invert, neutral mode, and other features related to motor output.
-
Field Summary
FieldsModifier and TypeFieldDescriptiondoubleWhen a control request UseTimesync is enabled, this determines the time-sychronized frequency at which control requests are applied.doubleConfigures the output deadband duty cycle during duty cycle and voltage based control modes.Invert state of the device as seen from the front of the motor.The state of the motor controller bridge when output is neutral or disabled.doubleMaximum (forward) output during duty cycle based control modes.doubleMinimum (reverse) output during duty cycle based control modes. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionclone()final StatusCodedeserialize(String to_deserialize) Take a string and deserialize it to this configuration group.final FrequencyHelper method to get this configuration's ControlTimesyncFreqHz parameter converted to a unit type.final StringGet the serialized form of this configuration group.toString()final MotorOutputConfigswithControlTimesyncFreqHz(double newControlTimesyncFreqHz) Modifies this configuration's ControlTimesyncFreqHz parameter and returns itself for method-chaining and easier to use config API.final MotorOutputConfigswithControlTimesyncFreqHz(Frequency newControlTimesyncFreqHz) Modifies this configuration's ControlTimesyncFreqHz parameter and returns itself for method-chaining and easier to use config API.final MotorOutputConfigswithDutyCycleNeutralDeadband(double newDutyCycleNeutralDeadband) Modifies this configuration's DutyCycleNeutralDeadband parameter and returns itself for method-chaining and easier to use config API.final MotorOutputConfigswithInverted(InvertedValue newInverted) Modifies this configuration's Inverted parameter and returns itself for method-chaining and easier to use config API.final MotorOutputConfigswithNeutralMode(NeutralModeValue newNeutralMode) Modifies this configuration's NeutralMode parameter and returns itself for method-chaining and easier to use config API.final MotorOutputConfigswithPeakForwardDutyCycle(double newPeakForwardDutyCycle) Modifies this configuration's PeakForwardDutyCycle parameter and returns itself for method-chaining and easier to use config API.final MotorOutputConfigswithPeakReverseDutyCycle(double newPeakReverseDutyCycle) Modifies this configuration's PeakReverseDutyCycle parameter and returns itself for method-chaining and easier to use config API.
-
Field Details
-
Inverted
Invert state of the device as seen from the front of the motor. -
NeutralMode
The state of the motor controller bridge when output is neutral or disabled. -
DutyCycleNeutralDeadband
Configures the output deadband duty cycle during duty cycle and voltage based control modes.- Minimum Value: 0.0
- Maximum Value: 0.25
- Default Value: 0
- Units: fractional
-
PeakForwardDutyCycle
Maximum (forward) output during duty cycle based control modes.- Minimum Value: -1.0
- Maximum Value: 1.0
- Default Value: 1
- Units: fractional
-
PeakReverseDutyCycle
Minimum (reverse) output during duty cycle based control modes.- Minimum Value: -1.0
- Maximum Value: 1.0
- Default Value: -1
- Units: fractional
-
ControlTimesyncFreqHz
When a control request UseTimesync is enabled, this determines the time-sychronized frequency at which control requests are applied.The application of the control request will be delayed until the next timesync boundary at the frequency defined by this config. When set to 0 Hz, timesync will never be used for control requests, regardless of the value of UseTimesync.
- Minimum Value: 50
- Maximum Value: 500
- Default Value: 0
- Units: Hz
-
-
Constructor Details
-
MotorOutputConfigs
public MotorOutputConfigs()
-
-
Method Details
-
withInverted
Modifies this configuration's Inverted parameter and returns itself for method-chaining and easier to use config API.Invert state of the device as seen from the front of the motor.
- Parameters:
newInverted- Parameter to modify- Returns:
- Itself
-
withNeutralMode
Modifies this configuration's NeutralMode parameter and returns itself for method-chaining and easier to use config API.The state of the motor controller bridge when output is neutral or disabled.
- Parameters:
newNeutralMode- Parameter to modify- Returns:
- Itself
-
withDutyCycleNeutralDeadband
Modifies this configuration's DutyCycleNeutralDeadband parameter and returns itself for method-chaining and easier to use config API.Configures the output deadband duty cycle during duty cycle and voltage based control modes.
- Minimum Value: 0.0
- Maximum Value: 0.25
- Default Value: 0
- Units: fractional
- Parameters:
newDutyCycleNeutralDeadband- Parameter to modify- Returns:
- Itself
-
withPeakForwardDutyCycle
Modifies this configuration's PeakForwardDutyCycle parameter and returns itself for method-chaining and easier to use config API.Maximum (forward) output during duty cycle based control modes.
- Minimum Value: -1.0
- Maximum Value: 1.0
- Default Value: 1
- Units: fractional
- Parameters:
newPeakForwardDutyCycle- Parameter to modify- Returns:
- Itself
-
withPeakReverseDutyCycle
Modifies this configuration's PeakReverseDutyCycle parameter and returns itself for method-chaining and easier to use config API.Minimum (reverse) output during duty cycle based control modes.
- Minimum Value: -1.0
- Maximum Value: 1.0
- Default Value: -1
- Units: fractional
- Parameters:
newPeakReverseDutyCycle- Parameter to modify- Returns:
- Itself
-
withControlTimesyncFreqHz
Modifies this configuration's ControlTimesyncFreqHz parameter and returns itself for method-chaining and easier to use config API.When a control request UseTimesync is enabled, this determines the time-sychronized frequency at which control requests are applied.
The application of the control request will be delayed until the next timesync boundary at the frequency defined by this config. When set to 0 Hz, timesync will never be used for control requests, regardless of the value of UseTimesync.
- Minimum Value: 50
- Maximum Value: 500
- Default Value: 0
- Units: Hz
- Parameters:
newControlTimesyncFreqHz- Parameter to modify- Returns:
- Itself
-
withControlTimesyncFreqHz
Modifies this configuration's ControlTimesyncFreqHz parameter and returns itself for method-chaining and easier to use config API.When a control request UseTimesync is enabled, this determines the time-sychronized frequency at which control requests are applied.
The application of the control request will be delayed until the next timesync boundary at the frequency defined by this config. When set to 0 Hz, timesync will never be used for control requests, regardless of the value of UseTimesync.
- Minimum Value: 50
- Maximum Value: 500
- Default Value: 0
- Units: Hz
- Parameters:
newControlTimesyncFreqHz- Parameter to modify- Returns:
- Itself
-
getControlTimesyncFreqHzMeasure
Helper method to get this configuration's ControlTimesyncFreqHz parameter converted to a unit type. If not using the Java units library,ControlTimesyncFreqHzcan be accessed directly instead.When a control request UseTimesync is enabled, this determines the time-sychronized frequency at which control requests are applied.
The application of the control request will be delayed until the next timesync boundary at the frequency defined by this config. When set to 0 Hz, timesync will never be used for control requests, regardless of the value of UseTimesync.
- Minimum Value: 50
- Maximum Value: 500
- Default Value: 0
- Units: Hz
- Returns:
- ControlTimesyncFreqHz
-
toString
-
serialize
Get the serialized form of this configuration group.- Specified by:
serializein interfaceISerializable- Returns:
- Serialized form of this config group
-
deserialize
Take a string and deserialize it to this configuration group.- Specified by:
deserializein interfaceParentConfiguration- Returns:
- Return code of the deserialize method
-
clone
-