isupCircuitStatsEx

Sends a request to retrieve the statistics for a given circuit and blocks the calling application while waiting for a response. This function also controls whether the statistics counters are reset after the function execution.

Prototype

short isupCircuitStatsEx ( U8 board, U32 circId, IsupCircStats *stats, U8 reset)

Argument

Description

board

TX board number.

circId

Circuit for which to retrieve statistics.

stats

Pointer to the IsupCircStats structure where the requested statistics information is returned. Refer to isupCircuitStats for the structure definition.

reset

Indicates whether to reset the statistics counters after function execution:

0 = Reset the statistics counters to zeroes.

1 = Do not reset the statistics counters.


Return values

Return value

Description

ISUP_SUCCESS

 

ISUP_BOARD

board is out of range.

ISUP_DRIVER

Error occurred accessing the driver.

ISUP_FAILED

Task on the TX board returned a failure.

ISUP_UNBOUND

Application failed to call isupInitMgmtAPI prior to this call.


Examples

S16            status;
U8             boardNum = 1;
U32            circId = 1;
IsupCircStats  sts;
U8             resetStats=1;

if ((status = isupCircuitStatsEx(boardNum, circId, &sts, resetStats)) !=
        ISUP_MGMT_SUCCESS)
{
    printf( "Board %d Circuit %d Statistics Request failed: status = %d\n",
        boardNum, circId, status );
}
else
    printf( “Successfully retrieved circuit statistics for circuit %d on board %d\n",
        circId, boardNum );

/* The sts structure contains the circuit statistics information
}