SERVICEHANDLER_PARAMETER
(STRUCT)
TYPE SERVICEHANDLER_PARAMETER : STRUCT
- InOut:
Name
Type
Comment
ulChannelId
UDINT
Id of the channel on which the request arrived
pHeaderTag
POINTER TO HEADER_TAG
Pointer to the header struct of the received request
pduData
References the request data (without header)
pduSendBuffer
Contains the buffer (pointer and length) for the reply data
Result
RTS_IEC_RESULT
Result code; is used as inout parameter. When the corresponding event is posted, then this value is already pre-initalized with error code: - ERR_PENDING: Event was already posted before for the same received service request. The previous call returned ERR_CALL_AGAIN. - All other values (most likely ERR_L7_UNKNOWNCMD): Event for the received service request is posted the first time. Typical result codes, which should be returned by the event handler: - ERR_OK: Received service was completely handled. - ERR_CALL_AGAIN: Received service will be handled asynchronously. Event should be signaled again to poll the service reply. - ERR_L7_UNKNOWNCMD: Service is unknown by the event handler. - All other error codes: Runtime will send this result in a generic error tag as reply (or close the channel).