[Asterisk-Users] SIP exten to PSTN calls

Rich Adamson radamson at routers.com
Tue Aug 16 05:26:20 MST 2005


> The Dial plan is given below
> 
> [incoming]
> 
> exten => 197,1,Dial(SIP/197,20,tr)
> exten => 197,2,Hangup
> exten => 198,1,Dial(SIP/198,20,tr)
> exten => 198,2,Hangup
> 
> 
> exten=>_0.,1,Dial(Zap/1/SIP/197,20,tT)
> exten=>_0.,1,Dial(Zap/1/SIP/198,20,tT)

Those last two statements are incorrect. You want something like this:

exten => _X11,1,Dial(Zap/1/${EXTEN}) 

where the _X11 (in this specific case) is intended to match what the
user dialed (eg, 411), the call is to be sent out Zap/1 interface, and
the number to be sent to the pstn is ${EXTEN} which "is" what the
user dialed (411 in this example).

Not sure what country you're in or what the standard dial plan looks
like for your country, so you might have to experiment a little with
multiple statements to cover all pstn numbering cases. If your local
pstn dial plan involves seven digits (as another example), then the
statement would look something like this:

exten => _XXXXXXX,1,Dial(Zap/1/${EXTEN})






More information about the asterisk-users mailing list