Добавил:
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Building Telephony Systems With Asterisk (2005).pdf
Скачиваний:
45
Добавлен:
17.08.2013
Размер:
1.82 Mб
Скачать

Case Studies

Notice that we are able to create 20 extensions for our programmers in a single line. This is the power of Asterisk's pattern matching, coupled with the flexibility of macros. We can use tricks like this one by grouping similar extensions together.

;dialext.incl

;#included from extensions.conf [dialext]

include => default exten => s,1,Answer

exten => s,2,DigitTimeout(5) exten => s,3,ResponseTimeout(20)

exten => s,4,Background(pleaseenterextension) ; "Please enter the

;extension of the party you are calling."

exten => 9,1,Directory(default)

; press 9 for the directory

exten => 9,2,Goto(dialext,9,1)

 

exten => 0,1,Goto(default,100,1)

; send to operator as a

 

; courtesy if they press 0

exten => i,1,Playback(privacy-incorrect)

 

exten => i,2,Goto(dialext,s,1)

 

exten => t,1,Goto(dialext,i,1)

This small context allows users to dial anybody in the company, and also to access the corporate directory. The directory, which reads the voicemail.conf file, allows access to any extension in the company. By so doing, a "backdoor" line can be established that points directly to this extension, allowing us to no longer need direct phone numbers for each extension.

Conclusions

Asterisk has proved itself again as a powerful solution for real-world problems. By taking advantage of the feature set Asterisk provides, we are able to create a server that has the features of a Centrex system, and then some. The savings ACMEsoft will experience are very real and will pay for the system with a short ROI.

Hosted PBX

Asterisk is not limited to being able to service only one company. With a little finesse, we can configure Asterisk to handle multiple companies without any needing to be aware of the others' presence. Although our example will deal with multiple companies on one site, there is no reason the same principles could not be applied over a high-speed data network.

128