SCOPTEL IP PBX Software - PSTN Interfaces and Gateways

PDF Version

Gateways

A VoIP gateway is as a bridge between:

  • Interfaces: (T1/E1, FXO, FXS)

  • Protocols: SIP, Cisco SCCP/Skinny, MGCP (legacy protocol), and H.323 (legacy protocol)

  • CODECS (media): GSM (13 Kbps), iLBC (15 Kbps), G.711 (64 Kbps), G.722 (48/56/64 Kbps), G726 (16/24/32/40 Kbps), G.728 (16 Kbps) and G.729 (8 Kbps)

What are FXS and FXO?

../_images/Module5ScopTELPSTNInterfacesandGateways1.gif ../_images/Module5ScopTELPSTNInterfacesandGateways2.gif

FXS (Foreign Exchange Station)

FXS is an interface which drives a telephone. FXS interfaces get phones plugged into them, deliver battery, and provide ringing. The FXS interface initiates and sends a ringing voltage to the FXO interface.

FXO (Foreign Exchange Office)

FXO is an interface that connect to a phone line. They supply your PBX with access to the public telephone network. FXS interfaces are what allow you to hook telephones to your PBX, and FXO interfaces allow you to connect your PBX to real analog phone lines. FXO interfaces receives the ringing voltage from the FXS interface.

The phone receiving the call is the last FXO device in the chain, and when it receives voltage from an FXS device, the phone will ring.

Setup

To receive voltage from outside lines, connect the outside line to an FXO port on your server or gateway. Then connect the phones to FXS ports on your server or gateway. When the FXO port receives the voltage, it will then generate voltage using the FXS port and send it to your analog phone.

FXO interfaces

  • Also known as POTS line (Plain Old Telephone Service)

  • Also known as 1fl (1 family line)

  • Each FXO line can support one conversation between two parties (Tx and Rx Transmit and Receive)

  • Most business use ‘equivalent lines’ placed into an equivalent group ordered from the phone company AKA Telco.

  • Sometimes these equivalent groups are referred to as:

    • Rotary group

    • Hunt group

  • The first line or ‘pilot’ in the equivalent group is usually referred to as the BTN (Billing Telephone Number)

  • Usually an inbound Caller ID service is ordered separately for each 1fl at an additional cost

  • If additional lines are added to the pilot in a group then they are programmed by the Telco in a forward on busy configuration.

    Example:

    • 555-1234 (BTN) forward busy to

    • 555-2234 forward busy to

    • 555-3234 forward busy to

    • 555-4234 Busy (since this is the last number in this 4 FXO equivalency group)

  • Usually an inbound Caller ID service is ordered separately for each 1fl at an additional cost

  • Variants of FXO interfaces include:

    • Loop Start (SCOPTEL)

    • Kewl Start (SCOPTEL’s preferred FXO interface when using DAHDI hardware)

    • Ground Start (Legacy PBX’s)

Disconnect Supervision

Disconnect supervision is a term in telephony describing signaling between the telephone exchange and a connected party used to indicate that the connected call is being disconnected. Without this Telco option FXO ports can get hung indefinitely on the PBX. It only applies to Loop Start and Kewl Start circuits (not Ground Start).

CPC (Calling Party Control)

Is a signal sent from most modern electronic COs to indicate that the “Calling Party” has hung up. North American Central Office Switches use the OSI (Open Switch Interval) to signal the PBX’s FXO port that the Calling Party has hung up.

The OSI is a break in loop voltage (0VDC), typically for 800ms. If the PBX’s FXO port can support the Open Switch Interval it will free up the FXO port.

Supervisory Disconnect Tone

Some Telco’s send a Supervisory Disconnect Tone when the Calling Party hangs up. If the PBX’s FXO port can support the Supervisory Disconnect Tone it will free up the FXO port.

Battery Reversal

Instead of an open loop for 800ms, the DC talk battery gets reversed for 500ms.

Battery Reversal is still used in some countries however no FCC registered telephone equipment would recognize a battery reversal, since the FCC requires that telephones operate correctly on either polarity. Therefore Battery Reversal would simply be ignored.

Basic Test

If you have a Butt-set with a polarity light that’s on all of the time while you’re talking or you can hold the polarity test button while listening, you can watch the polarity LED. Make a call to your cell phone, hang-up the cell phone, and watch the polarity LED on your Butt-set. When there’s an open loop, there’s no voltage, and there’s no electricity to light the LED. You can also listen for the Supervisory Disconnect Tone on your Butt-set when the Calling Party hangs up.

ISDN Interfaces

ISDN interfaces are digital TDM (Time Division Multiplexing) trunks that support multiple voice channels (also known as Bearer channels) over a single circuit. There are two common types of ISDN interfaces; BRI and PRI.

Bearer Channel (Media)

The bearer capability for BRI and PRI is voice/speech at 3.1 kHz audio voice channel of 8 bits sampled at 8 kHz with G.711 encoding, and data at unrestricted 64 kbps, restricted 64 kbps, 56 kbps.

Each one of these channels is known as a DS0

Data Channel (Signaling)

The signaling channel (D) uses Q.931 for signaling with the other side of the link.

Q.931

Q.931 is used to transmit and receive call signaling messages according to the H.225 protocol for digital telephone services. The messages in Q.931 include setup (a signal indicating the establishment of a connection), call-proceeding (a signal indicating that the call is being processed by the destination terminal), ring-alert (a signal that tells the calling party that the destination set is ringing), connect (a signal sent back to the source indicating that the intended destination phone set has received the call), and release/complete (a signal sent by either the source or the destination indicating that the call is to be terminated).

Basic Rate Interface

The entry level interface to ISDN is the Basic(s) Rate Interface (BRI), a 128 kbps service delivered over a pair of standard telephone copper wires. The 144 kbps payload rate is broken down into two 64 kbps Bearer channels (‘B’ channels) and one 16 kbps signaling channel (‘D’ channel or delta channel). This is sometimes referred to as 2B+D.

The interface specifies the following network interfaces:

  • The U interface is a two-wire interface between the exchange and a network terminating unit, which is usually the demarcation point in non-North American networks.

  • The T interface is a serial interface between a computing device and a terminal adapter, which is the digital equivalent of a modem.

  • The S interface is a four-wire bus that ISDN consumer devices plug into; the S & T reference points are commonly implemented as a single interface labeled ‘S/T’ on an Network termination 1 (NT1).

  • The R interface defines the point between a non-ISDN device and a terminal adapter (TA) which provides translation to and from such a device.

  • BRI-ISDN is very popular in Europe but is much less common in North America. It is also common in Japan - where it is known as INS64.

  • SCOPTEL supports many SIP to BRI gateways (Mediatrix, Patton, Audiocodes, Quintum, Vegastream)

  • SCOPTEL only supports Woomera and Wanpipe (Sangoma) BRI PSTN interfaces (using the Card Detection Wizard).

Primary Rate Interface

The other ISDN access available is the Primary Rate Interface (PRI), which is carried over an E1 (2048 kbps) in most parts of the world. An E1 is 30 ‘B’ channels of 64 kbps, one ‘D’ channel of 64 kbps and a timing and alarm channel of 64 kbps.

In North America PRI service is delivered on one or more T1 carriers (often referred to as 23B+D) of 1544 kbps (24 channels). A PRI has 23 ‘B’ channels and 1 ‘D’ channel for signaling (Japan uses a circuit called a J1, which is similar to a T1).

Inter-changeably but incorrectly, a PRI is referred to as T1 because it uses the T1 carrier format. A true T1 (commonly called “Analog T1” to avoid confusion) uses 24 channels of 64 kbps of in-band signaling. Each channel reserves 56 kb for data or voice and 8 kbps for signaling and messaging. Analog T1 circuits do not support CLID.

PRI uses out of band signaling which provides the 23 B channels with clear 64 kb for voice and data and one 64 kb ‘D’ channel for signaling and messaging. PRI Circuits supply CLID before the user’s phone starts ringing.

In North America, NFAS (Non-Facility Associated Signaling) allows two or more PRIs to be controlled by a single D channel, and is sometimes called “23B+D + n*24B”. D-channel backup allows for a second D channel in case the primary fails.

On a single span Channel 24 is normally reserved for the D Channel on North American T1 PRI circuits.

On a single span Channel 16 is normally reserved for the D Channel on E1 PRI Circuits.

PRI Circuits use DNIS to route calls to the CPE (Customer Provided Equipment) and most PRI circuits have many DNIS numbers associated with the circuit number (usually sold in blocks of 10 or 30).

DNIS (Dialed Number Information Service)

DNIS is the routing number the PRI CPE (Customer Provided Equipment) circuit receives from the carrier (also known as Received Digits)

The received digits length (also known as Digits to Out Pulse by some Telco’s) can vary in length typically from 3 to 10 digits in length.

DNIS digits, as received from the carrier, are used to route calls via Incoming Lines objects in the SCOPTEL IP PBX

Example 1

  • The customer’s BTN is 555-555-1234

  • The Received Digit length set by the Telco is 4

  • The resulting DNIS or received digits is equal to 1234

Toll Free Services

  • The customer has a published toll free number 1-800-555-2234

  • Toll free numbers must be associated with a local phone number which is referred to as the conversion number

  • The conversion number can be any DNIS number associated with the PRI circuit

  • In this example the conversion number for 1-800-555-2234 is the BTN number 555-555-1234

  • Therefore the DNIS number for 1-800-555-2234 is 1234

ISDN Interfaces - Clocking

Systems with digital interfaces need to synchronize to the network in order to function. Synchronization is performed in a hierarchical way, where each device/switch obtains the network clock from the device/or switch above it in the synchronization hierarchy and passes the network clock to the device/switch below it in the synchronization hierarchy. The synchronization levels are referred to as strata. Sangomaand DigiumISDN interfaces both include an internal CSU/DSU.

  • Clock Mode (Wanpipe) Master Clock: The interface does not obtain timing from the network, but transmits the systems timing to equipment connected to it. Always use this mode when setting the interface to PRI (Network side) signaling.

  • Primary reference: The interface obtains the timing reference from the network, to which the system synchronizes (usually the Telco).

  • Secondary reference (Secondary): The interface acts as a standby reference. If there are excessive errors on the primary reference T1 link, or the interface designated as primary reference fails, this interface will obtain the timing reference from the network, which the system synchronizes to.

  • Thirdary: The interface acts as a standby reference. If there are excessive errors on the secondary reference T1 link, or the interface designated as secondary reference fails, this interface will obtain the timing reference from the network, which the system synchronizes to.

  • Quaternary: The interface acts as a standby reference. If there are excessive errors on the thirdaryreference T1 link, or the interface designated as thirdaryreference fails, this interface will obtain the timing reference from the network, which the system synchronizes to.

SIP Overview

  • SIP (Session Initiation Protocol) is a light weight ASCII protocol which is well suited for voice (VoIP), video (H.264 CODEC), presence (XMPP), and text chat services.

  • It borrows from other technologies like email and DNS

  • The default SIP UDP/TCP signallingport is 5060 in format it looks like sip:user@domain.com:5060.

  • The default SIP TCP-TLS signallingport is 5061 in format it looks like sip:user@domain.com:5061.•The SCOPTELdefault RTP port range for SIP is 10000-20000.

  • SCOPTELintegrates a SIP UA, UAS, B2BUA, Registrar, and SBC.

  • SIP user agent (UA): is a logical network end-point used to create or receive SIP messages and thereby manage a SIP session. A SIP UA can perform the role of a UAC (User Agent Client ), which sends SIP requests to the UAS (User Agent Server).

  • Registrar: A server that authenticates REGISTER requests and places the information it receives in those requests into the location service for the domain it handles.

  • B2BUA: In the originating call leg the B2BUA acts as a user agent server(UAS) and processes the request as a user agent client(UAC) to the destination end, handling the signaling between end points back-to-back. A B2BUA maintains complete state for the calls it handles.

  • Session Border Controller: is a device regularly deployed in Voice over Internet Protocol (VoIP) networks to exert control over the signallingand usually also the media streams involved in setting up, conducting, and tearing down telephone calls or other interactive media communications. It can control multiple elements including:

    • NAT Traversal

    • SIP normalization via SIP message and header manipulation

    • Malicious attacks such as a DoS(Denial-of-Service attack) or distributed DoS

    • Topology hiding

    • Encryption of signaling (via TLS ) and media (SRTP).

  • SCOPTEL supports SIP end points (phones) and trunks without the need for optional licenses.

  • SIP is native to SCOPTEL.

T.38 Fax (UDPTL) Passthrough

Due to packet loss, latency, echo cancellation, compressed CODECS, and jitter buffers faxing is not reliable over IP networks. For example a fax is not supported over IP using any compressed CODEC such as G.729. Faxes are not supported if echo cancellation is used. Therefore some drivers or gateways will disable echo cancellation during fax negotiation.

UDPTL (T.38) refers to an Internet Facsimile Protocol used for carrying fax data over IP networks.

  • T.38 must be supported endpoint to endpoint.

  • The UDPTL (T.38) tab allows you to specify various parameters, which are as follows:

  • Start Port: Allows you to specify the starting port of the UDPTL (T.38) channel. By default, its value is 4000.

  • End Port: Allows you to specify an appropriate end port of the UDPTL (T.38) channel. By default, its value is 4999.

  • Enable UDP checksums on UDPTL traffic: Allows you to enable UDP checksums on UDPTL traffic for any error

Error Correction Type: Allows you to specify the error correction scheme to be used. You can

  • Select an appropriate scheme to use, from the two available schemes. By default, its value is t38 UDP FEC.

  • Maximum packet length: Allows you to specify the maximum packet length in the UDPTL (T.38) channel. By default, its value is 400.

  • Number of Error Correction Entries per packet: Allows you to specify the number of error correction entries per packet. By default, its value is 3.•Error Correction Span: Allows you to specify an appropriate error correction span. The span over which parity is calculated for FEC in a UDPTL packet.

Interfaces Card Detect

  • If any analog FXO/FXS or T1/E1 or BRI cards are installed then you must do a “Card Detect” to recognize and configure that hardware before the drivers and configurations can be properly loaded. Configuration > Telephony > Interfaces > Detect Cards

  • Follow the pop-up windows to complete the card detection procedure and be certain to read and follow any instructions that will appear in those pop-up windows. After your PSTN hardware is detected and the required services are running it will be necessary to configure regional properties and gain settings for each of your PSTN cards and ports. If a change is made to any settings on the “Interfaces” tabs it is a good practice to “Commit” those changes and then restart the following services in the correct order. First navigate to the “General” tab…

  • The correct order to reset services is :
    • Stop the “Telephony Server”

    • Restart the “Analog/Digital Modules ( Zaptel / Wanpipe )

    • Start the “Telephony Server”

../_images/Module5ScopTELPSTNInterfacesandGateways3.png

VoIP Accounts

Add a new VoIP Account

  • A typical VoIP Interface would normally use the industry standard SIP technology. Therefore this example will cover the creation of a CPE side (Customer Provided Equipment) SIP account.

  • SIP trunks normally require a SIP Registrar for client authentication and a SIP Proxy to handle signaling and media. It is common for the SIP Registrar and SIP Proxy to be the same server but the SIP Registrar and SIP Proxy can reside on different servers.<

  • To create a new SIP Interface navigate to Configuration > Telephony > Configuration > Interfaces > VoIP Accounts and Click “Add a New VoIP Account” and choose SIP from the drop down list.

../_images/Module5ScopTELPSTNInterfacesandGateways4.png

General

  • The name field is mandatory and it is typical for the name of the SIP trunk to equal the SIP username provided by the SIP ITSP (Internet Telephony Service Provider). A SIP Friend allows both Incoming and Outgoing Calls and is most typical.

  • In this example the name of our SIP trunk is 5555551212. When the General properties are entered click on the Server tab next to add the authentication properties and the address of the SIP Registrar and Proxy.

../_images/Module5ScopTELPSTNInterfacesandGateways5.png

Server

  • Use the Plaintext option to enter username and password into the matching fields (MD5 will be used to encrypt the authentication during transit).

  • Host Mode Specific is chosen when the server is authenticating to a Dynamic Account like an ITSP in Client Mode.
    • Enter either the FQDN or IP address of the remote Dynamic Account

  • Dynamic Mode is chosen when the remote VoIP Account is authenticating to this VoIP Interface.

  • In this example we authenticating to a remote account therefore we must choose Host Mode Specific. Registration is required to check the box for Register as User Agent

  • When finished click on the Network tab

../_images/Module5ScopTELPSTNInterfacesandGateways6.png

Network

  • If the server is situated behind a third party NAT Router/Firewall then check off the box for Trunk Behind NAT.

  • If the server is situated behind a third party NAT Router/Firewall then the third party Firewall rules must port forward the following rules to the LAN IP address of the SCOPTEL server. 5060 / udp 10000 - 20000 / udp.

  • Also a static public IP address and/or FQDN (Fully Qualified Domain Name) is recommended for the SCOPTEL server to help negotiate Firewall related RTP issues. This IP address or FQDN is entered into the text field located at Configuration > Telephony > General > External IP or Hostname and the “Server behind NAT ?[ ]” option be checked [x ].

  • It is common for most SIP ITSP’s to require the Insecure options Port, Invite to be checked. The SIP Qualify Time is defined in seconds (default 300 seconds). The server will send a SIP qualify message to the ITSP every 300 seconds. This allows the ITSP to monitor the status of the SIP registration and latency. When finished here click on the Options tab.

../_images/Module5ScopTELPSTNInterfacesandGateways7.png

Options

  • The correct DTMF mode must be selected to match with the requirements of the ITSP. Typically “Automatic RFC-2833/inband” is selected. However most ITSP’s support RFC-2833 because it is more reliable.

  • The CODEC selection must match the requirements of the ITSP and any supported CODEC’s not checked off will never be negotiated with the ITSP because they have not been allowed. The global Channel options defined in`` Configuration > Telephony > Configuration > Channels > Codecs`` will choose the first supported CODEC in the preferred order.

  • Not all provider support P-Asserted Identity (PAI) but this setting is required for dynamic Caller ID updates such as Connected Party.

  • Remote Party ID (RPID) is supported by many ITSP’s to support Caller ID Name and Number but RPID is considered a Legacy Protocol.

  • No other options are required at this time so it is OK to click on the “Add” button.

../_images/Module5ScopTELPSTNInterfacesandGateways8.png

Interoperable Products