OpenVox Document Center OpenVox Document Center
  • Home 
  • Products 
  • Solutions 
  • Resources 
    • Document Center 
    • Datasheets 
    • Firmwares 
    • Videos 
  • Partners 
  • Blog 
  • Company 
OpenVox Document Center OpenVox Document Center
OpenVox Document Center
  • Home 
  • Products 
  • Solutions 
  • Resources 
    • Document Center 
    • Datasheets 
    • Firmwares 
    • Videos 
  • Partners 
  • Blog 
  • Company 

EOL-Product

  • folder icon closed folder iconUser Manual
    • iCallDroid User Manual
    • iCallDroid spot User Manual
    • IX120 User Manual
    • IX132 Series IP-PBX User Manual
    • SWG2008_User_Manual
    • SWG-1016C User Manual
    • WGW1002 User Manual
    • VS-GW1202-8G User Manual
    • VS-GW1600 User Manual
    • VS-GW2120 Series User Manual
    • 3G Gateways User Manual
    • A800E on DAHDI User Manual
    • A800P on DAHDI User Manual
    • A1200E on DAHDI User Manual
    • A1200P on DAHDI User Manual
    • D110P /D110E on DAHDI User Manual
    • D115P/DE115P on Elastix User Manual
    • DE115P/DE115E on DAHDI User Manual
    • G400P/G400E/G410P/G410E User Manual
    • iAG804/iAG808 User Manual
    • iAG840/iAG880 User Manual
  • folder icon closed folder iconDatasheet
    • VS-GW1600 GSM Series Datasheet
    • VS-GWM400 Datasheet
    • VS-GWM400W Datasheet
  • folder icon closed folder iconQuick Start Guide
    • Quickstart Guide of VS-GW1600-20G Connect with VOS3000 Operation Platform
    • Quickstart Guide of VS-GW1600-20G Connect with 3CX Server
    • Quickstart Guide of VS-GW1600-20G Connect with Asterisk Server
    • Quickstart Guide of VS-GW1600-20G Connect with Elastix Server
    • Quickstart Guide of VS-GW1600-20G Connect with FreeSWITCH Server
  • folder icon closed folder iconAPP Note
    • GSM Gateways APP Note
      • APP Note_AMI
      • Expand Callback Function
      • How to Bind the GSM Gateway Ports with PBX Sip Extension
      • How to Integrate the Analog Gateway and the GSM Gateway in One OpenVox Box
      • OpenVox GSM Gateway Function User Manual
      • OpenVox GSM Gateway HTTP Interface
      • Openvox HTTP SMS API Demo
      • OpenVox Wireless Gateway Connect with playSMS Manual
      • Remote Server Get CDR from GSM Gateway by AMI
      • VoxStack GSM Gateway API 1.0.0
      • VoxStack GSM Gateway Connect with iCallDrid Manual
      • VoxStack GSM Module Upgrading Guide
  • folder icon closed folder iconFAQ
    • IPC100/110
loading
Popular Searches
  • VoIP
  • Gateway
  • IPPBX
  1. Home
  2. Docs
  3. EOL-Product
  4. APP Note
  5. GSM Gateways APP Note
  6. Expand Callback Function
Updated on March 17, 2022

EOL-Product

  • folder icon closed folder iconUser Manual
    • iCallDroid User Manual
    • iCallDroid spot User Manual
    • IX120 User Manual
    • IX132 Series IP-PBX User Manual
    • SWG2008_User_Manual
    • SWG-1016C User Manual
    • WGW1002 User Manual
    • VS-GW1202-8G User Manual
    • VS-GW1600 User Manual
    • VS-GW2120 Series User Manual
    • 3G Gateways User Manual
    • A800E on DAHDI User Manual
    • A800P on DAHDI User Manual
    • A1200E on DAHDI User Manual
    • A1200P on DAHDI User Manual
    • D110P /D110E on DAHDI User Manual
    • D115P/DE115P on Elastix User Manual
    • DE115P/DE115E on DAHDI User Manual
    • G400P/G400E/G410P/G410E User Manual
    • iAG804/iAG808 User Manual
    • iAG840/iAG880 User Manual
  • folder icon closed folder iconDatasheet
    • VS-GW1600 GSM Series Datasheet
    • VS-GWM400 Datasheet
    • VS-GWM400W Datasheet
  • folder icon closed folder iconQuick Start Guide
    • Quickstart Guide of VS-GW1600-20G Connect with VOS3000 Operation Platform
    • Quickstart Guide of VS-GW1600-20G Connect with 3CX Server
    • Quickstart Guide of VS-GW1600-20G Connect with Asterisk Server
    • Quickstart Guide of VS-GW1600-20G Connect with Elastix Server
    • Quickstart Guide of VS-GW1600-20G Connect with FreeSWITCH Server
  • folder icon closed folder iconAPP Note
    • GSM Gateways APP Note
      • APP Note_AMI
      • Expand Callback Function
      • How to Bind the GSM Gateway Ports with PBX Sip Extension
      • How to Integrate the Analog Gateway and the GSM Gateway in One OpenVox Box
      • OpenVox GSM Gateway Function User Manual
      • OpenVox GSM Gateway HTTP Interface
      • Openvox HTTP SMS API Demo
      • OpenVox Wireless Gateway Connect with playSMS Manual
      • Remote Server Get CDR from GSM Gateway by AMI
      • VoxStack GSM Gateway API 1.0.0
      • VoxStack GSM Gateway Connect with iCallDrid Manual
      • VoxStack GSM Module Upgrading Guide
  • folder icon closed folder iconFAQ
    • IPC100/110

Expand Callback Function

Estimated reading: 2 minutes 138 views

Both gsm and 3G gateway support to expand callback function, but you need config it in SSH way.

Please follow steps below:

Step 1:  define gsm channel entry:

[email protected]:~# cd /etc/asterisk/
[email protected]:~/memcfg/etc/asterisk# vi chan_extra.conf

#include extra-global.conf
;#include extra-channels.conf

#include extra-channels_custom.conf   //change default extra-channles to custom channels entry
[email protected]:~/memcfg/etc/asterisk# cp extra-channels.conf extra-channels_custom.conf
[email protected]:~/memcfg/etc/asterisk# vi extra-channels_custom.conf
group=1
;context=gsm-1     //default calls go to [gsm-1] context in extensions_routing.conf
context=gsm-custom-1     ////Now leading calls go to [gsm-custom-1] context in extensions_custom.conf
signalling = gsm
vol=70
mic=1
dacgain=-15
adcgain=-3
debugat=on
gsm_ec=off
anonymouscall=off
call_waiting=off
…….
…….

step 2: Modify asterisk.conf to change dirrectory of agi

[directories]

astetcdir => /etc/asterisk
astmoddir => /usr/lib/asterisk/modules
astvarlibdir => /usr/lib/asterisk
astagidir => /etc/asterisk/agi-bin
astspooldir => /tmp/media/spool/asterisk
astrundir => /var/run
astlogdir => /tmp/log/asterisk
astdatadir => /etc/asterisk

 

step 3: Creat your own Dialpan:

Such as: any incoming call from gsm-1.1 will be hangup, gsm gateway will automatically callback through gsm-1.1 and connect the caller with sip ext 1001.

[gsm-custom-1]
exten => s,1,Set(DESTINATION=${CALLERID(num)})
exten => s,n,Noop(===========incoming call=============)
exten => s,n,hangup()
exten => h,1,Noop(=======call back start=========)
exten => h,n,DeadAGI(callback.php,${DESTINATION},”1001″,gsm-callback.s.1,20)   ;1001 is  sip ext
exten => h,n,Hangup()

[gsm-callback]
exten => s,1,Noop(====${CALLERID(num)}====)
exten => s,n,Dial(EXTRA/1/${CALLERID(num)})      ;using port gsm-1.1 to callback
exten => s,n,Hangup()

Please upload files below to your gsm gateway. Put them in this directory:  /etc/asterisk/agi-bin

phpagi-asmanager.php

phpagi.php

callback.php

 

Notice: As all confiugration is stored in RAM, so you need to run a tool to write them into files, otherwise all configuration will be lost once reboot.
[email protected]:~/memcfg/etc/asterisk# /my_tools/sync2flash

Still stuck? How can we help?

Was this page helpful? Yes No

How can we help?

A premium WordPress theme with integrated Knowledge Base,
providing 24/7 community based support.

Leave a Comment Cancel reply

CONTENTS

Copyright © 2002-2022 OpenVox all rights reserved.