Table of Contents Index NMS Glossary Previous Page Next Page (Page 6 of 29 in this chapter) Version


swiConfigLocalTimeslot

Description

Configures stream-specific and timeslot-specific characteristics of a local device.

Prototype

DWORD swiConfigLocalTimeslot (SWIHD swihd,
SWI_LOCALTIMESLOT_ARGS *args,
void *buffer,
unsigned size)

swihd Handle returned by swiOpenSwitch.

args Pointer to a SWI_LOCALTIMESLOT_ARGS structure for configuring a device associated with a local stream and timeslot. The SWI_LOCALTIMESLOT_ARGS structure is:


typedef struct
{
DWORD localstream;
DWORD localtimeslot;
DWORD deviceid;
DWORD parameterid;
} SWI_LOCALTIMESLOT_ARGS;
See the Details section for a description of these fields.

buffer Pointer to timeslot specific information interpreted by the device driver.

size Size of buffer, in bytes.

Return Values

Events

Details

This function configures stream-specific and timeslot-specific characteristics of a local device. The content of the buffer portion of the call contains the configuration information and is vendor-dependent and device-dependent.

The SWI_LOCALTIMESLOT_ARGS structure contains the following fields:
Field

Description

localstream

The stream to be configured on the local bus.

localtimeslot

The timeslot to be configured on the local bus.

deviceid

The device type on the local bus. The deviceid is hardware dependent. Acceptable values for deviceid are:

MVIP95_T1_TRUNK_DEVICE
MVIP95_E1_TRUNK_DEVICE
MVIP95_ANALOG_LINE_DEVICE
MVIP95_CONFERENCE_DEVICE

In addition to these values, the device vendor may define device identifiers specific to their products. Refer to the device specific documentation for these values.

parameterid

The data item for which configuration is to be performed. This value is vendor-specific and device driver-specific. The combination of the deviceid and the parameterid specify the part of the device to configure.

Refer to Section 6.3, Board and Driver Configuration for more information.

If CTAERR_DRIVER_ERROR is returned, call swiGetLastError to retrieve the MVIP device error code.

Refer to the documentation for the board you are using for board-specific information.

See Also

swiConfigLocalStream, swiGetBoardInfo, swiGetDriverInfo, swiGetLastError, swiGetLocalStreamInfo, swiGetLocalTimeslotInfo, swiOpenSwitch

Example


void myConfigChannels(SWIHD age1hd)
{
SWI_LOCALTIMESLOT_ARGS args;
struct channel_parms cp;
DWORD i;

args.localstream = 0;
args.deviceid = MVIP95_T1_TRUNK_DEVICE;
args.parameterid = CONFIG_CHANNEL;

cp.size = sizeof(struct channel_parms);
cp.invert = 0;
cp.loopback = 0;
cp.robbedbit = 1;

for (i = 0; i < 24; i++)
{
args.localtimeslot = i;
cp.trunk = i;
swiConfigLocalTimeslot(age1hd, &args, &cp, cp.size);
}
}


Table of Contents Index NMS Glossary Previous Page Next Page (Page 6 of 29 in this chapter) Version


Want to send us feedback on our documentation? Email: Tech_Pubs@nmss.com
Copyright © 2000, Natural MicroSystems, Inc. All rights reserved.