Sunday, January 22, 2012

Creating a C# Softphone

Introduction

Softphone is the short term for a software telephone and it is an extended model for the traditional telephone device. It works with VoIP technology and it is extended as it can be capable of both voice and video calling.

In this article I try to introduce a simple softphone application that can be used for voice calls. The new version of the Ozeki VoIP SIP SDK I use has just come out, so I had to modify my program in some aspects, therefore I had no time to write the video calling part yet. I will cover that topic in another article soon.
Basic Requirements for an Ozeki Softphone

A softphone application requires a PBX, as I mentioned in my previous article. The Ozeki SDK supports many PBX systems [1] and they also have guides to their configuration. I use a simple FreePBX [2] that is installed onto a virtual machine. This is an Asterisk based PBX system that seemed to be easy to use and reliable. I have actually installed it, registered two SIP accounts for testing and it works properly.

The SDK is simply installed on my computer. It unpacked its .dll file and some sample programs into the Program Files/Ozeki folder. There are a lot of license possibilities for it but I simply use the demo version that can be downloaded from their website [3]. It has some limitations but it is enough for test purposes.

The IDE I use is Visual Studio 2010 Express Edition that is free as I do not want to sell my programs, only use them for my improvement in VoIP solutions.
The Project Structure and GUI

The softphone application I wrote is a basic C# program with two classes and it only contains the basic functions of a softphone. The program has a minimal main GUI and a pop-up window that is for setting the PBX registration data.

First of all I created a Windows Forms project in Visual Studio and registered the Ozeki SDK to it as a Reference (Figure 1).

SDK-as-reference.jpg

Read more: C# Corner
QR: http://chart.googleapis.com/chart?chs=80x80&cht=qr&choe=UTF-8&chl=http://www.c-sharpcorner.com/UploadFile/37fed4/creating-a-C-Sharp-softphone/

Posted via email from Jasper-Net