Page 10 - Asterisk™: The Future of Telephony
P. 10
Loading libpri Without Script 57
Starting Asterisk Without Scripts 57
Directories Used by Asterisk 59
AsteriskNOW ™ 62
Conclusion 67
4. Initial Configuration of Asterisk . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
What Do I Really Need? 70
Working with Interface Configuration Files 71
Setting Up the Dialplan for Some Test Calls 73
FXO and FXS Channels 73
Configuring an FXO Channel for a PSTN Connection 75
Configuring an FXS Channel for an Analog Telephone 79
Configuring SIP Telephones 81
Connecting to a SIP Service Provider 97
Connecting Two Asterisk Boxes Together via SIP 101
Configuring an IAX Softphone 106
Connecting to an IAX Service Provider 110
Connecting Two Asterisk Boxes Together via IAX 111
Using Templates in Your Configuration Files 115
Debugging 116
Conclusion 117
5. Dialplan Basics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119
Dialplan Syntax 119
A Simple Dialplan 124
Building an Interactive Dialplan 127
Conclusion 144
6. More Dialplan Concepts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 145
Expressions and Variable Manipulation 145
Dialplan Functions 148
Conditional Branching 149
Voicemail 153
Macros 157
Using the Asterisk Database (AstDB) 160
Handy Asterisk Features 163
Conclusion 165
7. Understanding Telephony . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 167
Analog Telephony 167
Digital Telephony 170
The Digital Circuit-Switched Telephone Network 180
viii | Table of Contents