NMS_GR303StartInterface

Starts the physical layer (HDLC channels) on a provisioned interface.

Prototype

NMS_GR303_RESULT_T NMS_GR303StartInterface ( NMS_GR303_INTERFACE_ID_T interfaceId)

Argument

Description

interfaceId

Interface ID of a provisioned interface.


Return values

Return value

Description

NMSGR303_SUCCESS

 

NMSGR303_INTERNAL_FAILURE

Internal failure. Refer to the trace log for more information.

NMSGR303_INVALID_INTERFACE_ID

Specified interface is not provisioned.

NMSGR303_INVALID_STATE

Interface is already started.

NMSGR303_NOT_INITIALIZED

NMS GR303 library was not initialized with NMS_GR303Initialize.


Details

NMS_GR303StartInterface starts a specified interface so that applications can use the interface. Applications must invoke NMS_GR303Initialize and NMS_GR303ProvisionInterface prior to calling NMS_GR303StartInterface.

When the HDLC channels on the interface are ready to send or receive frames, the NMS GR303 library invokes an application-defined callback (channel_callback) to send transmit and receive reports to the application.

See also

NMS_GR303StopInterface

Example

void  StartInterface( void )
{
       NMS_GR303_RESULT_T NmsResult;
       DWORD              InterfaceId;

       printf("NMS_GR303StartInterface:\n");    

       /* Get parameters */
       promptdw_nodft("Enter interfaceId", &InterfaceId);

       NmsResult = NMS_GR303StartInterface( InterfaceId );

       printf ("NMS_GR303StartInterface:
                 Result=%s\n",PRINT_RESULT(NmsResult));

}