
6.10 MAC_IsDevicePresent
This function enables the user to check Multi-axes controller IP address
Syntax:
int MAC_IsDevicePresent ( LPCTSTR cszHost, DWORD* pdwIP );
Input Parameters:
LPCTSTR cszHost - Host name or IP Address of controller.
Output Parameter:
DWORD* pdwIP - IP address of controller (NULL, if is Host not found).
Return Value:
int - command status: if 0 - OK,
else error code:
1 The API library is not initialized;
2 Invalid input parameter: zero pointer;
3 Unable to create interface
CLSID_MaestroLocator
4 The MAS Locator failed
5 The device is not found
Use MAC_GetLastError to retrieve the error string.
Sample:
int retVal = MAC_IsDevicePresent( _T("10.10.10.52"), &dwIP );
6.11 MAC_LocateObjects
This function enables the user to start motion objects search
Motion object can be one of the following:
- Axis: Either Elmo_Axis or Axis_402 .
- Group: Several axes that may be addressed simultaneously.
- Vector: Is a group of two axes that perform a synchronized motion.
Syntax:
int MAC_LocateObjects( COMMUNICATION_HANDLE hCommunication,
MOTION_OBJECT_TYPE moType );
Input Parameters:
COMMUNICATION_HANDLE hCommunication
Multi-axes supervisor communication handle.
MOTION_OBJECT_TYPE moType
motion object type mask for current search NULL - all motion objects
Maestro Software Manual The Maestro API
MAN-MASSW (Ver. Q)
6-8
Komentarze do niniejszej Instrukcji