Could you tell me a technology that allows you to make calls through a computer with a GSM modem connected to it?
1 answer
Not long ago dealt with this issue. It was necessary to implement calls from the browser to cellular / landline phones and receive incoming calls. If you need the same thing, then below is a plan of action.
The first thing you need is a server . It will accept VoIP traffic and process it, pass on. I used asterisk 13.08 as a server, although I can try freeswitch .
In order for your gsm модем to communicate with asterisk-ом you need to connect and configure the module to work with the modem (as well as configure the modem, because initially it does not work as it should)
If your goal is to call from any application thread from a computer ( X-lite , another soft background), then the work is completed. Customize dialplan , user and can call.
If you just need calls from the browser, go ahead
It is necessary to initially configure asterisk to work with a web-socket , it is not difficult, because in the latest versions of web-socket-ы in asterisk already there.
On the client side, we also need a library for calls (used this one )
Below is a more complete plan for setting up all this stuff, unfortunately I can’t attach configuration files, so I’ll have to find them myself
Put on Ubuntu Server 14+ версии
Download asterisk
wget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-12-current.tar.gz tar -zxvf asterisk-13-current.tar.gz Download dependencies
cd asterisk-13.xx/contrib/scripts/ ./install_prereq install Download libsrtp (v1.5.4)
git clone https://github.com/cisco/libsrtp.git git checkout v1.5.4 Install the libsrtp package
./configure CFLAGS=-fPIC make libsrtp.a make uninstall make install ldconfig Download pjproject
git clone https://github.com/asterisk/pjproject.git Install package
./configure --enable-shared --with-external-speex --with-external-gsm --with-external-srtp --disable-sound --disable-resample make make install ldconfig Install asterisk
cd asterisk-13.xx ./configure make menuselect in the menu you need to check whether there are asterisks
Channel Drivers -> chan_pjsip и chan_sip Resource Modules -> res_srtp, res_crypto и res_http_websocket make make install make samples Generate certificates
mkdir /etc/asterisk/keys cd /usr/src/asterisk-12.5.0/contrib/scripts/ ./ast_tls_cert -C domain -O "ATC Design" -d /etc/asterisk/keys Still need ssl certificate
Configure the asterisk-a configuration file
Download dongle
wget https://github.com/oleg-krv/asterisk-chan-dongle/archive/asterisk13.zip unzip asterisk13.zip Install module
В директории модуля: aclocal autoconf automake -a ./configure make make install After running make install : make sure that the module is copied to the asterisk modules directorychan_dongle.so .
The default asterisk module directory is here: /usr/lib/asterisk/modules . If there is no chan_dongle.so file, locate it in the source folder of chan_dongle and copy it manually to asterisk modules.
Make sure that the dongle.conf file is copied to the asterisk configuration directory. By default, the asterisk configuration directory is here: /etc/asterisk . If this file is not there, copy it from the chan_dongle source chan_dongle (subfolder etc) manually.
Something like that)
- You are my savior !!!)))) - nita
- Also in this scheme did the service. Tell me, why do you use SIP and PJSIP at the same time? They do not conflict with you? - carapuz
- @carapuz habrahabr.ru/post/236291/#comment_7952643 My answer is a hodgepodge of articles from Habré and from other sites + some of its own rakes. I decided not to take risks, since everything worked without errors - ThisMan