BACnetDecodeAsn1StandardProperty (FUN)ΒΆ

FUNCTION BACnetDecodeAsn1StandardProperty : IEC_BACNET_STATUS

Decodes the given BACnet ASN1 encoded property data type into an property contents buffer.

Decodes the given BACnet ASN1 encoded property data type into an property contents buffer. The encoded data has to match the expected encoding given by the object type and property identifier which correspond to an defined BACnet data type structure. If the encoding does not match an corresponding error will be returned. In some cases some mismatch of the ASN1 encoded data can not be detected and thus c-structures with invalid data may be created as result.

Return: IEC_BACNET_STATUS

InOut:

Scope

Name

Type

Comment

Return

BACnetDecodeAsn1StandardProperty

IEC_BACNET_STATUS

Input

objType

IEC_BACNET_OBJECT_TYPE

The object type the encoded data belongs to.

propID

IEC_BACNET_PROPERTY_ID

The object types property the encoded data belongs to.

arrayIndex

IEC_BACNET_ARRAY_INDEX

The object types property array index the encoded data belongs to.

pPropCont

POINTER TO IEC_BACNET_PROPERTY_CONTENTS

Pointer to the BACnet property contents structure which will contain the decoded c-structure. The rawBuffer member of this structure will be set to the given ASN1 data. If the buffer.pBuffer member is NULL and the buffer.nBufferSize member is 0 the memory required to store the converted c-structure data will be allocated and needs to be freed by the user.

pAsn1Encoded

POINTER TO IEC_BACNET_BYTE

Pointer to the BACnet ASN1 encoded data.

encodedSize

IEC_BACNET_UINT

The length in bytes of the BACnet ASN1 encoded data.