From 6:00 PM CST Friday, Feb 15th - 2:00 AM CST Sunday, Feb 17th, ni.com will be undergoing system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Table Of Contents

RT FIFO Read (G Dataflow)

Last Modified: January 12, 2018

Reads the oldest element in an RT FIFO.

If no new data exists in the RT FIFO or if the RT FIFO is empty, this node waits for the amount of time specified in timeout in ms for new data. If the value of timeout in ms expires, the node returns the value wired to element in the element out output and returns True in the empty? output.

Programming Patterns
connector_pane_image
datatype_icon

rt fifo

References an existing RT FIFO.

datatype_icon

element

Sets the default return value of an empty RT FIFO. This data type changes to match the type of the default return value you wire.

datatype_icon

timeout in ms

Time, in milliseconds, that the node waits to receive a new value if the RT FIFO is empty. Wire a -1 to the timeout in ms input to wait indefinitely.

Default: 0

datatype_icon

error in

Error conditions that occur before this node runs.

The node responds to this input according to standard error behavior.

Standard Error Behavior

Many nodes provide an error in input and an error out output so that the node can respond to and communicate errors that occur while code is running. The value of error in specifies whether an error occurred before the node runs. Most nodes respond to values of error in in a standard, predictable way.

error in does not contain an error error in contains an error
If no error occurred before the node runs, the node begins execution normally.

If no error occurs while the node runs, it returns no error. If an error does occur while the node runs, it returns that error information as error out.

If an error occurred before the node runs, the node does not execute. Instead, it returns the error in value as error out.

Default: No error

datatype_icon

rt fifo out

A reference to the RT FIFO defined in rt fifo.

datatype_icon

element out

The data read from the RT FIFO. If the node does not read new data, the node returns the default element.

datatype_icon

empty?

A Boolean that indicates whether the RT FIFO is empty when you read it.

True The RT FIFO is empty and the FIFO timed out.
False The RT FIFO is not empty.
datatype_icon

error out

Error information.

The node produces this output according to standard error behavior.

Standard Error Behavior

Many nodes provide an error in input and an error out output so that the node can respond to and communicate errors that occur while code is running. The value of error in specifies whether an error occurred before the node runs. Most nodes respond to values of error in in a standard, predictable way.

error in does not contain an error error in contains an error
If no error occurred before the node runs, the node begins execution normally.

If no error occurs while the node runs, it returns no error. If an error does occur while the node runs, it returns that error information as error out.

If an error occurred before the node runs, the node does not execute. Instead, it returns the error in value as error out.
datatype_icon

number of elements

Number of elements remaining in the RT FIFO after the read or write operation.

Where This Node Can Run:

Desktop OS: Windows

FPGA: Not supported

Web Server: Not supported in VIs that run in a web application


Recently Viewed Topics