User Manual

Table Of Contents
EK-5209-5 Evaluation Kit User’s Guide A-25
iBeanAPI_Utils.h
3. ibApi_Utils_ConvertTextToGroupID()
ibApi_FUNC ibApi_Utils_ConvertTextToGroupID(
ibApi_CONST ibApi_CHAR * group_id_text,
ibApi_GROUPID * group_id
);
This parses a text string such as “1.2.3.4” and stores the result in the group_id structure. If
fewer than 4 digit groups are provided, the result is left-padded with 0’s.
Parameters:
group_id_text: (input) Buffer to be parsed.
group_id: (output) Structure to store the result.
Return Value:
ibApi_RESULT_SUCCESS if successful, error code (<0) if not.
4. ibApi_Utils_ConvertDeviceIdToText()
ibApi_FUNC ibApi_Utils_ConvertDeviceIdToText(
ibApi_DEVICEID device_id,
ibApi_CHAR * device_id_text,
ibApi_UINT32 device_id_text_size,
ibApi_UINT32 min_words
);
This renders a device ID as a text string such as “1.2.3.4.5.6.7.8”. If the “min_words”
parameter is less than 8, leading zeros will be omitted for brevity. For example, if min_words
is 4, then 0.0.0.0.0.5.1 would be rendered as “0.0.5.1”.
Parameters:
device_id: (input) Device ID to convert.
device_id_text: (output) Buffer to store the text.
device_id_text_size: (input) Maximum size of the buffer.
min_words: (input) Minimum number of digit groups.
Return Value:
Error code, or the actual size of the result including the terminating NULL (which could
exceed device_id_text_size if the written data was truncated).
5. ibApi_Utils_ConvertTextToDeviceId()
ibApi_FUNC ibApi_Utils_ConvertTextToDeviceId(
ibApi_CONST ibApi_CHAR * device_id_text,
ibApi_DEVICEID * device_id
);