MakeCall

Purpose

Use MakeCall to make an outbound call.


A screen capture of the Action MakeCall window

Description

Use MakeCall to make an outbound call. MakeCall checks there is a free channel (it does not assume that a channel is already active, as Dial does) and then causes a SIP INVITE message to be sent. Prior to using this state table action the AssignData action must be used to set a value for "TO_HDR" in SV541 as shown in this example:

AssignData(SV541, "PUT_TAG", "TO_HDR", "1234@bluesystem.blueworx.com");

Specifying channels and channel groups

System Variable 178 (System : Call : Permitted channel groups) allows you to specify the channel groups from which MakeCall can select an available channel. Use AssignData to specify the permitted channel groups (for example, SV178 = 1,2,3). When this variable contains its initialized value of NULL, MakeCall uses any available channel in any channel group for outgoing calls. SV178 is supported for both channel associated signaling and common channel signaling.

System variable 228 (System : Call : Permitted channels) allows you to specify the channels that MakeCall can use. Use AssignData to specify the logical channel numbers (1 to 360) of the permitted channels. (As an example, specifying SV228 = 5,119,317 would allocate trunk 1 channel 5, trunk 4 channel 29, and trunk 11 channel 17). When this variable contains its initialized value of NULL, SV178 (System : Call : Permitted channel groups) controls which channels can be used. When SV228 is set to anything else, it overrides SV178. SV228 is supported for both channel associated signaling and common channel signaling.

System Variable 177 (System : Call : Current channel group) identifies the channel group of the channel most recently used by this application. The variable is initialized to a value of 0 when the channel is disconnected.

Transferring information between a state table and SIP

Information is passed between a state table and SIP using system variables 541 (System : Call Info : Info out ) and 542 (System : Call Info : Info in). SV541 is read when the MakeCall state table action is entered. When the action returns SV541 is reset and SV542 is set with the response information from SIP.

AssignData should be used to set the string contained in variable SV541. AssignData can also be used to reset SV541 by writing a blank string to it. See AssignData. for more information about the operations that can be performed.

Information relating to a far-end hangup or disconnect, such as cause and diagnostics, can also be communicated by the signaling process to the application using system variable 543 (System : Call Info : Disconnect info). A far-end hangup can be detected from the state table if one of the call actions fails (for example, with an edge of outbound line problem)and SV543 is set at that point. SV543 is only set a maximum of once per call, and is reset at the start of each new call.

The information passed between the state table and SIP is a tag string"a sequence of tag identifiers (labels), each of which has an associated value and list of attributes. These attributes also have associated values.

A list of supported tags (and associated attributes) are shown below. For detailed information about their structure and usage, see the following:

Background music

MakeCall causes an automatic fade out of any background music. You can override this by using the system variable System : Music : Automatic fade before actions (SV226).

Format

When MakeCall is invoked, the parameter values define both the digit string that contains all the numbers MakeCall sends and a format for the digit string. The format defines where MakeCall should pause as it sends the digits specified in the digit string.

MakeCall recognizes three format characters:

#, which means “This is a digit.”

, (comma), which means “Wait the number of seconds specified by the Pause parameter.” For more information about the Pause parameter, see Parameters.

. (period), which means “Wait the number of seconds specified by the Pause parameter to receive a dial tone. Proceed sending the digit string as soon as the dial tone is received. If the dial tone is not received before the specified time elapses, terminate the MakeCall action with the result Outbound Line Problem.” For more information about the Pause parameter, see Parameters.

If the Dial Tone Detection system parameter is set to no dial tone, the period has the same effect as a comma.

For example, the format of a digit string that dials 9 to get a trunk, followed by a seven-digit telephone number, could be either #,####### or #.#######, depending on whether you want Blueworx Voice Response to proceed immediately after pausing, or proceed only when a dial tone is received. When the action pauses, it waits for the system default time (2 seconds) unless you define a different wait time using the Pause parameter.

If the switch does not send a standard dial tone, use a comma rather than a period to format the digit string. This will ensure that the digits are sent after the time specified by the Pause parameter, regardless of the tone received.

Usage notes

The MakeCall action works in four distinct steps:

  1. It selects an idle channel on which to make the call
  2. It goes off-hook and dials the number string
  3. It waits for a ring tone.
  4. It waits for the phone to be answered

If no free channels are available in the selected channel groups, the action terminates with a No Lines Available result. If glare occurs (an incoming call arrives at the same time) on the channel when Blueworx Voice Response goes off-hook, MakeCall selects another channel repeatedly until it can go off-hook successfully. While dialing the number, a period (.) in the dial string causes the action to wait for a dial tone before proceeding. If the action does not receive a dial tone within the time specified in the Pause parameter, it terminates with an Outbound Line Problem result. If it receives a tone other than a dial tone, it terminates with an Unexpected Tone, Phone Busy or Network Busy result, depending on the tone received.

After the number has been dialed, MakeCall waits for a ring tone. Because some protocols do not provide ring tones, and because it is possible for the call to be answered before a ring tone is generated, the action can also detect that the call has been answered during this time. This means that, depending on the protocol, an answer is detected either by signaling or by voice energy. If a ring tone or an answer is not detected within the time specified in the Ring Wait parameter, the action terminates with an Outbound Line Problem result. If an answer is detected, the action terminates with a Succeeded result. If the action receives a tone other than a ring tone, the action terminates with an Unexpected Tone, Phone Busy, or Network Busy result, depending on the tone received.

In the final step, the action waits for up to the time specified in the Ring Time parameter for the call to be answered. This is detected by signaling for protocols that support answer detection or by voice energy for protocols that do not (loop start and ground start). If the call is not answered in the specified time, the action terminates with a No Answer result.

Parameters

The parameters for MakeCall identify the number and format of the digit string. They also include three timing parameters.

Phone Number
No longer used set to ""
Format
No longer used set to ""
Pause
No longer used set to 0
Ring Wait
No longer used set to 0
Ring Time
No longer used set to 0

Possible results

MakeCall can have one of the following results:

Succeeded
The switch has received the signal and made the call.
Invalid Phone Number
The phone number or format string specified in the action contained invalid characters, or the number of digits in the number did not match the number of # characters in the format string.
Cause Codes:
Unlocated (unassigned) number

Invalid number format

Invalid transit network selection

Number changed

Invalid number format

Phone Busy
The telephone number dialed was busy.
Cause Codes:
User Busy

Destination out of order

Incoming calls barred

Network Busy
The network was busy and the telephone number could not be dialed.
Cause Codes:
No route to specified transit network

Switching equipment or network congestion

Resources unavailable, unspecified

Bearer capability not presently available

No route to destination

No Answer
The telephone number dialed did not answer within the specified timeout.
Cause Codes:
No User Responding

No answer from user (user alerted)

Call rejected

Outbound Line Problem
There was a problem with the outbound line.
Cause Codes:
Network out of order

Temporary failure

Quality of service unavailable

Requested facility not subscribed

Service or option not available, unspecified

Service or option not implemented, unspecified

Recovery on timer expiry

Facility rejected

Bearer capability not authorized

Requested facility not implemented

Incompatible destination

Outgoing calls barred

Channel type not implemented

No Line Available
No outbound line was available to make the call.
Cause Codes:
No circuit or channel available
Channel Active
Activity on the channel prevented the action from making the call.
Cause Codes:
Channel unacceptable

Identified channel does not exist

Unexpected Tone
Unexpected call progress tone was detected. See the Blueworx Voice Response for AIX: Configuring the System information.
Note: When a MakeCall action is unsuccessful, use TerminateCall to return the channel to a non-active state before retrying the MakeCall.

ASCII syntax

When using an ASCII editor, code this action with these parameters in the following order:

  1. Number
  2. Format string
  3. Pause time
  4. Ring wait time
  5. Ring time

For example:

label: "Check Edges"
	AssignData(SV541, "PUT_TAG", "TO_HDR", "37241416@kroner.hursley.blueworx.com");
    MakeCall("", "", 0, 0, 0)
	  edge EDGE_MK_SUCCESSFUL:			successful
	  edge EDGE_MK_INVALID_PHONE_NO:	  invalid_phone_no
	  edge EDGE_MK_PHONE_BUSY: 		   phone_busy
	  edge EDGE_MK_NETWORK_BUSY:		   network_busy
	  edge EDGE_MK_NO_ANSWER:			   no_answer
	  edge EDGE_MK_OUTBOUND_LINE_PROBLEM: outbound_line_problem
	  edge EDGE_MK_NO_LINES_AVAILABLE:	  no_lines_available
	  edge EDGE_MK_ACTIVE_CHANNEL: 	   active_channel
	  edge EDGE_MK_UNEXPECTED_TONE:	   unexpected_tone
	;

The parameters and edges are described above under "Parameters" and "Possible results". For more information, see Testing a state table using the debugger.