Avaya Logo

Home

Previous Topic

Next Topic

Book Contents

Book Index

setparam

The setparam instruction sets a parameter associated with a script.

Synopsis

include "tas_defs.h"
setparam(type.param, type.value)

Description

The setparam instruction dynamically sets a parameter associated with a script. Note that Register 0 (r.0) is set to a negative number if the instruction fails.

The following are possible parameters that can be specified:

Service

Service type

SDN (including GSDN)

SVC_SDN

MEGACOM 800

SVC_MEGACOM800

MEGACOM

SVC_MEGACOM

INWATS

SVC_INWATS

WATS maximal subscribed band

SVC_WATS

ACCUNET switch digital

SVC_ACCUNET

Nodal Long Distance Service

SVC_NODAL_LDS

International 800

SVC_I800

ETN

SVC_ETN

Private Line

SVC_PRIVATE_LINE

DIAL IT NOVA, MULTIQUEST

SVC_DIALITNOVA

Reserved (CNO)

SVC_RESERVED_CNO

Note:
If you specify a service type that is not available, typically the tic instruction returns the value `p' in r.0. r.1 typically contains the value CV_MIGGINGIE (96) or CV_SERVICENA (63) depending on the switch software.

If the service you need to specify is not included in tas_defs.h, use the following lines:

#define SPECIAL_SERVICE X /* service type you want to use */
setparam(SERVICE_TYPE,
SPECIAL_SERVICE)

where X is a number between 0 and 31 that is to be placed in the Facility Coding Value field of the Network-Specific Facilities information element of the ISDN SETUP message.

Bearer

Bearer Capability

Speech

BEAR_SPEECH

Unrestricted digital

BEAR_DIGITAL

Restricted digital

BEAR_RDIGITAL

Modem 3.1 KHz audio

BEAR_MODEM

IRD_BLOCKFOREVER (defined in irDefines.h)

Wait as long as necessary for the resource to become available.

IRD_IMMEDIATE (defined in irDefines.h)

Fail if the resource is not immediately available.

<N> where N is any positive integer

Wait for N hundredths of a second for the resource to become available.

Example

The following example shows how to use the setparam instruction in an application to specify Nodal Long Distance Service when placing an outbound call.

#include "tas_defs.h" /* Contains SERVICE_TYPE macro definitions */

#define DIALED_NUMBER 0 /* Location of character string to be dialed */

/* Specify the speech file you wish to use */
tfile(application)

Begin:
/* Set service type for outgoing call to
Nodal Long Distance */
setparam(SERVICE_TYPE, SVC_NODAL_LDS)

/* initialize character string to be dialed */
strcpy(ch.DIALED_NUMBER,
"6145551212")

/* Originate call */
tic (`O', ch.DIALED_NUMBER)

...

� 2003 Avaya Inc. All Rights Reserved.