Package com.dsi.ant.message.fromhost
Class AcknowledgedDataMessageFromHost
java.lang.Object
com.dsi.ant.message.AntMessage
com.dsi.ant.message.fromhost.AntMessageFromHost
com.dsi.ant.message.fromhost.DataMessageFromHost
com.dsi.ant.message.fromhost.AcknowledgedDataMessageFromHost
Can be used as a replacement for
BroadcastDataMessageFromHost and
expects an acknowledgement message back from the slave being transmitted to.- Since:
- 4.0
-
Field Summary
Fields inherited from class com.dsi.ant.message.fromhost.DataMessageFromHost
LENGTH_STANDARD_PAYLOAD, OFFSET_PAYLOAD_STARTFields inherited from class com.dsi.ant.message.AntMessage
BITMASK_CHANNEL_NUMBER, FILLER_BYTE, OFFSET_CHANNEL_NUMBER, RAW_OFFSET_MESSAGE_CONTENT_START, RAW_OFFSET_MESSAGE_ID, RAW_OFFSET_MESSAGE_SIZE, SIZE_CHANNEL_NUMBER, SIZE_FILLER_BYTE -
Constructor Summary
ConstructorsConstructorDescriptionAcknowledgedDataMessageFromHost(byte[] payload) Constructs the message from the message bytes. -
Method Summary
Modifier and TypeMethodDescriptionbyte[]getMessageContent(int channelNumber, int networkNumber) The content of the message with specified channel number and network number set if required.The unique type of this message based on its message id, contents, and intended channel type.byte[]Gets the payload of the data message.Methods inherited from class com.dsi.ant.message.fromhost.DataMessageFromHost
createDataMessageFromHost, getStandardPayload, toStringMethods inherited from class com.dsi.ant.message.fromhost.AntMessageFromHost
createAntMessage, createAntMessage, getMessageContent, getMessageContent, getMessageId, getRawMessage, toStringHeaderMethods inherited from class com.dsi.ant.message.AntMessage
equals, getMessageContentString, getMessageIdString, hashCode, maskChannelNumber
-
Constructor Details
-
AcknowledgedDataMessageFromHost
public AcknowledgedDataMessageFromHost(byte[] payload) Constructs the message from the message bytes.- Parameters:
payload- The received message bytes.- Since:
- 4.0
-
-
Method Details
-
getPayload
public byte[] getPayload()Description copied from class:DataMessageFromHostGets the payload of the data message.- Specified by:
getPayloadin classDataMessageFromHost- Returns:
- The payload of the data message.
- Since:
- 4.0
-
getMessageContent
public byte[] getMessageContent(int channelNumber, int networkNumber) Description copied from class:AntMessageFromHostThe content of the message with specified channel number and network number set if required.- Specified by:
getMessageContentin classAntMessageFromHost- Parameters:
channelNumber- Written to the channel number byte if requirednetworkNumber- Written to the network number byte if required- Returns:
- Message content raw byte array.
- Since:
- 4.0
-
getMessageType
Description copied from class:AntMessageFromHostThe unique type of this message based on its message id, contents, and intended channel type.It is recommended to use this rather than the raw message ID.
- Specified by:
getMessageTypein classAntMessageFromHost- Returns:
- The type of message returned by the host.
- Since:
- 4.0
-