BACnetWritePropertyInstanceByHandle (FUN)

FUNCTION BACnetWritePropertyInstanceByHandle : IEC_BACNET_STATUS

Same function as BACnetWritePropertyInstance but uses handle to object instead of an device instance number and object idenfier.

InOut:

Scope

Name

Type

Comment

Return

BACnetWritePropertyInstanceByHandle

IEC_BACNET_STATUS

Input

handleToObject

IEC_BACNET_HANDLE

A valid handle to the object retrieved by a call to BACnetGetObjectHandle.

ePropertyID

IEC_BACNET_PROPERTY_ID

The Property identifier of the local property.

nIndex

IEC_BACNET_ARRAY_INDEX

The index of an array item. If the Property is not an array, the index value BACNET_VOID_INDEX (-1) should be used. If the Property is an array, the index value BACNET_ENTIRE_ARRAY (-1) can be used to write the entire array. If the Property is an array, the index value BACNET_ARRAY_COUNT (0) can be used to resize the array provided that this array can be variable size. The indices of BACnet arrays start counting at 1.

priority

IEC_BACNET_PRIORITY_LEVEL

The priority level for the Write-Property request, if the Property is a commandable Property (such as the present-value property of Output and Value Objects). If the Property is not commandable, the priority level BACNET_VOID_PRI should be used. If the Property is commandable, a priority level from 1 to 16 or BACNET_DEFAULT_PRI (16) can be used. The value is written into the Priority-Array Property of the object, and the highest priority value in that array is used as the value for the commandable property.

pValue

POINTER TO IEC_BACNET_PROPERTY_CONTENTS

A pointer to a Property Contents containing the value of the Property. The Property Contents tag attribute must indicate the data type of the Property.

pError

POINTER TO IEC_BACNET_ERROR

A pointer to store the returned BACnet error code.