[asterisk-users] API: how to bridge originated call?

chester c young chestercyoung at yahoo.com
Wed Jan 10 18:25:30 MST 2007


Moises

what you've done here looks great, but some examples or a little doc
would be really helpful - following the bug report, although
informative, is a very difficult way to extract specs.

in my case I want a user to be on-line all the time - the system will
dial and connect them and, when they're done, they select the next one.
 what I'm doing now is putting them into a loop with a g-option on the
dial.  the number it dials is set thru the api.  if the number's not
set it waits one second and loops again.

from my limited knowledge using a Bridge() function is much more
elegant, but I am in the dark as to what the context of the user, what
happens on hangup (can it fall thru?), etc.

maybe after this demo is done I'll solve this correctly using Bridge,
but alas little time now for experimentations.

thanks
cy



--- Moises Silva <moises.silva at gmail.com> wrote:

> I have uploaded a working patch for version 1.2.12.1, and other that
> seems to work in Trunk, but few people is reporting results, you can
> help to get this into Asterisk, go here:
> 
> http://bugs.digium.com/view.php?id=5841
> 
> The patch I ported to 1.2.12.1 is working fine, I have tested in my
> servers, is the one called "bridge-1.2.12.1.patch", there are other
> ones that say trunk, obviously only work with the trunk version of
> Asterisk.
> 
> Kind Regards
> 
> On 1/3/07, chester c young <chestercyoung at yahoo.com> wrote:
> > (my pstn calls are coming in thru an upstream asterisk server, so
> the
> > called and calling phone number is passed as an extension.)
> >
> > when caller comes in on 5551111, he will go to extension 1234 where
> he
> > will wait for the API to make a call to 9992222 for him.  how do I
> > bridge the two calls?
> >
> > extensions.conf:
> >
> > ;context where caller comes in
> > [caller]
> > 5551111,s,1 Answer()
> > 5551111,s,n UserEvent(Init) ;this lets me know the connection for
> > 5551111
> > 5551111,1234,1 Noop(caller waits to be bridged)
> > 5551111,1234,2 Background(soothingmusic)
> >
> > ;context for connection - is this needed?
> > [connect]
> >
> >
> > from the API:
> >
> > (do I need to create a new context/extension first?)
> >
> > Action: Originate
> > Channel: IAX2/upstream/9992222  <-- calls 999222 thru upsteam IAX
> > Context: ??
> > Exten: ??
> > Priority: ??
> >
> >
> >
> > __________________________________________________
> > Do You Yahoo!?
> > Tired of spam?  Yahoo! Mail has the best spam protection around
> > http://mail.yahoo.com
> > _______________________________________________
> > --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
> >
> 
> 
> -- 
> "Su nombre es GNU/Linux, no solamente Linux, mas info en
> http://www.gnu.org"
> _______________________________________________
> --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
> 



 
____________________________________________________________________________________
Yahoo! Music Unlimited
Access over 1 million songs.
http://music.yahoo.com/unlimited


More information about the asterisk-users mailing list