hi, can anyone please guide me as to how i can implement this in extensions.conf : my PSTN line normally has its longdistance capability "locked" which can be opened by dialing some keys and the PIN. if i wanted some users to be allowed to call long distance using the zap channel, how can i initially offhook then send some DTMF then Flash twice before proceeding with the dialing EXTEN. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20051127/5a70e86f/attachment.htm
> > hi, > > can anyone please guide me as to how i can implement this in > extensions.conf: > > my PSTN line normally has its longdistance capability "locked" whichcan> be opened by dialing some keys and the PIN. > > if i wanted some users to be allowed to call long distance using thezap> channel, how can i initially offhook then send some DTMF then Flashtwice> before proceeding with the dialing EXTEN.Do you want asterisk to take care of the DTMF for you? When you say users, do you mean certain extensions? Why not cancel your restrictions with the telco and implement restrictions within asterisk. You can use authenticate before your dial statement to prompt for a pin when dialing long distance or you can create different contexts for phones that you want to access long distance and for phones that you don't Thanks, Steve
How about this?
exten => 1234567890,1,Dial(Zap/g1/yourcodehere${EXTEN})
-or-
exten => 1234567890,1,Dial(Zap/g1/yourcodeherewwww${EXTEN})
I have not seen restrictions set before dialing since local numbers
would not fall under the restriction but that is what you said. Usually
you dial the number first and if it is a long distance call, they prompt
for a code with a tone or something. The second example shoud give you
a two second pause before dialing the rest of the number (wwww).
Thanks,
Steve
>
> thanks steve,
>
> the reason i cannot remove the restriction on the telco line is that
an> analog fone is connected to the phone jack of the x101p and some
visitors> occasionally use the fone and they're supposed to only call local toll
> free numbers.
>
> Your suggestion of doing the restrictions within asterisk is good but
i> have yet to buy an FXS port for the analog fone so i cannot do so.
>
> and for the extensions connected via softphones to asterisk, i wanted
> asterisk to take care of opening the lock before dialing the desired
phone> number.
>
> i was thinking of using the "SendDTMF" but i dont know how to get
the
zap> line go off hook.
>
>
> On 11/27/05, Steve Totaro < stotaro@totarotechnologies.com
> <mailto:stotaro@totarotechnologies.com> > wrote:
>
> >
> > hi,
> >
> > can anyone please guide me as to how i can implement this in
> > extensions.conf:
> >
> > my PSTN line normally has its longdistance capability
"locked"
> which
> can
> > be opened by dialing some keys and the PIN.
> >
> > if i wanted some users to be allowed to call long distance
using> the
> zap
> > channel, how can i initially offhook then send some DTMF then
> Flash
> twice
> > before proceeding with the dialing EXTEN.
>
>
> Do you want asterisk to take care of the DTMF for you? When you
say> users, do you mean certain extensions?
>
> Why not cancel your restrictions with the telco and implement
> restrictions within asterisk. You can use authenticate before
your> dial
> statement to prompt for a pin when dialing long distance or you
can> create different contexts for phones that you want to access
long> distance and for phones that you don't
>
> Thanks,
> Steve
> _______________________________________________
> --Bandwidth and Colocation provided by Easynews.com --
>
> Asterisk-Users mailing list
> To UNSUBSCRIBE or update options visit:
> http://lists.digium.com/mailman/listinfo/asterisk-users
>
>
Wow, what a pain. I would just pickup an FXS and be done with it.> > > Thanks Steve, > > But this will not work for me because after "yourcodehere" the linewill> give a confirmation tone (similar to a congestion tone only faster)then> after flashing or certain period will turn into a busytone and to getthe> dialtone again i need to Flash again before i can dial ${EXTEN}. > > > > On 11/28/05, Steve Totaro <stotaro@totarotechnologies.com> wrote: > > How about this? > > exten => 1234567890,1,Dial(Zap/g1/yourcodehere${EXTEN}) > -or- > exten => 1234567890,1,Dial(Zap/g1/yourcodeherewwww${EXTEN}) > > I have not seen restrictions set before dialing since localnumbers> would not fall under the restriction but that is what you said. > Usually > you dial the number first and if it is a long distance call,they> prompt > for a code with a tone or something. The second example shoudgive> you > a two second pause before dialing the rest of the number (wwww). > > Thanks, > Steve > > > > > > thanks steve, > > > > the reason i cannot remove the restriction on the telco lineis> that > an > > analog fone is connected to the phone jack of the x101p andsome> visitors > > occasionally use the fone and they're supposed to only calllocal> toll > > free numbers. > > > > Your suggestion of doing the restrictions within asterisk isgood> but > i > > have yet to buy an FXS port for the analog fone so i cannot doso.> > > > and for the extensions connected via softphones to asterisk, i > wanted > > asterisk to take care of opening the lock before dialing the > desired > phone > > number. > > > > i was thinking of using the "SendDTMF" but i dont know how toget> the > zap > > line go off hook. > > > > > > On 11/27/05, Steve Totaro < stotaro@totarotechnologies.com > <mailto:stotaro@totarotechnologies.com> > > <mailto:stotaro@totarotechnologies.com> > wrote: > > > > > > > > hi, > > > > > > can anyone please guide me as to how i can implementthis> in > > > extensions.conf: > > > > > > my PSTN line normally has its longdistance capability > "locked" > > which > > can > > > be opened by dialing some keys and the PIN. > > > > > > if i wanted some users to be allowed to call longdistance> using > > the > > zap > > > channel, how can i initially offhook then send someDTMF> then > > Flash > > twice > > > before proceeding with the dialing EXTEN. > > > > > > Do you want asterisk to take care of the DTMF for you?When> you > say > > users, do you mean certain extensions? > > > > Why not cancel your restrictions with the telco and > implement > > restrictions within asterisk. You can use authenticate > before > your > > dial > > statement to prompt for a pin when dialing long distanceor> you > can > > create different contexts for phones that you want toaccess> long > > distance and for phones that you don't > > > > Thanks, > > Steve
This might work if you switch it around a little. http://www.voip-info.org/wiki-Asterisk+cmd+Flash> -----Original Message----- > From: MZ [mailto:ultor_forum@jefmart.com] > Sent: Sunday, November 27, 2005 12:54 PM > To: Asterisk Users Mailing List - Non-Commercial Discussion > Subject: Re: [Asterisk-Users] Dialplan help > > > Thanks Steve, > > But this will not work for me because after "yourcodehere" the linewill> give a confirmation tone (similar to a congestion tone only faster)then> after flashing or certain period will turn into a busytone and to getthe> dialtone again i need to Flash again before i can dial ${EXTEN}. > > > > On 11/28/05, Steve Totaro <stotaro@totarotechnologies.com> wrote: > > How about this? > > exten => 1234567890,1,Dial(Zap/g1/yourcodehere${EXTEN}) > -or- > exten => 1234567890,1,Dial(Zap/g1/yourcodeherewwww${EXTEN}) > > I have not seen restrictions set before dialing since localnumbers> would not fall under the restriction but that is what you said. > Usually > you dial the number first and if it is a long distance call,they> prompt > for a code with a tone or something. The second example shoudgive> you > a two second pause before dialing the rest of the number (wwww). > > Thanks, > Steve > > > > > > thanks steve, > > > > the reason i cannot remove the restriction on the telco lineis> that > an > > analog fone is connected to the phone jack of the x101p andsome> visitors > > occasionally use the fone and they're supposed to only calllocal> toll > > free numbers. > > > > Your suggestion of doing the restrictions within asterisk isgood> but > i > > have yet to buy an FXS port for the analog fone so i cannot doso.> > > > and for the extensions connected via softphones to asterisk, i > wanted > > asterisk to take care of opening the lock before dialing the > desired > phone > > number. > > > > i was thinking of using the "SendDTMF" but i dont know how toget> the > zap > > line go off hook. > > > > > > On 11/27/05, Steve Totaro < stotaro@totarotechnologies.com > <mailto:stotaro@totarotechnologies.com> > > <mailto:stotaro@totarotechnologies.com> > wrote: > > > > > > > > hi, > > > > > > can anyone please guide me as to how i can implementthis> in > > > extensions.conf: > > > > > > my PSTN line normally has its longdistance capability > "locked" > > which > > can > > > be opened by dialing some keys and the PIN. > > > > > > if i wanted some users to be allowed to call longdistance> using > > the > > zap > > > channel, how can i initially offhook then send someDTMF> then > > Flash > > twice > > > before proceeding with the dialing EXTEN. > > > > > > Do you want asterisk to take care of the DTMF for you?When> you > say > > users, do you mean certain extensions? > > > > Why not cancel your restrictions with the telco and > implement > > restrictions within asterisk. You can use authenticate > before > your > > dial > > statement to prompt for a pin when dialing long distanceor> you > can > > create different contexts for phones that you want toaccess> long > > distance and for phones that you don't > > > > Thanks, > > Steve > > _______________________________________________ > > --Bandwidth and Colocation provided by Easynews.com -- > > > > Asterisk-Users mailing list > > To UNSUBSCRIBE or update options visit: > >http://lists.digium.com/mailman/listinfo/asterisk-users> > > > > > _______________________________________________ > --Bandwidth and Colocation provided by Easynews.com -- > > Asterisk-Users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users > >
Dear friends,
Does anyone know how do i convert hex to int in the dialplan. I want to do
this:-
Take the sip call-id in hex, use CUT to extract the first part , and convert it
to an int. But the math function ony takes arguments as int. Can anyone suggest
how to do that?
eg:-
exten => _X.,n,Set(sipcid = ${CUT(SIPCALLID,-,1)}) ---> evaluates to
E305CEC5
I want this hex value in int. But i cant think of a clean solution.
Please help.
Thanks in advance.
With warm regards.
Vivek J. Joshi.
vivek@staff.ownmail.com
Trikon electronics Pvt. Ltd.
All science is either physics or stamp collecting.
-- Ernest Rutherford
On 14:23, Wed 30 Aug 06, vivek@staff.ownmail.com wrote:> Dear friends, > Does anyone know how do i convert hex to int in the dialplan. I want to do this:- > Take the sip call-id in hex, use CUT to extract the first part , and convert it to an int. But the math function ony takes arguments as int. Can anyone suggest how to do that? > eg:- > exten => _X.,n,Set(sipcid = ${CUT(SIPCALLID,-,1)}) ---> evaluates to E305CEC5 > I want this hex value in int. But i cant think of a clean solution. > Please help. >Use a simple agi script that does this for you. -- Michiel van Baak michiel@vanbaak.eu http://michiel.vanbaak.eu GnuPG key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x71C946BD "Why is it drug addicts and computer afficionados are both called users?"
Hi Michael,
Thanks a lot. I am working on an agi script and it does it. Thanks a lot again.
With warm regards.
Vivek J. Joshi.
vivek@staff.ownmail.com
Trikon electronics Pvt. Ltd.
All science is either physics or stamp collecting.
-- Ernest Rutherford
Michiel van Baak wrote:> >On 14:23, Wed 30 Aug 06, vivek@staff.ownmail.com wrote:
>> Dear friends,
>> Does anyone know how do i convert hex to int in the dialplan. I want
to do
this:->> Take the sip call-id in hex, use CUT to extract the first part , and
convert
it to an int. But the math function ony takes arguments as int. Can anyone
suggest how to do that?>> eg:-
>> exten => _X.,n,Set(sipcid = ${CUT(SIPCALLID,-,1)}) --->
evaluates to E305CEC5
>> I want this hex value in int. But i cant think of a clean solution.
>> Please help.
>>
>
>Use a simple agi script that does this for you.
>
>--
>Michiel van Baak
>michiel@vanbaak.eu
>http://michiel.vanbaak.eu
>GnuPG key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x71C946BD
>
>"Why is it drug addicts and computer afficionados are both called
users?"
>
>_______________________________________________
>--Bandwidth and Colocation provided by Easynews.com --
>
>asterisk-users mailing list
>To UNSUBSCRIBE or update options visit:
> http://lists.digium.com/mailman/listinfo/asterisk-users