Project

General

Profile

extensions.conf

Asterisk config file, put it to /etc/asterisk/extensions.conf - csaba, 09/23/2015 04:08 PM

Download (1.5 KB)

 
1
[general]
2
static=yes
3
writeprotect=no
4
clearglobalvars=no
5

    
6
[globals]
7
; Global variables goes here
8

    
9
[incoming]
10
; Nothing should land here yet, but every context should end in
11
; a Hangup(), so we do that.
12
exten => s,1,Hangup()
13

    
14
[myphones]
15
; When we dial something from the phones we just added in
16
; sip.conf, Asterisk will look for a matching extension here,
17
; in this context.
18

    
19
; First Phone, extension 1000. If 1000 is called, here is
20
; where we land, and the device registered with the
21
; name 1000, is dialed, after that Asterisk hangs up.
22

    
23
exten => _XXXXX,1,lcr_config(a)
24
exten => _XXXXX,2,lcr_config(a)
25
exten => _XXXXX,3,Set(VOLUME(TX)=4)
26
exten => _XXXXX,4,Set(VOLUME(RX)=4)
27
exten => _XXXXX,5,Dial(LCR/ast/${EXTEN},10)
28
exten => _XXXXX,n,Hangup()
29

    
30
; Elevator music
31
exten => 201,1,lcr_config(a)
32
exten => 201,2,lcr_config(D)
33
exten => 201,3,Set(VOLUME(TX)=2)
34
exten => 201,4,Set(VOLUME(RX)=2)
35
exten => 201,5,Answer()
36
exten => 201,n,Playback(/usr/share/asterisk/moh/reno_project-system)
37
exten => 201,n,Hangup()
38

    
39
; Echo-test, it is good to test if we have sound in both directions.
40
; The call is answered
41
exten => 202,1,lcr_config(a)
42
exten => 202,2,lcr_config(D)
43
exten => 202,3,Set(VOLUME(TX)=2)
44
exten => 202,4,Set(VOLUME(RX)=2)
45
exten => 202,5,Answer()
46
exten => 202,6,Echo()
47
exten => 202,n,Hangup()
48

    
49
; Constant test tone
50
exten => 203,1,Set(VOLUME(TX)=1)
51
exten => 203,2,Set(VOLUME(RX)=1)
52
exten => 203,3,Answer()
53
exten => 203,4,Milliwatt()
54
exten => 203,n,Hangup()
55

    
56

    
57
[from-lcr]
58
include => myphones
59
;exten => _X.,1,Dial(LCR/ast/${EXTEN:0},60)