Showing posts with label conversion. Show all posts
Showing posts with label conversion. Show all posts

Components of a SIP Network

As I mentioned previously, devices on a SIP network are called User Agents. A User Agent Client and a User Agent Server are both required for communication.

SIP defines three server elements: a Registrar, a Proxy Server, or a Redirect Server. A Registrar server accepts REGISTER requests and is typically co-located with a proxy server or a redirect server. It can offer location services, and registers SIP parties in a SIP domain. A Proxy Server functions as both a server and a client that makes and receives requests on behalf of other SIP clients. It supports requests locally or forwards them to other servers. It can interpret and re-write a SIP request message before forwarding it to another server or User Agent. A Redirect server will accept SIP requests, read the information and map the address in the request to the next hop. It will then return an appropriate message to the client. The client can then directly contact the appropriate next hop. It does not forward SIP requests to other servers and it does not accept calls. A SIP Redirect Server will only respond with 3xx series responses. It is important to note that these three types of SIP servers are logically, and not physically distinct.

In addition to the three server types and the User Agents that are present in a SIP Network, there are also Session Border Controllers (SBC) and gateways on the network. A Session Border Controller is inserted into the signaling path and handles the signaling and media being sent across the network. The SBC can also perform anti-tromboning functions. Tromboning occurs when two devices on the same subnet are both trying to connect through a third server when they should be allowed to connect directly. By directing the two devices to speak directly to each other the trunks can be opened up for use by other devices. An SBC can also implement transcoding when required, but this is not recommended, as was discussed previously. An SBC can restrict call flow or allow connections to exist where they would not have otherwise been able to exist (due to a firewall between the two end-points, or other security policies). It is also interesting to note that the Session Border Controller can enforce interception of network sessions. This is interesting because, without the SBC, there would be no way to intercept the flow of data between two SIP devices as can be required by various law enforcement agencies. This is because under normal circumstances SIP will try to have end-points communicate directly with each other. A Gateway simply acts as a connecting point between a SIP network and a dissimilar network, such as H.323 or PSTN. Any calls that are being sent out to the PSTN will have to go through a gateway.

Analog to Digital Conversion

When communications occur across VoIP the speech from one end is converted to a binary format and is transmitted across a data network to the receiving end. At the receiving end it is converted back to an analog voice signal. A signal may be converted multiple times, depending on the path it takes. The basic process of this conversion is as follows:
First, the audio signal is filtered to 300-3600 Hz, as most human communication takes place in this range. The filtered signal is then sampled at a rate of 8,000 Hz (8000 samples/second), to fit with the Nyquist-Shannon Sampling Theorem. This results in a Pulse Amplitude Modulation (PAM) signal. The PAM signal is then converted into a Pulse Code Modulation (PCM) signal, which is a digital signal. Since we only have a limited amount of space in the PCM signal (it is only 8 bits!) we must find a method of mapping the analog signal to this 8-bit PCM signal. There are two methods used to do this: μlaw and alaw. μlaw is used in North America and Japan, while alaw is used in the rest of the world. These standards assign more bits to represent the lower frequencies where most communication occurs, and fewer bits for the higher frequencies, which contain less communication. These PCM samples are then packaged into packets and shipped across the network.

There are two main components that perform this voice sampling and compression: Digital Signal Processors (DSPs) and CODECs. A Digital Signal Processor is a specialized multiprocessor that performs complex operations on digital signals. A CODEC is an algorithm that converts analog signals into digital outputs. The digital output can be transmitted over a data network and then reconverted to an analog signal at the other end. A CODEC can compresss and convert voice to digital data to minimize bandwidth requirements. A CODEC can compress a standard 64 Kbps voice signal down to as low as 5.38 Kbps. I will go into further detail on CODECs in our next section.