Raptor:Data Logging File Read

From NewEagleWiki
Jump to navigation Jump to search

Return to the main Raptor page

Return to File IO page

Raptor™ Data Logging File Read

Description

This block will take in the file handle and length of a message to be read. It will then output a uint8 array of the given length.

The value provided to the "Length" input of the block will determine the number of characters read from the target file. The value provided to the mask parameter: "Output Size" determines the size of the character array output by the read block. If these values differ (e.g. Output Size is larger than "Length"), the remaining characters output in the Data array will be unitialized and may contain undesired values.

As with many of the other datalogging and file I/O Raptor blocks, this block takes a file handle as an input, and propagates the same file handle through the block logic to an output of the block. By connecting the File Handle output of file I/O block 'X' to the File Handle input of file I/O block 'Y', application designers can ensure that the logic executed by block Y will be performed after the logic executed by block X.

Inputs

Input Type Description
File Handle file type A number the operating system temporarily assigns to a file when it is opened
Length int32 The length of data that will be read.

Outputs

Output Type Description
File Handle file type A number the operating system temporarily assigns to a file when it is opened
Data uint8[] An array of data that is output in packets that are the size of the 'Length' input (up to 10 bytes).
Length int32 The length of data that is being read.

Parameters

Parameter Type Description
Hardware Resource Specified hardware from which the file will be opened.
Output Size Determines the size of the character array to be output by the block.