Record Class ServoHubLowLevel.PeriodicStatus2
java.lang.Object
java.lang.Record
com.revrobotics.servohub.ServoHubLowLevel.PeriodicStatus2
- All Implemented Interfaces:
StatusFrame
- Enclosing class:
ServoHubLowLevel
public static record ServoHubLowLevel.PeriodicStatus2(short channel0PulseWidth, short channel1PulseWidth, short channel2PulseWidth, boolean channel0Enabled, boolean channel1Enabled, boolean channel2Enabled, boolean channel0OutOfRange, boolean channel1OutOfRange, boolean channel2OutOfRange, int revlibError, long timestamp)
extends Record
implements StatusFrame
-
Constructor Summary
ConstructorsConstructorDescriptionPeriodicStatus2(short channel0PulseWidth, short channel1PulseWidth, short channel2PulseWidth, boolean channel0Enabled, boolean channel1Enabled, boolean channel2Enabled, boolean channel0OutOfRange, boolean channel1OutOfRange, boolean channel2OutOfRange, int revlibError, long timestamp) Creates an instance of aPeriodicStatus2record class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns the value of thechannel0Enabledrecord component.booleanReturns the value of thechannel0OutOfRangerecord component.shortReturns the value of thechannel0PulseWidthrecord component.booleanReturns the value of thechannel1Enabledrecord component.booleanReturns the value of thechannel1OutOfRangerecord component.shortReturns the value of thechannel1PulseWidthrecord component.booleanReturns the value of thechannel2Enabledrecord component.booleanReturns the value of thechannel2OutOfRangerecord component.shortReturns the value of thechannel2PulseWidthrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intReturns the value of therevlibErrorrecord component.longReturns the value of thetimestamprecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from interface StatusFrame
getRevlibError
-
Constructor Details
-
PeriodicStatus2
public PeriodicStatus2(short channel0PulseWidth, short channel1PulseWidth, short channel2PulseWidth, boolean channel0Enabled, boolean channel1Enabled, boolean channel2Enabled, boolean channel0OutOfRange, boolean channel1OutOfRange, boolean channel2OutOfRange, int revlibError, long timestamp) Creates an instance of aPeriodicStatus2record class.- Parameters:
channel0PulseWidth- the value for thechannel0PulseWidthrecord componentchannel1PulseWidth- the value for thechannel1PulseWidthrecord componentchannel2PulseWidth- the value for thechannel2PulseWidthrecord componentchannel0Enabled- the value for thechannel0Enabledrecord componentchannel1Enabled- the value for thechannel1Enabledrecord componentchannel2Enabled- the value for thechannel2Enabledrecord componentchannel0OutOfRange- the value for thechannel0OutOfRangerecord componentchannel1OutOfRange- the value for thechannel1OutOfRangerecord componentchannel2OutOfRange- the value for thechannel2OutOfRangerecord componentrevlibError- the value for therevlibErrorrecord componenttimestamp- the value for thetimestamprecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
channel0PulseWidth
public short channel0PulseWidth()Returns the value of thechannel0PulseWidthrecord component.- Returns:
- the value of the
channel0PulseWidthrecord component
-
channel1PulseWidth
public short channel1PulseWidth()Returns the value of thechannel1PulseWidthrecord component.- Returns:
- the value of the
channel1PulseWidthrecord component
-
channel2PulseWidth
public short channel2PulseWidth()Returns the value of thechannel2PulseWidthrecord component.- Returns:
- the value of the
channel2PulseWidthrecord component
-
channel0Enabled
public boolean channel0Enabled()Returns the value of thechannel0Enabledrecord component.- Returns:
- the value of the
channel0Enabledrecord component
-
channel1Enabled
public boolean channel1Enabled()Returns the value of thechannel1Enabledrecord component.- Returns:
- the value of the
channel1Enabledrecord component
-
channel2Enabled
public boolean channel2Enabled()Returns the value of thechannel2Enabledrecord component.- Returns:
- the value of the
channel2Enabledrecord component
-
channel0OutOfRange
public boolean channel0OutOfRange()Returns the value of thechannel0OutOfRangerecord component.- Returns:
- the value of the
channel0OutOfRangerecord component
-
channel1OutOfRange
public boolean channel1OutOfRange()Returns the value of thechannel1OutOfRangerecord component.- Returns:
- the value of the
channel1OutOfRangerecord component
-
channel2OutOfRange
public boolean channel2OutOfRange()Returns the value of thechannel2OutOfRangerecord component.- Returns:
- the value of the
channel2OutOfRangerecord component
-
revlibError
public int revlibError()Returns the value of therevlibErrorrecord component.- Specified by:
revlibErrorin interfaceStatusFrame- Returns:
- the value of the
revlibErrorrecord component
-
timestamp
public long timestamp()Returns the value of thetimestamprecord component.- Specified by:
timestampin interfaceStatusFrame- Returns:
- the value of the
timestamprecord component
-