public class CalibDone extends MsgToCCS
MESSAGE_SET_VERSION| Constructor and Description |
|---|
CalibDone(ByteBuffer data)
Reads and converts the PLC form of the message.
|
CalibDone(int sequence,
double[] homePosition,
double[] deployedPosition,
DoubleSupplier supplier)
Creates the message from scratch.
|
| Modifier and Type | Method and Description |
|---|---|
void |
encode(ByteBuffer data)
Puts the sequence number into a data buffer.
|
double |
getDeployedPosition(Axis ax)
Returns the deployed position for an axis.
|
double[] |
getHallTransitions(Axis axis,
Direction direction)
Returns the set of Hall transition positions for a given axis and direction of travel.
|
double |
getHomePosition(Axis ax)
Returns the home position for an axis.
|
String |
toString()
Converts the message to a readable string.
|
getVersion, messageVersionIsBadpublic CalibDone(int sequence,
double[] homePosition,
double[] deployedPosition,
DoubleSupplier supplier)
sequence - A message sequence number.homePosition - Axis blade set home positions (home = fully retracted).deployedPosition - Axis blade set deployed positions (fully extended).supplier - The supplier of double values for the Hall calibration. Used to fill the
internal map of Hall transition positions which has "dimensions"
[axis number][direction][transitions per direction].
The order is row-major, Axis 0 comes before Axis 1, positive direction comes before negative. 240
values are expected for each combination of axis and direction.Axis,
Directionpublic CalibDone(ByteBuffer data)
data - The PLC message data.public void encode(ByteBuffer data)
MsgToCCSpublic double[] getHallTransitions(Axis axis, Direction direction)
axis - The axis.direction - The direction of travel.public double getHomePosition(Axis ax)
ax - The axis.public double getDeployedPosition(Axis ax)
ax - The axis.public String toString()
PLCMsgtoString in class MsgToCCSCopyright © 2020 LSST. All rights reserved.