Package com.revrobotics.spark.config
Class SparkBaseConfigAccessor
java.lang.Object
com.revrobotics.spark.config.SparkBaseConfigAccessor
- Direct Known Subclasses:
SparkFlexConfigAccessor
,SparkMaxConfigAccessor
-
Field Summary
Modifier and TypeFieldDescriptionAccessor for parameters relating to the absolute encoder.Accessor for parameters relating to the analog sensor.final ClosedLoopConfigAccessor
Accessor for parameters relating to the closed loop controller.final EncoderConfigAccessor
Accessor for parameters relating to the primary encoder.Accessor for parameters relating to the hardware limit switches.final SignalsConfigAccessor
Accessor for parameters relating to the Status Signals.final SoftLimitConfigAccessor
Accessor for parameters relating to the Software Limits. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiondouble
boolean
int
boolean
double
double
int
int
int
int
double
boolean
-
Field Details
-
absoluteEncoder
Accessor for parameters relating to the absolute encoder. To configure these values, useAbsoluteEncoderConfig
and callSparkBase.configure(SparkBaseConfig, SparkBase.ResetMode, SparkBase.PersistMode)
.NOTE: This uses calls that are blocking to retrieve parameters and should be used infrequently.
-
analogSensor
Accessor for parameters relating to the analog sensor. To configure these values, useAnalogSensorConfig
and callSparkBase.configure(SparkBaseConfig, SparkBase.ResetMode, SparkBase.PersistMode)
.NOTE: This uses calls that are blocking to retrieve parameters and should be used infrequently.
-
encoder
Accessor for parameters relating to the primary encoder. To configure these values, useEncoderConfig
and callSparkBase.configure(SparkBaseConfig, SparkBase.ResetMode, SparkBase.PersistMode)
.NOTE: This uses calls that are blocking to retrieve parameters and should be used infrequently.
-
limitSwitch
Accessor for parameters relating to the hardware limit switches. To configure these values, useLimitSwitchConfig
and callSparkBase.configure(SparkBaseConfig, SparkBase.ResetMode, SparkBase.PersistMode)
.NOTE: This uses calls that are blocking to retrieve parameters and should be used infrequently.
-
closedLoop
Accessor for parameters relating to the closed loop controller. To configure these values, useClosedLoopConfig
and callSparkBase.configure(SparkBaseConfig, SparkBase.ResetMode, SparkBase.PersistMode)
.NOTE: This uses calls that are blocking to retrieve parameters and should be used infrequently.
-
softLimit
Accessor for parameters relating to the Software Limits. To configure these values, useSoftLimitConfig
and callSparkBase.configure(SparkBaseConfig, SparkBase.ResetMode, SparkBase.PersistMode)
.NOTE: This uses calls that are blocking to retrieve parameters and should be used infrequently.
-
signals
Accessor for parameters relating to the Status Signals. To configure these values, useSignalsConfig
and callSparkBase.configure(SparkBaseConfig, SparkBase.ResetMode, SparkBase.PersistMode)
.NOTE: This uses calls that are blocking to retrieve parameters and should be used infrequently.
-
-
Constructor Details
-
SparkBaseConfigAccessor
protected SparkBaseConfigAccessor(long sparkHandle)
-
-
Method Details
-
getIdleMode
-
getInverted
public boolean getInverted() -
getSmartCurrentLimit
public int getSmartCurrentLimit() -
getSmartCurrentFreeLimit
public int getSmartCurrentFreeLimit() -
getSmartCurrentRPMLimit
public int getSmartCurrentRPMLimit() -
getSecondaryCurrentLimit
public double getSecondaryCurrentLimit() -
getSecondaryCurrentLimitChopCycles
public int getSecondaryCurrentLimitChopCycles() -
getOpenLoopRampRate
public double getOpenLoopRampRate() -
getClosedLoopRampRate
public double getClosedLoopRampRate() -
getVoltageCompensation
public double getVoltageCompensation() -
getVoltageCompensationEnabled
public boolean getVoltageCompensationEnabled() -
getFollowerModeLeaderId
public int getFollowerModeLeaderId() -
getFollowerModeInverted
public boolean getFollowerModeInverted()
-