Type of event (frame).
This element specifies the fundamental type of the frame. Interpretation of the Identifier, Flags, and Info elements are different for each type.
For NI-XNET development, this corresponds to the Type element in the CAN and FlexRay frames.
For NI-CAN development in LabVIEW, this corresponds to the IsRemote element in the CAN and LIN frames.
For NI-CAN development in C/C++ (or other languages), this corresponds to the FrameType element in the CAN and LIN frames.
For LabVIEW FPGA development, this corresponds to the Type element in the CAN frame.
The upper 4 bits of this element specify the protocol (hexadecimal):
- 0 CAN
- 1 LIN
- 2 FlexRay
- 3-D Reserved (unused)
- E None (unrelated to protocol)
- F Custom (customer-specific types in logfile only)
The lower 4 bits of this element are the specific type.
The most common types in hexadecimal are 00 (CAN data frame), 01 (CAN remote frame), 12 (LIN full frame), 20 (FlexRay data frame), and 21 (FlexRay null frame). Refer to your API documentation for other types.
The Custom category (F in upper 4 bits) is specifically designed for use in logfiles. In addition to using this logfile format for embedded network frames, you may need to encode other data, such as analog or digital measurements, or the time that a front-panel button is pressed. When you create such custom events, you need to know that future versions of the API will not return that type from the Read function. In addition, you may want the API Write function to ignore these custom events. Although all types from 00 to EF hex are reserved for use by NI products, types F0 to FF are available to you as custom types. When you use one of these custom types, NI products ignore the event. The definition of the Identifier, Flags, Info, and Payload is up to you. If you intend to exchange logfiles with other companies, we recommend using a different file extension than .ncl (or a different Signature), to avoid conflicts between different definitions of custom types.
Other than the custom frame Type, and the upper 2 bits of the Info element, you must assume that all other bits of the event are reserved for future use by NI products. For bits that are currently unused (i.e. bit 30 and 31 of Identifier), the API Read function will always return 0, and you must always use 0 for frames passed to the API Write.