Previous PageTable Of Contents../index.htmlIndexNext Page

scx_getevtmsk( )

Description | Cautions | Example | Errors | See Also

Name:

int scx_getevtmsk (devh, bitmask)

Inputs:

int devh

  SCX160 SCxbus Adapter device handle

 

unsigned short *bitmask

  pointer to where the event bitmask will be returned

Returns:

0 on success
-1 on failure

Includes:

scxlib.h

Category:

Configuration

Mode:

synchronous

Top Of PageDescription

The scx_getevtmsk( ) function retrieves alarm event mask. This function identifies the events enabled for a specified station.

Parameter

Description

devh:

SCX160 SCxbus Adapter device handle

bitmask:

Specifies the pointer to the buffer where the bitmask will be returned. The bitmask retrieved as a result of this call may be any combination of the following event mask equates:

  SCXMM_EXT_CLOCK - external clock event mask

  SCXMM_FIFO - SCX160 FIFO event mask

  SCXMM_SC_CLOCK - SCbus clock event mask

  SCXMM_SC_DRIVER - SCbus driver event mask

  SCXMM_SCX_CLOCK - SCxbus clock event mask

  SCXMM_SCX_DRIVER - SCxbus driver event mask

When an SCX160 SCxbus Adapter alarm event is generated, the event code returned by the sr_getevttype( ) function is TSCX_ALARM. The data field returned by the sr_getevtdatap( ) function contains the specific alarm information and is two bytes long. The first byte represents one of the following bitmask values:

Equate

Description

SCXEV_SCBUS_CLOCK

SCbus clock event

SCXEV_SCXBUS_CLOCK

SCxbus clock event

SCXEV_EXT_CLOCK

External clock event

SCXEV_SCBUS_DRIVER

SCbus driver event

SCXEV_SCXBUS_DRIVER

SCxbus driver event

SCXEV_FIFO

SCX160 FIFO event

The second byte provides additional details about the event reported by the first byte as follows. If any clock event is returned, then the second byte represents one of the following:

Equate

Description

SCXST_SCX_RCLOCK

SCxbus Right Clock failed/recovered

SCXST_SCX_LCLOCK

SCxbus Left Clock failed/recovered

SCXST_SC_CLOCK

SCbus Clock failed/recovered

SCXST_SC_CLOCK_FAIL_SIG

SCbus Clock Fail Signal failed/recovered

SCXST_EXTCLOCK

SCX160 External Clock failed/recovered

SCXST_PLL_REF

SCX160 PLL Reference failed/recovered

SCXST_INTCLOCK

SCX160 Internal Clock failed/recovered

SCXST_CLK_RECOVER

Recovery of Clock

If any driver event is returned, then the second byte represents either of the following:

Equate

Description

SCXBE_SC_BER

SCbus BER Threshold Exceeded

SCXBE_SCX_BER

SCxbus BER Threshold Exceeded

When a FIFO event is returned, then the second byte represents one of the following:

Equate

Description

SCXFS_SC_POS_SLIP

SCbus FIFO Positive Slip Threshold Exceeded

SCXFS_SC_NEG_SLIP

SCbus FIFO Negative Slip Threshold Exceeded

SCXFS_SCX_POS_SLIP

SCxbus FIFO Positive Slip Threshold Exceeded

SCXFS_SCX_NEG_SLIP

SCxbus FIFO Negative Slip Threshold Exceeded

SCXFS_SC_SKEW

SCbus FIFO Skew Threshold Exceeded

SCXFS_SCX_SKEW

SCxbus FIFO Skew Threshold Exceeded

See Section 9.2.  Handling Events for an example of handling unsolicited events.

Top Of PageCautions

This function will fail if an invalid device handle is specified.

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