User talk:Jonas Oestman/Howto/Asterisk

From BubbaWiki
< User talk:Jonas Oestman‎ | Howto
Revision as of 19:19, 25 April 2013 by Jonas Oestman (talk | contribs) (→‎Play GSM files: new section)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

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.