[asterisk-users] MeetMe in Macro

Anahi Ludueña a_luduena at hotmail.com
Wed Sep 16 10:43:53 CDT 2009


Thanks,
I asked you to execute the GoSub from the Originate action, because I need to pass some parameters.
First, I created a macro since I could pass the parameters from originate. But the macro's problem is it doesn't jump to the particular extension (for example: h extension). So, when you told me that GoSub could "replace" the Macro, I thought it could be called from the Originate...
Do you know if there is another way to pass some parameters to a context from the Originate?
Thank you!





Anahi Ludueña
 
Date: Wed, 16 Sep 2009 10:27:26 -0500
From: mmolina at millenium.com.co
To: asterisk-users at lists.digium.com
Subject: Re: [asterisk-users] MeetMe in Macro






  


Hi,



The GoSub() application is intended for use in the dialplan, not to
call it from a Originate Action. What is your specific need? You can
Originate to a extension instead of an application an then if you need
to execute a subroutine, you can use GoSub() and Return() then you need
to on the called context.



You can check
http://www.voip-info.org/wiki/index.php?page=Asterisk+cmd+Gosub but the
example using the same context is not very clear.



A better example would be this:



[incoming]

exten => s,1,Answer()

exten => s,n,Noop(one)

exten => s,n,Noop(two)

exten => s,n,GoSub(mysub,s,1)

exten => s,n,Noop(I returned!)

exten => s,n,Hangup



[mysub]

exten => s,1,Noop(So I'm at a subroutine)

exten => s,n,Noop(I need to do special steps)

exten => s,n,Playback(tt-monkeys)

exten => s,n,Return()



Cheers,

-- 
Ing. Miguel Molina
Grupo de Tecnología
Millenium Phone Center



Anahi Ludueña escribió:

  Thanks Miguel, It was my mistake.

So, my question is:

    if I want to call the GoSub application from
the Originate Action (using AMI), what I need to put in the context
parameter? The GoSub will jump to a special context.

Thanks,

  

  

  

  Date: Wed, 16 Sep 2009 09:34:31 -0500

From: mmolina at millenium.com.co

To: asterisk-dev at lists.digium.com; asterisk-users at lists.digium.com

Subject: Re: [asterisk-dev] MeetMe in Macro

  

  
Hi,

  

I didn't notice on my first answer, but we are on the -dev list and
this is not related to asterisk code developing. I will answer you on
the -users list, so we can continue the discussion there.

  

Cheers,

  -- 
Ing. Miguel Molina
Grupo de Tecnología
Millenium Phone Center
  


_________________________________________________________________
Hay tantos ordenadores como personas. ¡Descubre ahora cuál eres tú!
http://www.quepceres.com/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20090916/7d265629/attachment.htm 


More information about the asterisk-users mailing list