PcanMessage Class

Represents a PCAN message from a CAN, CAN FD or CAN XL capable hardware.

Definition

Namespace: Peak.Can.Basic
Assembly: PCANBasic.NET (in PCANBasic.NET.dll) Version: 5.1.0
C#
public sealed class PcanMessage
Inheritance
Object    PcanMessage

Constructors

PcanMessage(UInt32, MessageType, Byte, Byte, Boolean) Initializes an instance of PcanMessage for representing a CAN CC or CAN FD frame.
PcanMessage(UInt32, Byte, MessageTypeXL, UInt16, Byte, UInt32, Boolean, Boolean, Byte) Initializes an instance of PcanMessage for representing a CAN XL frame.

Properties

AF Acceptance Field, SDU - specific high - layer ID.

  Important

Only valid when protocols CAN XL is used.
Data The data associated to the CAN message (CAN DATA[0]..DATA[7], CAN FD DATA[0]..DATA[63]).
DLC CAN-CC/CAN-FD: The Data Length Code (DLC) of the message (0..15). CAN-XL: The Data Length Code (DLC) of the message (0..2047).
ID A 11/29-bit CAN message identifier.

  Important

Only valid when protocols CAN classic or CAN FD are used.
Length The amount of data bytes according to the Data Length Code and CAN protocol used.
MaxDataLength Maximum amount of data bytes supported by this object
MsgType The kind of CAN frame represented by this object.

  Important

Only valid when protocols CAN classic or CAN FD are used.
MsgTypeXL The kind of CAN frame represented by this object.

  Important

Only valid when protocols CAN XL is used.
PID Priority ID (physical layer) (0..0x7FF)

  Important

Only valid when the protocol CAN XL is used.
Protocol Gets the CAN protocol for which this object is valid.
RRS Remote Request Substitution flag.

  Important

Only valid when protocols CAN XL is used.
SDT Service Data unit(SDU) protocol Type.

  Important

Only valid when protocols CAN XL is used.
SEC Simple Extended Content flag.

  Important

Only valid when protocols CAN XL is used.
VCID Gets or sets the virtual CAN network ID (VCID).

  Important

Only valid when the protocol CAN XL is used.

Methods

EqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
GetHashCodeServes as the default hash function.
(Inherited from Object)
GetTypeGets the Type of the current instance.
(Inherited from Object)
ToString Builds and returns a string that represents the current CAN message.
(Overrides ObjectToString)

See Also