13 settembre 2007 - Come collegare Voice Blue Lite a un centralino Asterisk
The present document is a step-by-step guide for configuring the 2N VoiceBlue Lite GSM Gateway and Asterisk software IP PBX. It includes essential steps for interconnecting the two products rather than a detailed configuration analysis of the two units. For more information on the 2N VoiceBlue Lite GSM Gateway configuration refer to the manual (you can find it on www.2nitalia.it).
For more information on the Asterisk IP PBX see www.asterisk.org.
The 2N VoiceBlue Lite GSM Gateway is an ideal complementary product to any SIP-based IP PBX. It's suitable for small and medium companies with IP infrastructure and for companies with international affiliates. With 2N VoiceBlue Lite you gain significant savings on outgoing and incoming calls from IP to GSM networks and backwards. Thanks to the efficient and powerful Least Cost Router (LCR), the 2N VoiceBlue Lite GSM gateway always chooses the cheapest possible way to route the call (according to GSM prefixes, free minutes on SIM cards etc.).Using the 2N VoiceBlue Lite GSM Gateway you achieve complete independence when connecting to GSM networks and maintain 100% control of your GSM call costs. With the help of voice prompts and efficient Dynamic Clip Routing, 2N VoiceBlue Lite routes incoming GSM calls to the right IP phones.
Asterisk is a software PBX originally developed by Mark Spencer. This software PBX is designed as an open source, which means that it can be downloaded from the Internet, namely from: http://www.asterisk.org/index.php?menu=download, installed and used without any limitations. The fact that the Asterisk is a software PBX indicates that VoIP is the native environment for this PBX. Asterisk supports VoIP using three protocols, which means that its users can use a wide range of VoIP telephones, both software ones and hardphones.
Together with the above mentioned VoIP services, Asterisk supports connection of TDM equipment by means of PCI cards supporting both digital (ISDN PRI/BRI) and analog trunks. Since the PCI bus on the PC is not unlimited, Asterisk users employ as much VoIP equipment as possible in order to save the TDM interface for other services, such as PSTN connection, or use of analog telephones. This is why most Asterisk users use the 2N VoiceBlue Lite VoIP GSM Gateway for their GSM calls. You find below how to interconnect these two types of equipment.
For more information on the Asterisk software solution see www.asterisk.org.
Suppose we have an IP network to which an Asterisk IP PBX, several SIP telephones and an 2N VoiceBlue Lite VoIP-GSM gateway are connected. This typical configuration is shown in the figure below. Furthermore, suppose that the network is addressed as shown in the figure and GSM numbers are all numbers starting with 6,7,8 and containing 9 digits. For configuration simplicity, use SIM cards from one GSM provider.
Now say that all incoming calls are answered by the gateway, which replays the invitation message and waits for 10s for another DTMF dialing. After this timeout, the gateway dials extension 111, which is a dial-in to the operator.![]()
Step-by-step configuration...ready in 5 minutes:-)
Set information on the IP interface only ...address, mask, default gateway
![]()
![]()
Since SIM cards from one GSM provider are used, all you have to do is make sure that all GSM modules have been assigned to the first group.
![]()
Create a network list containing the prefix of your GSM destinations ...remember to keep the default number of digits (9 in our case).
![]()
Finally, sum up all settings in a single LCR table defining that all called numbers that match the network list 1 shall be routed via GSM group 1.
![]()
As far as incoming calls are concerned, the 2N VoiceBlue Lite GSM Gateway has a relatively wide choice of possibilities. Besides call ignoring and rejection, you can mainly receive incoming calls as follows:
The following configuration can be used as an example:
![]()
Now add a few lines in the IP PBX configuration for both proper routing of outgoing calls to the 2N VoiceBlue Lite GSM Gateway and receiving calls coming from the GSM gateway to Asterisk.
The core of Asterisk connection lies in the /etc/asterisk/extensions.conf file.
Open this file in your favourite editor and add the following lines:
exten => _6XXXXXXXX,1,Dial(SIP/${EXTEN:0}@10.0.0.20,,r)
exten => _7XXXXXXXX,1,Dial(SIP/${EXTEN:0}@10.0.0.20,,r)
exten => _8XXXXXXXX,1,Dial(SIP/${EXTEN:0}@10.0.0.20,,r)
Once you have saved and closed the file, restart Asterisk and from now on all calls starting with 6,7,8 should be routed to the 2N VoiceBlue Lite GSM Gateway.
It is recommended to make a little restriction for incoming calls to prevent unauthorised persons from calling over your system.
Since 2N VoiceBlue Lite works with the SIP, modify the /etc/asterisk/sip.conf file where the 2N VoiceBlue Lite section could look as follows, for example:
[voiceblue]
type=peer
insecure=very
disallow=all
allow=alaw
host=10.0.0.20
username=voiceblue
permit=10.0.0.20/255.255.255.255
qualify=yes
canreinvite=no
call-limit=4
Again, restart Asterisk after saving the file. After that, Asterisk will be ready to receive calls coming from the 2N VoiceBlue Lite GSM Gateway.
The first thing you should do when you find that there is something wrong is to run the trace in 2N VoiceBlue Lite... this helps you locate the problem. First of all you can see immediately whether any SIP messages come to the GSM gateway and if so, check the called numbers for proper format. If this is OK too, review the complete communication listing both on the VoIP and GSM sides.
To start tracing click on Tracing in the CTRL section. For recommended trace parameters see the figure below.![]()
If, despite all your effort, troubles persist, send an e-mail message to serviziotecnico@@2nitalia.it, where you will be served readily.