optional
function
Declaration
function GetDecoderMessages(
var pOutMsg : Pointer;
var outLen : integer
): integer; stdcall;
Arguments
pOutMsg : pointer to output data
outLen : length of output data
Function Result
= 0 : OK
≠ 0 : failure
Description
A decoder can provide several decoder-messages. Use this function to query the appropriate messag ID's. If the function succeeds then it allocates global memory where the result data will be passed. The variable 'pOutMsg' provides the pointer to this memory and the variable 'outLen' provides the number of bytes of the allocated memory.
Note: The caller of this function has to free the allocated memory.
The function has to provide a XML structure as result, as shown in the following example:
<PROTOCOL_MESSAGES>
<PROTOCOL_MESSAGE>
<SID>2</SID>
<NAME>MSG_CMD_1</NAME>
</PROTOCOL_MESSAGE>
<PROTOCOL_MESSAGE>
<SID>8</SID>
<NAME>MSG_CMD_2</NAME>
</PROTOCOL_MESSAGE>
</PROTOCOL_MESSAGES>
If a decoder library does not provide this function or this function fails then the default message-id 'sid=0' will be passed.