TPCANMsgFD Structure

Defines a CAN message with flexible data rate.

Definition

Namespace: Peak.Can.Basic.BackwardCompatibility
Assembly: PCANBasic.NET (in PCANBasic.NET.dll) Version: 5.1.0
C#
public struct TPCANMsgFD
Inheritance
Object    ValueType    TPCANMsgFD

Remarks

The members of this structure are sequentially byte aligned.

Longer Data field with CAN FD messages:

DLCData Bytes
00
11
22
33
44
55
66
77
88
912
1016
1120
1224
1332
1448
1564

  Important

The TPCANMsgFD structure is intended for reading and writing standard CAN messages as well as CAN messages with flexible data rate on PCAN Channels initialized for standard CAN-FD communication, this is, using the InitializeFD method for initialization and the methods ReadFD and WriteFD for data transmission.

For CAN communication using only the standard CAN 2.0 A/B, the TPCANMsg structure is to be used.

Methods

EqualsIndicates whether this instance and a specified object are equal.
(Inherited from ValueType)
GetHashCodeReturns the hash code for this instance.
(Inherited from ValueType)
GetTypeGets the Type of the current instance.
(Inherited from Object)
ToStringReturns the fully qualified type name of this instance.
(Inherited from ValueType)

Fields

DATA The data associated to the CAN message (DATA[0]..DATA[63]).

  Important

This array must be explicitly created, for instance:
C#
TPCANMsgFD msgFd = new TPCANMsgFD() { DATA = new byte[64] };
before a variable of this type can be used in any API function.
DLC The Data Length Code of the message (0..15).
ID A 11/29-bit CAN message identifier.
MSGTYPE The kind of CAN frame represented by this value.

See Also