PREV TOC HOME INDEX NEXT


NCM_DetectBoards( )


Description | Cautions | Example | Error Codes

Name:

NCMRetCode NCM_DetectBoards( pCallBackFunc, pnNumBrdsFound )

Inputs:

GL_PROG_FUNC *pCallBackFunc
  • pointer to a callback function
int *pnNumBrdsFound
  • pointer to variable indicating the number of boards found through the auto-detect process

Returns:

NCM_SUCCESS if success NCM error code if failure

Includes:

NCMApi.h

Mode:

synchronous

Description

The NCM_DetectBoards( ) function initiates a process that detects auto-detectable boards installed in the system. For more information about auto-detection, see Section 2.6.1, Auto Detection.

The function parameters are defined as follows:

Parameter

Description

pCallBackFunc Pointer to a function that is part of the client application and will be called by the DCM API to provide updates on the status of the auto-detection process. (See Cautions below.)
pnNumBrdsFound Pointer to a variable where the number of boards found through the auto-detection process will be stored. The client application must declare the variable referenced by this pointer prior to calling NCM_DetectBoards( ).

Cautions

Intel® Dialogic recommends using the NCM_DetectBoards ( ) function for non-DM3 boards only.

All auto-detectable Intel® Dialogic devices in the system must be detected using either the NCM_DetectBoards( ) function or the NCM_DetectBoardsEx( ) function before the NCM_StartDlgSrv( ) function can be used to start the Intel® Dialogic System Service. Refer to Section 2.6.1, Auto Detection for information about auto-detectable Intel® Dialogic devices.

The callback function referenced by the pCallBackFunc pointer must have the following format:

If pCallBackFunc is NULL, then no message is sent to the client application from the detection process.

Example

#include "NCMApi.h" 
int CallBackFunc( UINT uipercent, const char *message )
{
     // use the percentage and message
     // to show status of the auto-detection process 
     return TRUE;
} 
... 
int      nNumBoardsFound = 0; 
//
// Execute
// 
NCMRetCode ncmRc = NCM_DetectBoards( CallBackFunc, &nNumBoardsFound );
... 

Error Codes

Equate

Returned When

NCME_REG_CALLBK callback function cannot be registered with initialization process
NCME_BRD_DETECT auto-detect failed
NCME_SP invalid state transition
NCME_CTBB_DEVICE_DETECTED error configuring the TDM Bus
NCME_GENERAL a problem occurred retrieving the data
NCME_DETECTOR_LIB_NOT_FOUND there was an error loading the detector library
NCME_DETECTOR_FCN_NOT_FOUND there was an error getting the detector function


PREV TOC HOME INDEX NEXT

Click here to contact Telecom Support Resources

Copyright 2003, Intel Corporation
All rights reserved
This page generated January, 2003