Previous PageTable Of Contents../index.htmlIndexNext Page

scx_getbrdparm( )

Description | Cautions | Example | Errors | See Also

Name:

int scx_getbrdparm(devh, parm, valuep)

Inputs:

int devh

  SCX160 SCxbus Adapter device handle

 

unsigned char parm

  parameter defined name

 

void *valuep

  pointer where value will be returned

Returns:

0 on success
-1 on failure

Includes:

scxlib.h

Category:

Configuration

Mode:

synchronous

Top Of PageDescription

The scx_getbrdparm( ) function retrieves board parameters. Parameters may be informative, defaults or values previously set by the scx_setbrdparm( ) function. Each parameter has a symbolic name defined in the scxlib.h file.

Parameter

Description

devh:

Specifies the SCX160 SCxbus Adapter device handle.

parm:

Specifies the name of the parameter. See Table 12.  SCX160 SCxbus Adapter Parameters below for a complete list of parameters. The user selectable parameters, designated by a "W" (write) in the "R/W" (read/write) column, can be set using the scx_setbrdparm( ) function.

valuep:

Points to the buffer where the parameter value will be returned.

Top Of PageCautions

Ensure that the valuep buffer is large enough to receive the parameter value, see Table 12.  SCX160 SCxbus Adapter Parameters below. This function will fail if an invalid device handle is specified.


Table 12.  SCX160 SCxbus Adapter Parameters

Define

B

Default

R/W

Description

SCXBP_SCX_CLOCK_MODE

1

Default SCxbus clocking configured at download time.

R/W

Specifies clocking for the SCxbus interface of the SCX160 SCxbus Adapter. The SCxbus interface can be set to any of the following:

  SCXCM_MASTER - provides right SCxbus clock

  SCXCM_SLAVE - receives clock from another SCxbus device

  SCXCM_FALLBACK_MASTER - receives right clock from another SCxbus device, and generates left SCxbus clock to be used by other SCxbus devices if the right SCxbus clock is unavailable

SCXBP_CLOCK_REF

1

Default SCX160 Clock Reference Signal configured at download time.

R/W

Specifies source of the SCX160 SCxbus Adapter clock reference signal. The clock source can be any one of the following:

  SCXCS_INTERNAL - use Internal Clock

  SCXCS_SCBUS - derive clock from SCbus

  SCXCS_SCXBUS_RIGHT - derive clock from SCxbus Right Clock

  SCXCS_SCXBUS_LEFT - derive clock from SCxbus Left Clock

  SCXCS_EXTERNAL - use External 8 kHz Clock

SCXBP_FIFO_ERR_THRESH

4

0xFFFFFFFF

R/W

Specifies FIFO buffer error threshold that must be exceeded before an alarm is generated:

  Lower word is Over Flow/Under Flow (Slip) Threshold (Valid Range: 0 _ Thresh _ 0xFFFF)

  Upper word is Frame Error Threshold (Valid Range:0 _ Thresh _ 0xFFFF)

SCXBP_DRIVER_ERR_THRESH

4

0xFFFFFFFF

R/W

Specifies SCX160 driver error threshold that must be exceeded before an alarm is generated:

  Lower word is SCbus Threshold (Valid Range:0 _ Thresh _ 0xFFFF)

  Upper word is SCxbus Threshold (Valid Range:0 _ Thresh _ 0xFFFF)

SCXBP_SC_CLOCK_MODE

1

Default SCbus clocking configured at download time.

R/W

Specifies clocking for SCbus interface of the SCX160 SCxbus Adapter. The SCbus interface can be set to any of the following:

  SCXCM_MASTER - provides SCbus clock

  SCXCM_SLAVE - receives clock from another SCbus device

  SCXCM_FALLBACK_MASTER - receives clock from another SCbus device. However, it is armed to provide master SCbus clock if the master clock fails.

SCXBP_SC_MAP

2

SCbus data stream mapping configured at download time.

R

The SCbus data stream bitmap. The values are as follows:

  0x0000 indicates that no SCbus data streams are assigned

  0x0001 indicates that the first of 16 SCbus data streams is assigned

  0xFFFF indicates that all SCbus data streams are assigned

SCXBP_SCX_MAP

2

SCxbus data stream mapping configured at download time.

R

The SCxbus data stream bitmap. The values are as follows:

  0x0000 indicates that no SCxbus data streams are assigned

  0x0001 indicates that the first of 16 SCxbus data streams is assigned

  0xFFFF indicates that all SCxbus data streams are assigned

SCXBP_CLK_HISTORY

1

0

R

SCX160 Clock History Bitmask. Upon detection of a SCX160 Clock event, the value of this parameter may be retrieved to determine the specific clock event that was detected. When the SCXST_CLK_RECOVER bit is set in conjunction with another set bit, then the clock with the set bit is recovered. Otherwise, when the SCXST_CLK_RECOVER bit is 0, then any other set bit indicates that the clock with the set bit failed. The value of this parameter is set to 0 after the parameter is read. Possible values may be any combination of the following:

  SCXST_SCX_RCLOCK - SCxbus Right Clock failed or recovered

  SCXST_SCX_LCLOCK - SCxbus Left Clock failed or recovered

  SCXST_SC_CLOCK - SCbus Clock failed or recovered

  SCXST_SC_CLOCK_FAIL_SIG - SCbus Clock Fail Signal

  SCXST_EXTCLOCK - SCX160 External Clock failed or recovered

  SCXST_PLL_REF - SCX160 PLL Reference failed or recovered

  SCXST_INTCLOCK - SCX160 Internal Clock failed or recovered

  SCXST_CLK_RECOVER - Recovery of Clock

SCXBP_CLK_STATE_BYTE

1

0

R

SCX160 Clock State Bitmask. The value of this parameter may be retrieved to determine the current clock state of the SCX160 see (Chapter 4.  Clocking). When set, indicates loss of clock. Possible values may be any combination of the following:

  SCXST_SCX_RCLOCK - SCxbus Right Clock state

  SCXST_SCX_LCLOCK - SCxbus Left Clock state

  SCXST_SC_CLOCK - SCbus Clock state

  SCXST_SC_CLOCK_FAIL_SIG - SCbus Clock Fail Signal state

  SCXST_EXTCLOCK - SCX160 External Clock state

  SCXST_PLL_REF - SCX160 PLL Reference state

  SCXST_INTCLOCK - SCX160 Internal Clock state

SCXBP_SCX_FIFO_STAT

1

0

R

SCX160 FIFO Fail Bitmask. Upon detection of a SCX160 FIFO Error, the value of this parameter may be retrieved to determine the specific FIFO error detected. Possible values may be any combination of the following:

  SCXFS_SC_POS_SLIP - SCbus FIFO Positive Slip Exceeded

  SCXFS_SC_NEG_SLIP - SCbus FIFO Negative Slip Exceeded

  SCXFS_SCX_POS_SLIP - SCxbus FIFO Positive Slip Exceeded

  SCXFS_SCX_NEG_SLIP - SCxbus FIFO Negative Slip Exceeded

  SCXFS_SC_SKEW - SCbus FIFO Skew Exceeded

  SCXFS_SCX_SKEW - SCxbus FIFO Skew Exceeded

SCXBP_SCX_BER_STAT

1

0

R

SCX160 Bit-Error-Rate Bitmask. Upon detection of a SCX160 Bus Driver Error, the value of this parameter may be retrieved to determine the specific error detected. Possible values may be any combination of the following:

  SCXBE_SC_BER - SCbus BER Threshold Exceeded

  SCXBE_SCX_BER - SCxbus BER Threshold Exceeded

SCXBP_SCX_BER_HISTORY

4

0

R

SCX160 Bit-Error-Rate History Bitmask. Upon detection of an SCX160 Bus Driver Error, the value of this parameter may be retrieved to determine the specific error detected. Possible values may be any combination of the following:

The first two bytes provide the SCbus Bus Driver Error bitmap. The values are as follows:

  0x0000 indicates that no SCbus data streams exceeded the BER threshold

  0x0001 indicates that the first of 16 SCbus data streams exceeded BER threshold, and

  0xFFFF indicates that all SCbus data streams exceeded BER threshold

The second two bytes provide the SCxbus Bus Driver Error bitmap. The values are as follows:

  0x0000 indicates that no SCxbus data streams exceeded BER threshold

  0x0001 indicates that the first of 16 SCxbus data streams exceeded BER threshold, etc.

SCXBP_SC_DR_ERR_CNT

32

none

R

SCbus Driver Error Count for each data stream is stored in a 16 bit counter.

SCXBP_SCX_DR_ERR_CNT

32

none

R

SCxbus Driver Error Count for each data stream is stored in a 16 bit counter.

SCXBP_SC_FIFO_OVER_CNT

24

none

R

SCbus FIFO Overflow Error Count. 12 - two byte hourly error count windows:

  window 0 is error count for current hour

  window 11 is hourly error count from 11 hours ago

SCXBP_SCX_FIFO_OVER_CNT

24

none

R

SCxbus FIFO Overflow Error Count. 12 - two byte hourly error count windows:

  window 0 is error count for current hour

  window 11 is hourly error count from 11 hours ago

SCXBP_SC_FIFO_UNDR_CNT

24

none

R

SCbus FIFO Underflow Error Count. 12 - two byte hourly error count windows:

  window 0 is error count for current hour

  window 11 is hourly error count from 11 hours ago

SCXBP_SCX_FIFO_UNDR_CNT

24

none

R

SCxbus FIFO Underflow Error Count. 12 - two byte hourly error count windows:

  window 0 is error count for current hour

  window 11 is hourly error count from 11 hours ago

SCXBP_SC_FIFO_SKEW_CNT

24

none

R

SCbus FIFO Skew Error Count. 12 - two byte hourly error count windows:

  window 0 is error count for current hour

  window 11 is hourly error count from 11 hours ago

SCXBP_SCX_FIFO_SKEW_CNT

24

none

R

SCxbus FIFO Skew Error Count. 12 - two byte hourly error count windows:

  window 0 is error count for current hour

  window 11 is hourly error count from 11 hours ago

SCXBP_SCX_BOARD_STAT

1

none

R

SCX160 Board Status Bitmask. This parameter may be retrieved to determine the current status of the SCX160 board (see Chapter 4.  Clocking). Possible values may be any combination of the following:

SCXBS_SELF_TEST - SCX160 Board Self Test Results (Bit 1):

  0 - Passed Self Test

  1 - Failed Self Test

SCXBS_DOWNLOAD - SCX160 Board Download State (Bit 2):

  0 - Not Downloaded

  1 - Downloaded

SCXBS_RUN_STATE - SCX160 Firmware Run State (Bit 3):

  0 - Not Started

  1 - Started

SCXBS_SCX_CLOCK_
STATE - SCxbus Clock State (Bits 4-6); possible values are:

  SCX_MASTER - operating as SCxbus Clock Master

  SCX_WAIT_SLAVE - operating as SCxbus Clock Master. Waiting to become SCxbus Clock Slave

  SCX_SLAVE - operating as SCxbus Clock Slave

  SCX_WAIT_FB_MASTER - operating as SCxbus Clock Slave. Waiting to become SCxbus Clock Master

  SCX_FB_MASTER - operating as SCxbus Clock Fallback Master

  SCX_WAIT_MASTER - operating as SCxbus Clock Fallback Master. Waiting to become SCxbus Clock Master

  SCX_FB_WAIT_SLAVE - operating as SCxbus Clock Fallback Master. Waiting to become SCxbus Clock Slave

  SCXBS_SC_CLOCK_
STATE - SCbus Clock State (Bits 7-8); possible values are:

  SC_MASTER - operating as SCbus Clock Master

  SC_WAIT_MASTER - Waiting to become SCbus Clock Master

  SC_SLAVE - operating as SCbus Clock Slave

  SC_FB_MASTER - operating as SCbus Clock Fallback Master

Legend:

  B (2nd) column lists the length in Byte(s)

  R/W column: R = Read; W = Write

Top Of PageExample

Top Of PageErrors

If the function returns -1, use the SRL Standard Attribute function ATDV_LASTERR( ) to obtain the error code, or you can use the ATDV_ERRMSGP( ) function to obtain a descriptive error message. The error codes returned by ATDV_LASTERR( ) function are listed in Chapter 7.  Errors.

Top Of PageSee Also


Previous PageTable Of ContentsTop Of PageIndexNext Page

Click here to contact Dialogic Customer Engineering

Copyright 2001, Dialogic Corporation
All rights reserved
This page generated February, 2002