Special Frames

The NI-XNET driver offers some special frames not directly used in bus communication.

Future Time Wait Frame

When a frame with a Future Time Wait frame type is received, hardware waits until the absolute time associated with this frame occurs before continuing on to process the subsequent frames. If the Future Time Wait timestamp was in the past when this frame is processed, hardware immediately continues processing the subsequent frames. This frame type always resets the start time. The next frame to be dequeued is treated as a new first frame and transmitted immediately. Future Time Wait is only supported with Ethernet.

Future Time Wait is particularly useful for synchronizing with other devices that also support a common notion of time. For example, this frame type can be used to synchronize the start of replay across multiple Ethernet ports. It can also be used in conjunction with nxFutureTimeTrigger to synchronize with other devices that require a physical signal. Multiple Future Time Wait frames can be written into a replay stream. Hardware will compensate for front-end delays (from the MAC through the PHY) when determining how long to wait. This will cause data from the next frame following Future Time Wait to hit the wire at the same time that was just waited for (hardware subtracts the front-end delay from the actual time that is waited for).

Delay Frame

When a frame with a Delay Frame frame type is received, the hardware delays for the requested time. The next frame to be dequeued is treated as a new first frame and transmitted immediately. You can use a Delay Frame with a time of 0 to restart time quickly. If you replay a logfile of frames repeatedly, you can insert a Delay Frame at the start of each replay to insert a delay between each iteration through the file.

The Delay frame fields are as follows:
Element Description
Identifier 0 (Ignored)
Extended False (Ignored)
Echo False (Ignored)
Type Delay
Timestamp Amount of time to delay. Note that this is not an absolute time and is not related to any other time in the replay frames. A time of 0.25 (that is, LabVIEW absolute time of 6:00:00.250PM 12/31/1903) will delay 250 ms.
Payload Length 0
Payload Ignored

Log Trigger Frame

A Log Trigger frame is a special frame that can be received by a Frame Stream Input session. This frame is generated when a rising edge is detected on an external connection (PXI_Trig or FrontPanel trigger). To enable the hardware to log this frame, you must use the Connect Terminals function (nxConnectTerminals in C or the XNET Connect Terminals VI in LabVIEW) to connect the external connection to the internal LogTrigger terminal. A Log Trigger frame is applicable to CAN, FlexRay, and LIN.

The fields of the Log Trigger frame are as follows:
Table 10. CAN Frame
Element Description
identifier 0
extended? False
echo? False
type Log Trigger
timestamp Time when the trigger occurred
payload length 0 (may increase in the future)
payload N/A
Table 11. FlexRay Frame
Element Description
slot 0
cycle count 0
startup? False
sync? False
preamble? False
ch A False
ch B False
echo? False
Type Log Trigger
Timestamp Time when the trigger occurred
Payload length 0 (may increase in the future)
Payload N/A
Table 12. LIN Frame
Element Description
identifier 0
event slot? False
event ID 0
echo? False
type Log Trigger
timestamp Time when the trigger occurred
payload length 0 (may increase in the future)
payload N/A

Start Trigger Frame

A Start Trigger frame is a special frame that a Frame Stream Input session can receive. This frame is generated when the interface is started. To enable the hardware to log this frame, you must enable the Interface:Start Trigger Frames to Input Stream? property. A Start Trigger frame is applicable to CAN, FlexRay, and LIN.

Start Trigger frames are not supported on Ethernet devices, as they are not needed. Ethernet devices use Future Time Wait frames for synchronization use cases.

The fields of the Start Trigger frame are as follows:
Table 13. CAN Frame
Element Description
identifier 0
extended? False
echo? False
type Start Trigger
timestamp Time when the interface started
payload length 0 (may increase in the future)
payload N/A
Table 14. FlexRay Frame
Element Description
slot 0
cycle count 0
startup? False
sync? False
preamble? False
ch A False
ch B False
echo? False
Type Start Trigger
Timestamp Time when the interface started
Payload Length 0 (may increase in the future)
Payload N/A
Table 15. LIN Frame
Element Description
identifier 0
event slot? False
event ID 0
echo? False
type Start Trigger
timestamp Time when the interface started
payload length 0 (may increase in the future)
payload N/A

Bus Error Frame

A CAN Bus Error frame is a special that can be received by a Frame Stream Input session. This frame is generated when a bus error is detected on the CAN bus. To enable the hardware to log this frame, you must enable the Interface:Bus Error Frames to Input Stream? property. A Bus Error frame is applicable to CAN and LIN. The fields of the Bus Error frame are as follows:
Table 16. CAN Frame
Element Description
identifier 0
extended? False
echo? False
type CAN Bus Error
timestamp Time when the bus error was detected
payload length 5 (may increase in future)
payload
Byte 0: CAN Comm State
0 Error Active
1 Error Passive
2 Bus Off

Byte 1: TX Error Counter

Byte 2: RX Error Counter

Byte 3: Detected Bus Error
0 None (never returned)
1 Stuff
2 Form
3 Ack
4 Bit 1
5 Bit 0
6 CRC
Byte 4: Transceiver Error?
0 no error
1 error
Table 17. LIN Frame
Element Description
identifier 0
event slot? False
event ID 0
echo? False
type LIN Bus Error
timestamp Time when the interface started
payload length 0 (may increase in the future)
payload
Byte 0: LIN Comm State
0 Idle
1 Active
2 Inactive
Byte 1: Detected Bus Error
0 None (never returned)
1 UnknownId
2 Form
3 Framing
4 Readback
5 Timeout
6 CRC

Byte 2: Identifier on bus

Byte 3: Received byte on bus

Byte 4: Expected byte on bus

LIN No Response Frame

A LIN No Response frame is a special frame that a Frame Stream Input session can receive. This frame is generated when a header with no response is detected on the LIN bus. To enable the hardware to log this frame, you must enable the Interface:LIN:No Response Frames to Input Stream? property. The No Response frame fields are as follows:

Element Description
Identifier Unprotected version of header ID
Event Slot? 0
Event ID 0
Echo? False
Type LIN No Response
Timestamp Time when the end of the header (ID) was detected
Payload Length 0
Payload N/A