How to: Configure Tel2 SIP trunk with Asterisk using CHAN_SIP

Matthew Atkinson

Last Update 8 bulan yang lalu

As a big supporter of open source projects, Tel2 supports connectivity to Asterisk using either the SIP or IAX2 protocol.


This guide is a sample configuration for connecting to Asterisk using chan_sip (sip.conf). For sample configurations for PJSIP or IAX2, please see our configuration guides:



in the below sample configs, replace {{yournumber}} with your actual Tel2 number (e.g. 442034567890) and {{yourpassword}} with your Tel2 password.

sip.conf

[general]
registerattempts=0
registertimeout=20
; Register line should be somewhere inside your general section
register => {{yournumber}}:{{yourpassword}}@phone.tel2.co.uk/{{yournumber}}


[Tel2]
type=friend
username={{yournumber}}
fromuser={{yournumber}}
secret={{yourpassword}}
host=phone.tel2.co.uk
context=default ; or your own selected context if desired
dtmfmode=rfc2833
disallow=all
allow=alaw
allow=ulaw
;allow=g729 ; or gsm, ilbc, g722, etc
nat=yes
canreinvite=no
insecure=invite,port

extensions.conf

[default]
;receive incoming calls to a connected phone
exten => s,1,Dial(SIP/{{yournumber}})
; outbound calls (outside of your own PBX)
exten => _X.*,1,Dial(SIP/${EXTEN}@Tel2)

Still need help? Message Us