Download TelePACE C Tools User Manual

Transcript
Telepace C Tools Function Specifications
hartCommand11
Read Unique Identifier Associated with Tag
Syntax
#include <ctools.h>
BOOLEAN hartCommand11(unsigned module, char * deviceTag,
HART_DEVICE * device);
Description
This function reads the unique identifier of a HART device using command 11.
This is a link initialization function.
The function has three parameters: the module number of the 5904 module (0 to
3); a pointer to a null terminated string containing the tag of the HART device;
and a pointer to a HART_DEVICE structure. The information read by command
11 is written into the HART_DEVICE structure when the response is received by
the 5904 interface.
The function returns TRUE if the command was sent. The function returns
FALSE if the module number is invalid.
Notes
The function returns immediately after the command is sent. The calling program
needs to wait for the response to be received. Use the hartStatus command to
read the status of the command.
The number of attempts and the number of preambles sent are set with the
hartSetConfiguration command.
A program needs to initialize the link before executing any other commands.
See Also
hartCommand0, hartStatus, hartSetConfiguration
Document (Version 2.50) 5/12/2011
260