Package edu.wpi.first.hal.can
Class CANStreamMessage
java.lang.Object
edu.wpi.first.hal.can.CANStreamMessage
Represents a CAN message read from a stream.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbyte[]
setStreamData
(int length, int flags, int messageId, long timestamp) API used from JNI to set the data.
-
Field Details
-
data
The message data. -
length
The length of the data received (0-64 bytes). -
flags
The flags of the message. -
timestamp
Timestamp message was received, in milliseconds (based off of CLOCK_MONOTONIC). -
messageId
The message ID.
-
-
Constructor Details
-
CANStreamMessage
public CANStreamMessage()Default constructor.
-
-
Method Details
-
setStreamData
API used from JNI to set the data.- Parameters:
length
- Length of packet in bytes.messageId
- CAN message ID of the message.flags
- Message flags.timestamp
- CAN frame timestamp in microseconds.- Returns:
- Buffer containing CAN frame.
-