IEC_BACNET_READ_FILE_RESULT (STRUCT)

TYPE IEC_BACNET_READ_FILE_RESULT : STRUCT

Describes the structure in which an AtomicReadFile response is returned.

The Read File Result data (data type BACNET_READ_FILE_RESULT) contains the result of reading. This data type contains a boolean End Of File parameter which indicates does the response include the last octet of the file, Access Type field, and a number of fields which describe the memory block containing the file contents. In the Stream case there are a Start Position field and an Octet String field. In the Record case there are a Start Record Number field, a Record Count field that indicates a number of records to read, and a Buffer field. The buffer is formatted as an array of BACNET_OCTET_STRING values which represent the records. The Start position and start record counts begin from zero. If the Octet String field or Buffer field is not big enough to hold the actual result, a BACNET_STATUS_OUT_OF_SPACE reply will be returned.

InOut:

Name

Type

Comment

endOfFile

IEC_BACNET_BOOLEAN

The ‘End Of File’ parameter, of type BOOLEAN, shall be equal to TRUE if this response includes the last octet of the file and FALSE otherwise. This parameter shall be used to check for the end of file since the number of octets returned could be less than the ‘Requested Octet Count’ or the ‘Returned Record Count’ could be less than the ‘Requested Record Count’ due to the amount of data remaining in the file. This parameter also provides a data-independent way for the client user of this service to detect an end of file.

accessType

IEC_BACNET_FILE_ACCESS_TYPE

Describes the type of the access made in the AtomicReadFile service

data

UNION_BACNET_READ_FILE_RESULT

Specifies the range result for reading access to file objects