NSLU2-Linux
view · edit · print · history

Optware.AsteriskCallbackDISA History

Hide minor edits - Show changes to markup

January 23, 2007, at 06:44 AM by ka6sox --
Changed lines 6-7 from:

your VoIP? service by calling out through your home Asterisk server.

to:

your VoIP service by calling out through your home Asterisk server.

Changed line 33 from:

Here is how I setup my home Asterisk on Slug. I am using UnSlung? 6.8

to:

Here is how I setup my home Asterisk on Slug. I am using UnSlung 6.8

January 23, 2007, at 06:42 AM by ka6sox --
Changed line 16 from:

3. Your cellphone should have a legitimate CallerID? number. (We use

to:

3. Your cellphone should have a legitimate CallerID number. (We use

Changed line 34 from:

with Asterisk14 installed. A DID number 6085558888 from MyVSP? is

to:

with Asterisk14 installed. A DID number 6085558888 from MyVSP is

Changed line 41 from:

Channel: SIP/6081112222@MyVSP?

to:

Channel: SIP/6081112222@MyVSP

January 22, 2007, at 04:48 AM by J Gao -- format
Added line 54:
Changed lines 70-74 from:

exten => h,1,NoOp?(copy callback.call file to /opt/var/spool/asterisk/outgoing) exten => h,2,System(/opt/etc/asterisk/callback_exe) exten => h,3,Hangup()

to:

exten => h,1,System(/opt/etc/asterisk/callback_exe) exten => h,2,Hangup()

January 22, 2007, at 04:45 AM by J Gao -- J Gao
Changed lines 1-2 from:

Who need this?

to:

Who need this?

Changed lines 8-9 from:

Requirement:

to:

Requirement:

Added line 13:
Added line 15:
Changed lines 19-20 from:

How it works?

to:

How it works?

Added line 23:
Added line 27:
January 22, 2007, at 04:44 AM by J Gao -- format
Deleted line 0:
Changed lines 24-25 from:

Setup

to:

Setup

Added line 40:
Added line 83:
Deleted lines 84-85:

@]

January 22, 2007, at 04:40 AM by J Gao -- format
Changed lines 1-2 from:

[@

to:
Added line 33:

[@

Changed line 39 from:
to:

@]

Added line 42:

[@

Added line 45:

@]

Added line 47:

[@

Changed lines 49-50 from:
to:

@]

Added line 52:

[@

Changed lines 55-58 from:

exten => 6085558888 ,n,GotoIf?("${CALLERID(num)}" = "6081112222"? custom-CallBack?,s,1)

to:

exten => 6085558888 ,n,GotoIf?("${CALLERID(num)}" = "6081112222"?custom-CallBack?,s,1)

Changed lines 72-73 from:
to:

@]

Added line 75:

[@

Changed line 81 from:
to:

@]

January 22, 2007, at 03:03 AM by cdoban -- added callbackDISA feature done by Jian
Added lines 1-79:

Who need this?
If you have a unlimited incoming cellphone service plan, you can use
this method to call out without paying outgoing minute charge. You
may also take advantage of your low long distance calling rate of
your VoIP service by calling out through your home Asterisk server.

Requirement:
1. Your Asterisk box (in my case this is the Slug) should be able to
make at least two simultaneous outgoing calls. (One to call you back
and the other provides DISA to dial out.)
2. A separate Direct-Inward-Dial (DID) number dedicated to this task.
3. Your cellphone should have a legitimate CallerID number. (We use
this to identify the caller.)

How it works?
1. Call your DID number on your Asterisk box from your cellphone.
When you hear the ringing tone, just hang up your cellphone.
2. Wait 20 sec, your cellphone will get a incoming call from your
Asterisk box. Answer it, follow the instruction, press your password
and the #, if everything is all right, you should get a dial tone.
3. Now you may make an outgoing call from there. All calls should be
routed from your Asterisk PBX using the lowest calling rate.

Setup
Here is how I setup my home Asterisk on Slug. I am using UnSlung 6.8
with Asterisk14 installed. A DID number 6085558888 from MyVSP is
setup for this task. My cellphone number is 6081112222. You should
change these to fit your situation.

1. Create a file named /opt/etc/asterisk/callback.call with the
following lines:
Channel: SIP/6081112222@MyVSP
Context: custom-DISA-out
Extension: s
Priority: 1
CallerID: 6085558888

2. Create a file named /opt/etc/asterisk/callback_exe with the
following lines:
sleep 20
cp /opt/etc/asterisk/callback.call /opt/var/spool/asterisk/outgoing
Make this file executable:
chmod +x /opt/etc/asterisk/callback_exe

3. In your extensions.conf:
[MyVSP-incoming]
exten => 6085558888 ,1,NoOp(Incoming call from # ${CALLERID(num)})
exten => 6085558888 ,n,GotoIf($["${CALLERID(num)}" = "6081112222"]?
custom-CallBack,s,1)


[custom-CallBack]
;;prepare for callback and DISA
exten => s,1,NoOp(Hangup then callback to cellphone)
exten => s,2,Hangup()
exten => h,1,NoOp(copy callback.call file
to /opt/var/spool/asterisk/outgoing)
exten => h,2,System(/opt/etc/asterisk/callback_exe)
exten => h,3,Hangup()

[custom-DISA-out]
exten => s,1,Wait(1)
exten => s,n,Background(agent-pass)
exten => s,n,Authenticate(87235) ;this number is the password
exten => s,n,Background(pls-wait-connect-call)
exten => s,n,DISA(no-password|out-pstn)

4. in your modules.conf, make sure the following modules are loaded:
load=app_authenticate.so
load=app_disa.so
load=app_system.so
load=pbx_spool.so
load=func_callerid.so

5. Restart Asterisk and test it.

view · edit · print · history · Last edited by ka6sox.
Based on work by ka6sox and J Gao.
Originally by cdoban.
Page last modified on January 23, 2007, at 06:44 AM