Difference between revisions of "User talk:Jonas Oestman/Howto/Asterisk"
Jump to navigation
Jump to search
(→Play GSM files: new section) |
|||
(4 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
bubba1 sarge | bubba1 sarge '''etc/asterisk/sip.conf''' | ||
'''etc/asterisk/sip.conf''' | <pre>[general] | ||
<pre> | |||
[general] | |||
context=incomming | context=incomming | ||
bindport=5060 | bindport=5060 | ||
Line 13: | Line 10: | ||
localnet=192.168.0.0/255.255.254.0 | localnet=192.168.0.0/255.255.254.0 | ||
register = | register => 0123456789:PUTSOMETHINGHERE@sipserver.alltele.se | ||
[gahron] | [gahron] | ||
Line 35: | Line 32: | ||
insecure=very | insecure=very | ||
allow=all | allow=all | ||
</pre> | </pre> | ||
'''extensions.conf''' | |||
'''extensions.conf''' | |||
<pre> | <pre> | ||
[general] | [general] | ||
static=yes | static=yes | ||
Line 50: | Line 45: | ||
[globals] | [globals] | ||
CONSOLE=Console/dsp ; Console interface for demo | CONSOLE=Console/dsp ; Console interface for demo | ||
IAXINFO=guest ; IAXtel username/password | IAXINFO=guest ; IAXtel username/password | ||
TRUNK=Zap/g2 ; Trunk interface | TRUNK=Zap/g2 ; Trunk interface | ||
TRUNKMSD=1 ; MSD digits to strip (usually 1 | TRUNKMSD=1 ; MSD digits to strip (usually 1 | ||
[incomming] | [incomming] | ||
exten = | exten => s,1,Dial(SIP/hardphone) | ||
[outgoing] | [outgoing] | ||
exten = | exten => _X.,1,Dial(SIP/${EXTEN}@RixTelecom) | ||
[hello] | |||
exten => hello,1,NoOp(${CALLERID(all)} called at ${STRFTIME(${EPOCH},,%Y%m%d-%H:%M:%S)}) | |||
exten => hello,n,Answer() | |||
exten => hello,n,Playback(hello-world) | |||
exten => hello,n,SayUnixTime(,Europe/Stockholm) | |||
exten => hello,n,SayAlpha(abcdefghijklmnopqrstuvwxyz) | |||
exten => hello,n,SayDigits(1234567890) | |||
exten => hello,n,SayNumber(123456789) | |||
exten => hello,n,SayPhonetic(abcdefghijklmnopqrstuvwxyz) | |||
exten => hello,n,SendDTMF(1234567890) | |||
exten => hello,n,Playback(vm-goodbye) | |||
exten => hello,n,Hangup() | |||
[echo] | |||
exten => echo,1,Answer() | |||
exten => echo,n,Echo() | |||
exten => echo,n,Playback(vm-goodbye) | |||
exten => echo,n,Hangup() | |||
[hardphone] | |||
exten => hardphone,1,Dial(SIP/hardphone) | |||
[callmeonallphones] | |||
exten => barefoot,1,Dial(SIP/hardphone&SIP/softphone&SIP/n95&SIP/hp6910&SIP/kphone) | |||
</pre> | </pre> | ||
'''Callerid''' läggar man in genom att skriva detta i en kedja <sup>exten => s,n,AGI(/home/asterisk/set_callerid.php)</sup> | |||
'''Ring lokalt, lägg på riktnummer''' | |||
<pre> | |||
exten => _XXXXX,1,Dial(SIP/090${EXTEN}@RixTelecom) | |||
exten => _XXXXXX,1,Dial(SIP/090${EXTEN}@RixTelecom) | |||
exten => _XXXXXXX,1,Dial(SIP/090${EXTEN}@RixTelecom) | |||
</pre> | |||
== Play GSM files == | |||
If you install this package http://archive.debian.net/lenny/sox | |||
you can play them with the "play" command. |
Latest revision as of 19:19, 25 April 2013
bubba1 sarge etc/asterisk/sip.conf
[general] context=incomming bindport=5060 bindaddr=0.0.0.0 ;srvlookup=yes realm=PUTSOMETHINGHERE.org ;realm=asterisk externhost=UTSOMETHINGHERE.org localnet=192.168.0.0/255.255.254.0 register => 0123456789:PUTSOMETHINGHERE@sipserver.alltele.se [gahron] type=friend secret=hmm context=internal host=dynamic Callerid=User Name qualify=3000 [RixTelecom] type=peer fromuser=0123456789 username=0123456789 authname=0123456789 authuser=0123456789 secret=PUTSOMETHINGHERE password=PUTSOMETHINGHERE host=int.sipserver.alltele.se fromdomain=cx-cust-shg02.rixtelecom.se insecure=very allow=all
extensions.conf
[general] static=yes writeprotect=no autofallthrough=yes clearglobalvars=no priorityjumping=no CONSOLE=Console/dsp [globals] CONSOLE=Console/dsp ; Console interface for demo IAXINFO=guest ; IAXtel username/password TRUNK=Zap/g2 ; Trunk interface TRUNKMSD=1 ; MSD digits to strip (usually 1 [incomming] exten => s,1,Dial(SIP/hardphone) [outgoing] exten => _X.,1,Dial(SIP/${EXTEN}@RixTelecom) [hello] exten => hello,1,NoOp(${CALLERID(all)} called at ${STRFTIME(${EPOCH},,%Y%m%d-%H:%M:%S)}) exten => hello,n,Answer() exten => hello,n,Playback(hello-world) exten => hello,n,SayUnixTime(,Europe/Stockholm) exten => hello,n,SayAlpha(abcdefghijklmnopqrstuvwxyz) exten => hello,n,SayDigits(1234567890) exten => hello,n,SayNumber(123456789) exten => hello,n,SayPhonetic(abcdefghijklmnopqrstuvwxyz) exten => hello,n,SendDTMF(1234567890) exten => hello,n,Playback(vm-goodbye) exten => hello,n,Hangup() [echo] exten => echo,1,Answer() exten => echo,n,Echo() exten => echo,n,Playback(vm-goodbye) exten => echo,n,Hangup() [hardphone] exten => hardphone,1,Dial(SIP/hardphone) [callmeonallphones] exten => barefoot,1,Dial(SIP/hardphone&SIP/softphone&SIP/n95&SIP/hp6910&SIP/kphone)
Callerid läggar man in genom att skriva detta i en kedja exten => s,n,AGI(/home/asterisk/set_callerid.php)
Ring lokalt, lägg på riktnummer
exten => _XXXXX,1,Dial(SIP/090${EXTEN}@RixTelecom) exten => _XXXXXX,1,Dial(SIP/090${EXTEN}@RixTelecom) exten => _XXXXXXX,1,Dial(SIP/090${EXTEN}@RixTelecom)
Play GSM files
If you install this package http://archive.debian.net/lenny/sox you can play them with the "play" command.