SIP to PSTN - SIP

How does SIP communicate with PSTN ?

We need a translator between SIP (softphone) and PSTN (old telephone) because both are different network and they speak different languages. This translator, called Gateway is used to communicate between both these networks.

Consider an example which shows a SIP phone placing a telephone call to a PSTN through a PSTN gateway.

In the below example, Tom is using sip:tom@wisdomjobs.com which is a sip phone (sip:tom@wisdomjobs.com) whereas Jerry is using +91401234567 which is a global telephone number.

How does SIP to PSTN communication happen through Gateways ?

Below diagram shows a call flow through gateways from SIP to PSTN.

SIP to PSTN

Following is an explanation of all the steps in the process that happens when a call is placed from a SIP phone to PSTN.

  • First, Tom uses his SIP phone to reach Jerry on his global number +91401234567. SIP user agent then converts it into request-uri since it understands it as a global number. It uses DNS for this conversion and then sends the request.
  • Tom’s SIP phone sends INVITE to the gateway directly.
  • Gateway then selects an SS7 ISUP trunk to the next telephone switch in the PSTN to initiate the call.
  • INVITE contains the dialled digits which are then mapped to the ISUP IAM. To signal that the trunk has been created, the PSTN then sends back ISUP Address Complete Message (ACM).
  • Before going to the telephone switch, the telephone generates the ringtone. ACM is mapped to 183 Session Progress response by the gateway. This response contains an SDP which indicates the RTP port which the gateway uses to bridge audio from the PSTN.
  • Caller’s UAC then receives the 183 and it beings receiving the RTP packets which are sent by the gateway. To let the callee know about the progress in the PSTN, audio is presented to the caller.
  • When the called party answers the telephone the call gets completed. Telephone switch then sends an Answer Message (known as ANM) to the gateway.
  • Then the gateway cuts the PSTN audio connection in both directions and then sends a 200 OK response back to the caller. The gateway replies the SDP in the 183 as the RTP media path is already established. But this does not cause any changes to the RTP connection.
  • To complete the SIP signalling exchange, UAC then sends an ACK. The gateway totally absorbs the ACK since there is no equivalent message in ISUP.
  • The caller then terminates the connection to the gateway by sending BYE. This makes causes the gateway to map the BYE into ISUP Release Message (REL).
  • Then the gateway sends 200OK and then receives RLC from the PSTN.

All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd DMCA.com Protection Status

SIP Topics