diff --git a/asterisk/conf/mobile/extensions.conf b/asterisk/conf/mobile/extensions.conf index 7ce4d61..f5785d3 100644 --- a/asterisk/conf/mobile/extensions.conf +++ b/asterisk/conf/mobile/extensions.conf @@ -4,11 +4,11 @@ ; ; First, some safeguards against abuse of the built-in contexts. [default] -exten=>s,1,Verbose(1, "INFO ${CALLERID(num)} was passed to default.") -same=>n,Hangup(3) +exten => s,1,Verbose(1, "INFO ${CALLERID(num)} was passed to default.") +same => n,Hangup(3) [presence] -exten=>_X.,hint,PJSIP/${EXTEN} +exten => _X.,hint,PJSIP/${EXTEN} [from-ext] -exten=>123,1,Hangup(3) +exten => 123,1,Hangup(3) diff --git a/asterisk/conf/mobile/modules.conf b/asterisk/conf/mobile/modules.conf index ee663a6..3f5ddbb 100644 --- a/asterisk/conf/mobile/modules.conf +++ b/asterisk/conf/mobile/modules.conf @@ -4,7 +4,7 @@ ; This is the same as the sample but without text. ; [modules] -autoload=yes +autoload = yes noload = chan_alsa.so noload = res_hep.so diff --git a/asterisk/conf/mobile/pjsip.conf b/asterisk/conf/mobile/pjsip.conf index a000c93..02805e5 100644 --- a/asterisk/conf/mobile/pjsip.conf +++ b/asterisk/conf/mobile/pjsip.conf @@ -11,7 +11,7 @@ type = global endpoint_identifier_order = ip,username,anonymous ; Basic UDP Transport. -[ipv4-udp-nat] +[ipv4-udp] type = transport bind = 0.0.0.0:65534 protocol = udp @@ -19,8 +19,3 @@ local_net = 172.16.0.0/12 local_net = 192.168.0.0/16 local_net = 127.0.0.0/8 local_net = 10.0.0.0/8 - -; -; Load trunk identify block. -#tryinclude pjsip_identify_trunk_one.conf - diff --git a/asterisk/conf/mobile/pjsip_users.conf b/asterisk/conf/mobile/pjsip_users.conf index c3d7692..eb34d69 100644 --- a/asterisk/conf/mobile/pjsip_users.conf +++ b/asterisk/conf/mobile/pjsip_users.conf @@ -2,11 +2,35 @@ ; /etc/asterisk/pjsip_users.conf ; [1000](extension-defaults) +; Dialplan context name for calls originating from this account. +endpoint/context = from-ext -inbound_auth/username=1000 +; Voicemail address. +endpoint/mailboxes = 1000@default -inbound_auth/password=MapleCarrotBlueGrainFishSoapSoup +; Internal Caller ID string for this device. +endpoint/callerid = 1000 <1000> -endpoint/callerid=1000 +; Username for SIP account. By convention, this should be the extension number. +inbound_auth/username = 1000 -endpoint/context=from-ext +; Password for SIP account (you can choose whatever password you like). +inbound_auth/password = MapleCarrotBlueGrainFishSoapSoup + +; Maximum number of simultaneous logins for this account. +aor/max_contacts = 1 + +; Check connectivity every 30 seconds. +aor/qualify_frequency = 30 + +; Set connectivity check timeout to 3 seconds. +aor/qualify_timeout = 3.0 + +; IMPORTANT! This setting determines whether the audio stream will be proxied +; through the Asterisk server. +; +; If this device is directly reachable by the internet (either by a publicly +; routable IP, or static port mappings on your router), choose YES. +; +; Otherwise, if this device is hidden behind NAT, choose NO. +endpoint/direct_media = no diff --git a/asterisk/conf/mobile/pjsip_wizard.conf b/asterisk/conf/mobile/pjsip_wizard.conf index d66823a..1eb24bb 100644 --- a/asterisk/conf/mobile/pjsip_wizard.conf +++ b/asterisk/conf/mobile/pjsip_wizard.conf @@ -1,36 +1,60 @@ ; ; /etc/asterisk/pjsip_wizard.conf +; +[trunk-defaults](!) +type = wizard + +; Send media to the address and port on the incoming packet, regardless of what +; the SIP headers say (NAT workaround). +endpoint/rtp_symmetric = yes + +; Rewrite the SIP contact to the address and port of the request (NAT workaround). +endpoint/rewrite_contact = yes + +; Send the Remote-Party-ID SIP header. Some providers need this. +endpoint/send_rpid = yes + +; We use alaw mainly in Europe. +endpoint/allow = !all,alaw + +; Call encryption. +endpoint/media_encryption = no + +; Default language, pjsip wizard appears to ignore global setting. +endpoint/language = en_GB + ; [extension-defaults](!) -type=wizard +type = wizard ; Users must register and auth! -accepts_registrations=yes -accepts_auth=yes +accepts_registrations = yes + +accepts_auth = yes ; Check ext connectivity every x seconds. -aor/qualify_frequency=30 +aor/qualify_frequency = 30 ; How long do we wait for a response to our connection check? -aor/qualify_timeout=3.0 +aor/qualify_timeout = 3.0 ; Remove older sessions when logins exceed max_contacts. -aor/remove_existing=yes +aor/remove_existing = yes ; Max simultaneous account logins. -endpoint/max_contacts=1 +endpoint/max_contacts = 1 ; Audio codecs: alaw only please. endpoint/allow=!all,alaw ; Default language. -endpoint/language=en_GB +endpoint/language = en_GB ; By default don't allow direct media connections. -endpoint/direct_media=no +endpoint/direct_media = no ; Busy Lamp field / Presence context. -endpoint/subscribe_context=presence +endpoint/subscribe_context = presence ; ; Load user extensions. diff --git a/asterisk/conf/mobile/quectel.conf b/asterisk/conf/mobile/quectel.conf index 069d5c0..6e7b686 100644 --- a/asterisk/conf/mobile/quectel.conf +++ b/asterisk/conf/mobile/quectel.conf @@ -1,8 +1,8 @@ [general] -interval=30 ; Number of seconds between trying to connect to devices -smsdb=/var/lib/asterisk/smsdb -csmsttl=600 +interval = 30 ; Number of seconds between trying to connect to devices +smsdb = /var/lib/asterisk/smsdb +csmsttl = 600 ;------------------------------ JITTER BUFFER CONFIGURATION -------------------------- ;jbenable = yes ; Enables the use of a jitterbuffer on the receiving side of a @@ -41,35 +41,35 @@ csmsttl=600 ; now you can set here any not required device settings as template ; sure you can overwrite in any [device] section this default values -context=default ; context for incoming calls -group=0 ; calling group -rxgain=0 ; increase the incoming volume; may be negative -txgain=0 ; increase the outgoint volume; may be negative -autodeletesms=yes ; auto delete incoming sms -resetquectel=yes ; reset quectel during initialization with ATZ command -u2diag=-1 ; set ^U2DIAG parameter on device (0 = disable everything except modem function) ; -1 not use ^U2DIAG command -usecallingpres=yes ; use the caller ID presentation or not -callingpres=allowed_passed_screen ; set caller ID presentation by default use default network settings -disablesms=no ; disable of SMS reading from device when received +context = default ; context for incoming calls +group = 0 ; calling group +rxgain = 0 ; increase the incoming volume; may be negative +txgain = 0 ; increase the outgoint volume; may be negative +autodeletesms = yes ; auto delete incoming sms +resetquectel = yes ; reset quectel during initialization with ATZ command +u2diag = -1 ; set ^U2DIAG parameter on device (0 = disable everything except modem function) ; -1 not use ^U2DIAG command +usecallingpres = yes ; use the caller ID presentation or not +callingpres = allowed_passed_screen ; set caller ID presentation by default use default network settings +disablesms = no ; disable of SMS reading from device when received ; chan_quectel has currently a bug with SMS reception. When a SMS gets in during a ; call chan_quectel might crash. Enable this option to disable sms reception. ; default = no -language=en_GB ; set channel default language -mindtmfgap=45 ; minimal interval from end of previews DTMF from begining of next in ms -mindtmfduration=80 ; minimal DTMF tone duration in ms -mindtmfinterval=200 ; minimal interval between ends of DTMF of same digits in ms +language = en_GB ; set channel default language +mindtmfgap = 45 ; minimal interval from end of previews DTMF from begining of next in ms +mindtmfduration = 80 ; minimal DTMF tone duration in ms +mindtmfinterval = 200 ; minimal interval between ends of DTMF of same digits in ms -callwaiting=auto ; if 'yes' allow incoming calls waiting; by default use network settings +callwaiting = auto ; if 'yes' allow incoming calls waiting; by default use network settings ; if 'no' waiting calls just ignored -disable=no ; OBSOLETED by initstate: if 'yes' no load this device and just ignore this section +disable = no ; OBSOLETED by initstate: if 'yes' no load this device and just ignore this section -initstate=start ; specified initial state of device, must be one of 'stop' 'start' 'remote' +initstate = start ; specified initial state of device, must be one of 'stop' 'start' 'remote' ; 'remove' same as 'disable=yes' -exten=+1234567890 ; exten for start incoming calls, only in case of Subscriber Number not available!, also set to CALLERID(ndid) +exten = +1234567890 ; exten for start incoming calls, only in case of Subscriber Number not available!, also set to CALLERID(ndid) -dtmf=relax ; control of incoming DTMF detection, possible values: +dtmf = relax ; control of incoming DTMF detection, possible values: ; off - off DTMF tones detection, voice data passed to asterisk unaltered ; use this value for gateways or if not use DTMF for AVR or inside dialplan ; inband - do DTMF tones detection @@ -78,17 +78,8 @@ dtmf=relax ; control of incoming DTMF detection, possible values: ; quectel required settings [quectel0] -context=quectel0 -exten=+447123456789 +context = quectel0 +exten = +447123456789 -audio=/dev/ttyUSB1 ; tty port for audio connection; no default value -data=/dev/ttyUSB2 ; tty port for AT commands; no default value - -; or you can omit both audio and data together and use imei=123456789012345 and/or imsi=123456789012345 -; imei and imsi must contain exactly 15 digits ! -; imei/imsi discovery is available on Linux only -;imei=123456789012345 -;imsi=123456789012345 - -; if audio and data set together with imei and/or imsi audio and data has precedence -; you can use both imei and imsi together in this case exact match by imei and imsi required +audio = /dev/ttyUSB1 ; tty port for audio connection; no default value +data = /dev/ttyUSB2 ; tty port for AT commands; no default value diff --git a/asterisk/conf/mobile/res_stun_monitor.conf b/asterisk/conf/mobile/res_stun_monitor.conf index 1a13ac7..ad5e904 100644 --- a/asterisk/conf/mobile/res_stun_monitor.conf +++ b/asterisk/conf/mobile/res_stun_monitor.conf @@ -5,5 +5,5 @@ ; [general] -stunaddr=stun.aa.net.uk:3478 -stunrefresh=30 +stunaddr = stun.aa.net.uk:3478 +stunrefresh = 30 diff --git a/asterisk/conf/mobile/rtp.conf b/asterisk/conf/mobile/rtp.conf index aed55be..51addcb 100644 --- a/asterisk/conf/mobile/rtp.conf +++ b/asterisk/conf/mobile/rtp.conf @@ -4,5 +4,5 @@ ; Inspired by/Stolen from https://www.sacredheartsc.com/blog/building-a-personal-voip-system/ ; [general] -rtpstart=62535 -rtpend=65533 +rtpstart = 62535 +rtpend = 65533