BACnetRetrieveExtraInfoForLastIllegalResponseStatus (FUN)

FUNCTION BACnetRetrieveExtraInfoForLastIllegalResponseStatus : IEC_BACNET_STATUS

This function retreives extra error information in case some invalid / illegal response has been recieved for a previously sent request.

In case of some invalid or illegal received response the status BACNET_STATUS_ILLEGAL_RESPONSE is returned by the requesting client function (e.g. BACnetReadProperty(…)). In this case this function may be used to get more information about the error detected in the response. This function will get the extra information for the last received response with detected errors.

Return: IEC_BACNET_STATUS

InOut:

Scope

Name

Type

Comment

Return

BACnetRetrieveExtraInfoForLastIllegalResponseStatus

IEC_BACNET_STATUS

Input

ptService

POINTER TO IEC_BACNET_SERVICE_EXECCODE

A ponter to store the service code for which an invalid or illegal response was received. Can be NULL if application does not need this information.

ptError

POINTER TO IEC_BACNET_ERROR

A pointer to store the BACnet error code generated for the invalid / illegal response. Can be NULL if application does not need this information.

pszDebugInfoBuffer

POINTER TO IEC_BACNET_BYTE

A pointer to a large buffer for storing the ASCII decoded and parsed ASN1 request. This feature is only available if the stack API was build bith the define DO_ASCII_DECODING. Can be NULL if application does not need this information.

nAsciiBufferSize

IEC_BACNET_UINT

Contains the size of the debug info buffer in bytes. If the buffer is too small the decoding is trucated to the buffer size.

pAsn1InfoBuffer

POINTER TO IEC_BACNET_BYTE

A pointer to a buffer to store the complete received response in ASN1 encoding. Can be NULL if application does not need this information.

pnAsn1BufferSize

POINTER TO IEC_BACNET_UINT

As input it shall contain the size of the buffer. As output it will contain the size of the ASN1 response received.

pAsn1ErrorBuffer

POINTER TO IEC_BACNET_BYTE

A ponter to a buffer to strore the part of the ASN1 encoding which contains the error. Can be NULL if application does not need this information.

pnAsn1ErrorSize

POINTER TO IEC_BACNET_UINT

As input it shall contain the size of the buffer. As output it will contain the size of the ASN1 response part which contains the error.