(Page 9 of 29 in this chapter) Version


Mtp3InitGenCfg

Description

Initializes the general configuration structure passed with default values and the originating point code provided.

Prototype

MTP3_STATUS Mtp3InitGenCfg (MTP3GenCfg *pGenCfg,
U32 opc)

pGenCfg Pointer to the MTP3GenCfg structure to be initialized.

opc Point code of the local signaling point.

Return Values

Details

This function is provided as a quick way for an application to initialize an MTP3GenCfg structure before calling Mtp3SetGenCfg to set the general configuration parameters. This function sets the opc as specified and initializes all other fields in the MTP3GenCfg structure to their defaults.

Refer to the following MTP3GenCfg structure for more information about its fields and their default values.

The following structures are used for general/global configuration of the MTP 3 task. Typically a pointer to an MTP3GenCfg structure is passed to Mtp3InitGenCfg where default values are set. If there is no default, either the field is unused or its value is passed as a parameter to Mtp3InitGenCfg. In the latter case the parameter name is specified. After initialization, an application may override zero to all of these values and then pass the pointer to the Mtp3SetGenCfg function, which actually sets the configuration.

Most of the default values provided by Mtp3InitGenCfg will be adequate for most applications.

typedef struct _Mtp3SetGenCfg
{
  U8              typeSP;              /* Type of signaling point      */
  U8              spare1;              /* Alignment                    */
  U32             spCode1;             /* Local Point Code for CCITT 
                                        * version                      */
  U32             spCode2;             /* Local Point Code for ANSI
                                        * version                      */
  Bool            ssfValid;            /* True if ssf validation 
                                        * required.                    */
  Bool            rstReq;              /* True if restarting procedure 
                                        * required.                    */
  U16             nmbLinks;            /* Max number of MTP Data Link
                                        * SAPs                         */
  U16             nmbNSap;             /* Max number of Network Layer 
                                        * Saps                         */
  U16             nmbLnkSets;          /* Max number of link sets      */
  U16             nmbRouts;            /* Max number of routing 
                                        * entries                      */
  U16             nmbRteInst;          /* Max number of concurrent Route
                                        * instances.                   */
  U8              nmbMasks;            /* Number of masks              */
  U8              spare2;              /* Alignment                    */
  U32             masks[MTP3MAXMASKS]; /* Route masks                  */
  S16             cbTimeRes;           /* Link timer resolution        */
  S16             icbTimeRes;          /* Route instance timer 
                                        * resolution                   */
  S16             spTimeRes;           /* Signaling point timer 
                                        * resolution                   */
  S16             rteTimeRes;          /* Route timer resolution       */
  MTP3GenTimerCfg tmr;                 /* General timers configuration.*/
  PDesc           stkmgr;              /* Stack manager (unused)       */
} MTP3SetGenCfg;

Note: The spCode1 and spCode2 fields in the MTP3SetGenCfg structure store the local point code. spCode1 is used by MTP 3 if the link type is CCITT or a variant thereof. spCode2 is used by MTP 3 if the link type is ANSI or a variant thereof. Both fields are set to the same value (the opc parameter) by the Mtp3InitGenCfg function. If a signaling point is acting as a gateway between CCITT and ANSI networks, or otherwise uses both types of point codes (14 and 24 bit), the application may override the defaults and specify different values for spCode1 and spCode2.
Fields that do not appear in the following table are either unused or for internal use only. Those fields should not be modified by the user. Field names in bold indicate that the field is updatable on subsequent calls to Mtp3SetGenCfg.
Field Name

Default

Valid Values

Description

typeSp

STP

One of:

MTP3TYPE_SP
MTP3TYPE_STP

Signaling point type. With or without transfer functionality.

spCode1

None

0-0xFFFFFF

Local point code for CCITT version. Must be specified via opc parameter.

spCode2

None

0-0xFFFFFF

Local point code for ANSI or CHINA version. Must be specified via opc parameter.

rstReq

True

True/False

If true, restart procedures are implemented as per the ANSI or ITU-T specification.

nmbLinks

4

1 - 16

Maximum number of data links configurable.

nmbNSap

2

1 - 64

Maximum number of network SAPs configurable

nmbLnkSets

1

1 - 16

Maximum number of link sets configurable

nmbRouts

32

1 - 32767

Maximum number of routes configurable

nmbRteInst

64

1 - 32767

Maximum number of simultaneous route instances.

nmbMasks

0

0 - 8

Number of route masks

masks

Entire structure zeroed

N/A

Route masks

tmr

See the following structure

See the following structure

General timers configuration. Refer to the MTP3GenTimerCfg structure.

typedef struct _Mtp3GenTimerCfg
{
  TimerCfg  t15;  /* Waiting to start route set congestion test        */
  TimerCfg  t16;  /* Waiting for route set congestion status update    */
  TimerCfg  t18;  /* Waiting for links to become available             */
  TimerCfg  t19;  /* Waiting to receive all traffic restart allowed    */
  TimerCfg  t20;  /* Waiting to broadcast traffic restart allowed      */
  TimerCfg  t21;  /* Waiting to restart traffic routed through adjacent 
                   * SP                                                */
  TimerCfg  t26;  /* Waiting to repeat traf restart waiting msg for 
                   * ANSI                                              */
  TimerCfg  t29;  /* Started when TRA sent for unexpected TRA or TRW   */
  TimerCfg  t30;  /* Route instance timer                              */
} MTP3GenTimerCfg;

Fields that do not appear in the following table are either unused or for internal use only. Those fields should not be modified by the user. Field names in bold indicate that the field can be updated on subsequent calls to Mtp3SetGenCfg. Unless otherwise specified, the timer names correspond to the CCITT specification. Differences from the ANSI and/or CCITT specification are noted in parentheses in the description.
Field Name

Default
(in tenth/secs)

Range

Description

t15

30

1 - 65535

Waiting to start route set congestion test

t16

20

1 - 65535

Waiting for route set congestion status update

t18

20

1 - 65535

Timer at restarting SP, waiting for links to become available (ANSI timer T22)

t19

50

1 - 65535

Timer at restarting SP, waiting to receive all traffic restart allowed (ANSI timer T23)

t20

40

1 - 65535

Timer at restarting SP, waiting to broadcast traffic restart allowed (ANSI timer T24)

t21

50

1 - 65535

Waiting to restart traffic routed through adjacent SP (ANSI timer T25)

t26

140

1 - 65535

Timer at restarting SP, waiting to repeat traffic restart waiting message (ANSI timer T26, CCITT timer N/A)

t29

600

1 - 65535

Timer started when TRA sent in response to unexpected TRA or TRW (ANSI timer T29, CCITT timer N/A)

t30

300

1 - 65535

Route instance timer (internally used, N/A to ANSI or CCITT specs)

See Also

Mtp3MgmtInit, Mtp3SetGenCfg



(Page 9 of 29 in this chapter) Version


tech_support@nmss.com
Copyright © 2000, Natural MicroSystems, Inc. All rights reserved.