Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Al Baker
SO does that mean that if he used BACKGROUND is a SubRoutine  he would
get the correct or desired action , from his point of view? It would 
jump to the 1 Extension in the SUBROUTINE ?

Tilghman Lesher wrote:
 On Thursday 10 July 2008 19:13:50 Douglas Garstang wrote:
   
 It's a known problem.

 If you call Background() in a macro, then Asterisk will look for the
 extensions to jump to in the CALLING Macro/context and NOT the Macro that
 the Background() app was called in.
 

 I wouldn't call it a known problem.  It works precisely as it was designed to
 work.  It may not work the way that you want it to, but it works like a Macro:
 an independent set of instructions, with substitution, that acts as if it were
 invoked inline with the calling location.  That is why Background will match
 in the context of the calling location: it acts like it never left that
 original context (and, in a way, it really didn't).

 Subroutines are a different beast, and they are available with the Gosub/
 Return set of routines in app_stack.so.

   

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Douglas Garstang
Well I can tell you that it makes a difficult programming environment, just a 
little more difficult. It means I can't implement a menu as a single reusable 
piece of code inside a macro. 


- Original Message 
From: Tilghman Lesher [EMAIL PROTECTED]
To: Asterisk Users Mailing List - Non-Commercial Discussion 
asterisk-users@lists.digium.com
Sent: Thursday, July 10, 2008 6:07:36 PM
Subject: Re: [asterisk-users] Asterisk as an IVR solution

On Thursday 10 July 2008 19:13:50 Douglas Garstang wrote:
 It's a known problem.

 If you call Background() in a macro, then Asterisk will look for the
 extensions to jump to in the CALLING Macro/context and NOT the Macro that
 the Background() app was called in.

I wouldn't call it a known problem.  It works precisely as it was designed to
work.  It may not work the way that you want it to, but it works like a Macro:
an independent set of instructions, with substitution, that acts as if it were
invoked inline with the calling location.  That is why Background will match
in the context of the calling location: it acts like it never left that
original context (and, in a way, it really didn't).

Subroutines are a different beast, and they are available with the Gosub/
Return set of routines in app_stack.so.

-- 
Tilghman

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users



  ___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread randulo
On Fri, Jul 11, 2008 at 8:28 AM, Douglas Garstang [EMAIL PROTECTED] wrote:
 Well I can tell you that it makes a difficult programming environment, just
 a little more difficult. It means I can't implement a menu as a single
 reusable piece of code inside a macro.

I do the IVR stuff in a context and jump to it as needed. The context
is reusable from anywhere.

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Tilghman Lesher
On Friday 11 July 2008 01:28:34 Douglas Garstang wrote:
 Well I can tell you that it makes a difficult programming environment, just
 a little more difficult. It means I can't implement a menu as a single
 reusable piece of code inside a macro.

That's the point.  A Macro is NOT a subroutine.  It's like saying that you
can't effectively hammer a nail with a screwdriver, and therefore you think
the screwdriver has a known problem.  There's nothing wrong with the
screwdriver; it simply is the wrong tool for the job.

-- 
Tilghman

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Douglas Garstang
Yes, and by doing that your compounding the fact that all your variables are 
global.


- Original Message 
From: randulo [EMAIL PROTECTED]
To: Asterisk Users Mailing List - Non-Commercial Discussion 
asterisk-users@lists.digium.com
Sent: Friday, July 11, 2008 12:14:28 AM
Subject: Re: [asterisk-users] Asterisk as an IVR solution

On Fri, Jul 11, 2008 at 8:28 AM, Douglas Garstang [EMAIL PROTECTED] wrote:
 Well I can tell you that it makes a difficult programming environment, just
 a little more difficult. It means I can't implement a menu as a single
 reusable piece of code inside a macro.

I do the IVR stuff in a context and jump to it as needed. The context
is reusable from anywhere.

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users



  ___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Tilghman Lesher
On Friday 11 July 2008 01:05:22 Al Baker wrote:
 Tilghman Lesher wrote:
  On Thursday 10 July 2008 19:13:50 Douglas Garstang wrote:
  It's a known problem.
 
  If you call Background() in a macro, then Asterisk will look for the
  extensions to jump to in the CALLING Macro/context and NOT the Macro
  that the Background() app was called in.
 
  I wouldn't call it a known problem.  It works precisely as it was
  designed to work.  It may not work the way that you want it to, but it
  works like a Macro: an independent set of instructions, with
  substitution, that acts as if it were invoked inline with the calling
  location.  That is why Background will match in the context of the
  calling location: it acts like it never left that original context (and,
  in a way, it really didn't).
 
  Subroutines are a different beast, and they are available with the Gosub/
  Return set of routines in app_stack.so.

 SO does that mean that if he used BACKGROUND is a SubRoutine  he would
 get the correct or desired action , from his point of view? It would
 jump to the 1 Extension in the SUBROUTINE ?

Yes, if he used Background within a Gosub, it would behave the way that he
expects.

-- 
Tilghman

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Tilghman Lesher
On Friday 11 July 2008 09:22:25 Douglas Garstang wrote:
 Yes, and by doing that your compounding the fact that all your variables
 are global.

No, his variables are local to the channel he's using.  Global variables are
a completely different beast.

-- 
Tilghman

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Douglas Garstang
Well, a macro is the closest thing the dial plan has to a subroutine, and 
without that, we might as well be programming in Assembler (no subroutines, 
local variables, lots of goto's... sound familiar?).

Doug.


- Original Message 
From: Tilghman Lesher [EMAIL PROTECTED]
To: Asterisk Users Mailing List - Non-Commercial Discussion 
asterisk-users@lists.digium.com
Sent: Friday, July 11, 2008 7:20:40 AM
Subject: Re: [asterisk-users] Asterisk as an IVR solution

On Friday 11 July 2008 01:28:34 Douglas Garstang wrote:
 Well I can tell you that it makes a difficult programming environment, just
 a little more difficult. It means I can't implement a menu as a single
 reusable piece of code inside a macro.

That's the point.  A Macro is NOT a subroutine.  It's like saying that you
can't effectively hammer a nail with a screwdriver, and therefore you think
the screwdriver has a known problem.  There's nothing wrong with the
screwdriver; it simply is the wrong tool for the job.

-- 
Tilghman

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users



  ___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Douglas Garstang
Ugh. Yes, the variables are local to the current channel. However, they are 
global to the entire dial plan within the current channel. I have stepped on 
myself many times because I've had a loop counter called $i for example, jumped 
somewhere else within that loop, reused the same variable name, $i, and screwed 
up my logic.

Surely you where aware that's the type of thing I was talking about. I'd be 
surprised if you didn't.

Doug.


- Original Message 
From: Tilghman Lesher [EMAIL PROTECTED]
To: Asterisk Users Mailing List - Non-Commercial Discussion 
asterisk-users@lists.digium.com
Sent: Friday, July 11, 2008 7:36:54 AM
Subject: Re: [asterisk-users] Asterisk as an IVR solution

On Friday 11 July 2008 09:22:25 Douglas Garstang wrote:
 Yes, and by doing that your compounding the fact that all your variables
 are global.

No, his variables are local to the channel he's using.  Global variables are
a completely different beast.

-- 
Tilghman

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users



  ___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Steve Edwards
On Fri, 11 Jul 2008, Douglas Garstang wrote:

 Ugh. Yes, the variables are local to the current channel. However, they 
 are global to the entire dial plan within the current channel. I have 
 stepped on myself many times because I've had a loop counter called $i 
 for example, jumped somewhere else within that loop, reused the same 
 variable name, $i, and screwed up my logic.

Ugh indeed. While I sympathize with your local/global name space issues, 
you lose credibility with your false economy.

IMNSHO, anybody who uses a single [common] letter for a variable deserves 
a bump in the temperature when they reach their final resting place :)

For example, out of the 157 applications on one of my Asterisk servers, 76 
contain the letter l.

(absolutetimeout, adsiprog, agentcallbacklogin, agentlogin, 
agentmonitoroutgoing, agi, alarmreceiver, appendcdruserfield, 
authenticate, changemonitor, chanisavail, congestion, datetime, deadagi, 
dial, dictate, digittimeout, directory, disa, dundilookup, eagi, endwhile, 
execif, execiftime, externalivr, festival, getcpeid, gosubif, gotoif, 
gotoiftime, hasnewvoicemail, hasvoicemail, iax2provision, ices, importvar, 
lookupblacklist, lookupcidname, macroexit, macroif, mailboxexists, 
meetmeadmin, milliwatt, mixmonitor, monitor, pickup, privacymanager, 
readfile, realtime, realtimeupdate, responsetimeout, retrydial, ringing, 
saydigits, sayphonetic, sayunixtime, sendimage, setcallerid, 
setcdruserfield, setcidname, setcidnum, setrdnis, settransfercapabilit, 
sipaddheader, sipdtmfmode, sipgetheader, stopmonitor, testclient, 
txtcidname, vmauthenticate, voicemail, voicemailmain, wait, waitexten, 
waitforring, waitforsilence, while)

Surely you can come up with a name slightly more descriptive -- maybe 
idx?

Take pity on the next sod that has to plod through your dialplan. The 
millisecond you spend typing a more meaningful name will be returned to 
you (or your employer) a millionfold.

 - Original Message 
 From: Tilghman Lesher [EMAIL PROTECTED]
 To: Asterisk Users Mailing List - Non-Commercial Discussion 
 asterisk-users@lists.digium.com
 Sent: Friday, July 11, 2008 7:36:54 AM
 Subject: Re: [asterisk-users] Asterisk as an IVR solution

 On Friday 11 July 2008 09:22:25 Douglas Garstang wrote:
 Yes, and by doing that your compounding the fact that all your variables
 are global.

 No, his variables are local to the channel he's using.  Global variables are
 a completely different beast.

 -- 
 Tilghman

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 AstriCon 2008 - September 22 - 25 Phoenix, Arizona
 Register Now: http://www.astricon.net

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users





Thanks in advance,

Steve Edwards  [EMAIL PROTECTED]  Voice: +1-760-468-3867 PST
Newline Fax: +1-760-731-3000

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Tilghman Lesher
On Friday 11 July 2008 09:40:55 Douglas Garstang wrote:
 Well, a macro is the closest thing the dial plan has to a subroutine, and
 without that, we might as well be programming in Assembler (no subroutines,
 local variables, lots of goto's... sound familiar?).

I've mentioned Gosub at least twice before in this thread, which implements a
subroutine.

-- 
Tilghman

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Douglas Garstang
A subroutine with arguments?


- Original Message 
From: Tilghman Lesher [EMAIL PROTECTED]
To: Asterisk Users Mailing List - Non-Commercial Discussion 
asterisk-users@lists.digium.com
Sent: Friday, July 11, 2008 8:58:46 AM
Subject: Re: [asterisk-users] Asterisk as an IVR solution

On Friday 11 July 2008 09:40:55 Douglas Garstang wrote:
 Well, a macro is the closest thing the dial plan has to a subroutine, and
 without that, we might as well be programming in Assembler (no subroutines,
 local variables, lots of goto's... sound familiar?).

I've mentioned Gosub at least twice before in this thread, which implements a
subroutine.

-- 
Tilghman

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users



  ___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Douglas Garstang
Fine, I'll call it ${LoopVariable} then... how's that going to fix the problem?


- Original Message 
From: Steve Edwards [EMAIL PROTECTED]
To: Asterisk Users Mailing List - Non-Commercial Discussion 
asterisk-users@lists.digium.com
Sent: Friday, July 11, 2008 8:43:47 AM
Subject: Re: [asterisk-users] Asterisk as an IVR solution

On Fri, 11 Jul 2008, Douglas Garstang wrote:

 Ugh. Yes, the variables are local to the current channel. However, they 
 are global to the entire dial plan within the current channel. I have 
 stepped on myself many times because I've had a loop counter called $i 
 for example, jumped somewhere else within that loop, reused the same 
 variable name, $i, and screwed up my logic.

Ugh indeed. While I sympathize with your local/global name space issues, 
you lose credibility with your false economy.

IMNSHO, anybody who uses a single [common] letter for a variable deserves 
a bump in the temperature when they reach their final resting place :)

For example, out of the 157 applications on one of my Asterisk servers, 76 
contain the letter l.

(absolutetimeout, adsiprog, agentcallbacklogin, agentlogin, 
agentmonitoroutgoing, agi, alarmreceiver, appendcdruserfield, 
authenticate, changemonitor, chanisavail, congestion, datetime, deadagi, 
dial, dictate, digittimeout, directory, disa, dundilookup, eagi, endwhile, 
execif, execiftime, externalivr, festival, getcpeid, gosubif, gotoif, 
gotoiftime, hasnewvoicemail, hasvoicemail, iax2provision, ices, importvar, 
lookupblacklist, lookupcidname, macroexit, macroif, mailboxexists, 
meetmeadmin, milliwatt, mixmonitor, monitor, pickup, privacymanager, 
readfile, realtime, realtimeupdate, responsetimeout, retrydial, ringing, 
saydigits, sayphonetic, sayunixtime, sendimage, setcallerid, 
setcdruserfield, setcidname, setcidnum, setrdnis, settransfercapabilit, 
sipaddheader, sipdtmfmode, sipgetheader, stopmonitor, testclient, 
txtcidname, vmauthenticate, voicemail, voicemailmain, wait, waitexten, 
waitforring, waitforsilence, while)

Surely you can come up with a name slightly more descriptive -- maybe 
idx?

Take pity on the next sod that has to plod through your dialplan. The 
millisecond you spend typing a more meaningful name will be returned to 
you (or your employer) a millionfold.

 - Original Message 
 From: Tilghman Lesher [EMAIL PROTECTED]
 To: Asterisk Users Mailing List - Non-Commercial Discussion 
 asterisk-users@lists.digium.com
 Sent: Friday, July 11, 2008 7:36:54 AM
 Subject: Re: [asterisk-users] Asterisk as an IVR solution

 On Friday 11 July 2008 09:22:25 Douglas Garstang wrote:
 Yes, and by doing that your compounding the fact that all your variables
 are global.

 No, his variables are local to the channel he's using.  Global variables are
 a completely different beast.

 -- 
 Tilghman

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 AstriCon 2008 - September 22 - 25 Phoenix, Arizona
 Register Now: http://www.astricon.net

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users





Thanks in advance,

Steve Edwards  [EMAIL PROTECTED]  Voice: +1-760-468-3867 PST
Newline Fax: +1-760-731-3000

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users



  ___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Tilghman Lesher
On Friday 11 July 2008 12:07:37 Douglas Garstang wrote:
 A subroutine with arguments?

In 1.6, yes, or in the 1.4 backport, yes.

-- 
Tilghman

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Steve Edwards
 From: Steve Edwards [EMAIL PROTECTED]

 On Fri, 11 Jul 2008, Douglas Garstang wrote:

 Ugh. Yes, the variables are local to the current channel. However, they 
 are global to the entire dial plan within the current channel. I have 
 stepped on myself many times because I've had a loop counter called $i 
 for example, jumped somewhere else within that loop, reused the same 
 variable name, $i, and screwed up my logic.

 Ugh indeed. While I sympathize with your local/global name space issues, 
 you lose credibility with your false economy.

 IMNSHO, anybody who uses a single [common] letter for a variable 
 deserves a bump in the temperature when they reach their final resting 
 place :)

 Surely you can come up with a name slightly more descriptive -- maybe 
 idx?

 Take pity on the next sod that has to plod through your dialplan. The 
 millisecond you spend typing a more meaningful name will be returned 
 to you (or your employer) a millionfold.

On Fri, 11 Jul 2008, Douglas Garstang wrote:

 Fine, I'll call it ${LoopVariable} then... how's that going to fix the 
 problem?

It (obviously) doesn't. It just fixes the next guy's problem when he 
tries to read your dialplan -- as stated above.

I'm just suggesting better practices. Even examples should demonstrate 
best practices because they form the basis of some coders only source of 
knowledge.

Kind of like not top posting in a list where the posted etiquette is 
not top posting ;)

Thanks in advance,

Steve Edwards  [EMAIL PROTECTED]  Voice: +1-760-468-3867 PST
Newline Fax: +1-760-731-3000

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Al Baker
Could you clarify how you end up with 1.4 Backport ?
If you go to DIGIUM and download 1.4 do you have a backport 1.4 or is 
there
a super-secret-non-more-secret-archive one would get it from ?
I have never really understood this.
Thank You

Tilghman Lesher wrote:
 On Friday 11 July 2008 12:07:37 Douglas Garstang wrote:
   
 A subroutine with arguments?
 

 In 1.6, yes, or in the 1.4 backport, yes.

   

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Al Baker


Douglas Garstang wrote:
 Well, a macro is the closest thing the dial plan has to a subroutine, 
 and without that, we might as well be programming in Assembler (no 
 subroutines, local variables, lots of goto's... sound familiar?).

 Doug.

 - Original Message 
 From: Tilghman Lesher [EMAIL PROTECTED]
 To: Asterisk Users Mailing List - Non-Commercial Discussion 
 asterisk-users@lists.digium.com
 Sent: Friday, July 11, 2008 7:20:40 AM
 Subject: Re: [asterisk-users] Asterisk as an IVR solution

 On Friday 11 July 2008 01:28:34 Douglas Garstang wrote:
  Well I can tell you that it makes a difficult programming 
 environment, just
  a little more difficult. It means I can't implement a menu as a single
  reusable piece of code inside a macro.

 That's the point.  A Macro is NOT a subroutine.  It's like saying that you
 can't effectively hammer a nail with a screwdriver, and therefore you 
 think
 the screwdriver has a known problem.  There's nothing wrong with the
 screwdriver; it simply is the wrong tool for the job.

I must somewhat disagree with you on this.
1) A MACRO could reasonably viewed as the Current Context, so if the 
jumping/branching from extension to extension that takes place in other 
contexts, it would if fact be quite reasonable and expected that this 
would happen in a MACRO.
2) As SUBROUTINES did not come standard until 1.6, it might be 
reasonably stated that no appropriate tool existed until 1.6,
and since good programming practice uses subroutines, and a MACRO did 
not work like subroutine, even though it LOOKS like one, people are not 
fully happy that the closest tool they had, did not do the job

Just a thought , no flame intended or implied.

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Al Baker
Thank You - clears up a LOT I did not fully grasp

Tilghman Lesher wrote:
 On Friday 11 July 2008 01:05:22 Al Baker wrote:
   
 Tilghman Lesher wrote:
 
 On Thursday 10 July 2008 19:13:50 Douglas Garstang wrote:
   
 It's a known problem.

 If you call Background() in a macro, then Asterisk will look for the
 extensions to jump to in the CALLING Macro/context and NOT the Macro
 that the Background() app was called in.
 
 I wouldn't call it a known problem.  It works precisely as it was
 designed to work.  It may not work the way that you want it to, but it
 works like a Macro: an independent set of instructions, with
 substitution, that acts as if it were invoked inline with the calling
 location.  That is why Background will match in the context of the
 calling location: it acts like it never left that original context (and,
 in a way, it really didn't).

 Subroutines are a different beast, and they are available with the Gosub/
 Return set of routines in app_stack.so.
   
 SO does that mean that if he used BACKGROUND is a SubRoutine  he would
 get the correct or desired action , from his point of view? It would
 jump to the 1 Extension in the SUBROUTINE ?
 

 Yes, if he used Background within a Gosub, it would behave the way that he
 expects.

   

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-11 Thread Tilghman Lesher
On Friday 11 July 2008 21:24:10 Al Baker wrote:
 Tilghman Lesher wrote:
  On Friday 11 July 2008 12:07:37 Douglas Garstang wrote:
  A subroutine with arguments?
 
  In 1.6, yes, or in the 1.4 backport, yes.

 Could you clarify how you end up with 1.4 Backport ?
 If you go to DIGIUM and download 1.4 do you have a backport 1.4 or is
 there
 a super-secret-non-more-secret-archive one would get it from ?
 I have never really understood this.

The backport exists on svncommunity:

http://svncommunity.digium.com/view/app_stack/1.4/

I also have two other repositories on svncommunity, both for backports:

http://svncommunity.digium.com/view/func_odbc/1.4/
http://svncommunity.digium.com/view/tilghman/branches/1.4/

-- 
Tilghman

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-10 Thread Steve Totaro
On Thu, Jul 10, 2008 at 1:25 PM, Mark Carpenter [EMAIL PROTECTED] wrote:

 Hi.
 We are building an application that will provide users with the ability to
 call in and report an absence. The caller will have to validate themselves
 and the call tree will be dynamic, based on data in a MySQL database. We
 will have many customers, each calling a separate phone number, each having
 a different call tree. New customers will be added regularly and we do not
 want a solution that requires extensive programming each time (the call
 trees are different in subtle ways from each other).

 Is Asterisk a great solution for this? If not do you know what would? If
 so, we need someone to help us set it up, can you suggest someone?

 Thanks in advance. Best.

 Mark


Asterisk certainly is a great solution for this.  If you find you need or
want extra flexibility,  the external IVR app.
http://www.voip-info.org/wiki/index.php?page=Asterisk+cmd+ExternalIVR

Thanks,
Steve Totaro
___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-10 Thread Leotis buchanan
Yes,asterisk can do that

On Thu, Jul 10, 2008 at 12:25 PM, Mark Carpenter [EMAIL PROTECTED] wrote:

 Hi.
 We are building an application that will provide users with the ability to
 call in and report an absence. The caller will have to validate themselves
 and the call tree will be dynamic, based on data in a MySQL database. We
 will have many customers, each calling a separate phone number, each having
 a different call tree. New customers will be added regularly and we do not
 want a solution that requires extensive programming each time (the call
 trees are different in subtle ways from each other).

 Is Asterisk a great solution for this? If not do you know what would? If
 so, we need someone to help us set it up, can you suggest someone?

 Thanks in advance. Best.

 Mark


 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 AstriCon 2008 - September 22 - 25 Phoenix, Arizona
 Register Now: http://www.astricon.net

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users




-- 
Leotis Buchanan
Manager/Electronic Design Systems Engineer
Exterbox.com
___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-10 Thread Leotis buchanan
Hey,

I am doing a similar project , which we will be integrating mysql db and a
ivr, maybe we can work on this together since we will be sharing components.
This should save us both some time.



On Thu, Jul 10, 2008 at 12:25 PM, Mark Carpenter [EMAIL PROTECTED] wrote:

 Hi.
 We are building an application that will provide users with the ability to
 call in and report an absence. The caller will have to validate themselves
 and the call tree will be dynamic, based on data in a MySQL database. We
 will have many customers, each calling a separate phone number, each having
 a different call tree. New customers will be added regularly and we do not
 want a solution that requires extensive programming each time (the call
 trees are different in subtle ways from each other).

 Is Asterisk a great solution for this? If not do you know what would? If
 so, we need someone to help us set it up, can you suggest someone?

 Thanks in advance. Best.

 Mark


 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 AstriCon 2008 - September 22 - 25 Phoenix, Arizona
 Register Now: http://www.astricon.net

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users




-- 
Leotis Buchanan
Manager/Electronic Design Systems Engineer
Exterbox.com
___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-10 Thread Douglas Garstang
Admittedly I have not used the ExternalIVR app. Is it any good?

I'm not sure I agree that Asterisk is GOOD for building IVR's. Sure, it can do 
it, but boy it is UGLY. There's also the fact that you can't call Backgound() 
in a macro, which forces you to use Read() which won't accept a timeout of 1s. 
There's no DTMF background detection while playing SayDigits so you have to 
roll your own by calling an external AGI and concatenating sound files. Yuck. 
By the time you code in logic for handling timeouts and incorrect responses to 
menu's with all the gotos and what-not, it turns into a god aweful mess.

Sure, you can do it.

Doug.




- Original Message 
From: Steve Totaro [EMAIL PROTECTED]
To: Asterisk Users Mailing List - Non-Commercial Discussion 
asterisk-users@lists.digium.com
Sent: Thursday, July 10, 2008 10:37:55 AM
Subject: Re: [asterisk-users] Asterisk as an IVR solution




On Thu, Jul 10, 2008 at 1:25 PM, Mark Carpenter [EMAIL PROTECTED] wrote:

Hi.

We are building an application that will provide users with the ability to call 
in and report an absence. The caller will have to validate themselves and the 
call tree will be dynamic, based on data in a MySQL database. We will have many 
customers, each calling a separate phone number, each having a different call 
tree. New customers will be added regularly and we do not want a solution that 
requires extensive programming each time (the call trees are different in 
subtle ways from each other).

Is Asterisk a great solution for this? If not do you know what would? If so, we 
need someone to help us set it up, can you suggest someone?

Thanks in advance. Best.

Mark

Asterisk certainly is a great solution for this.  If you find you need or want 
extra flexibility,  the external IVR app.  
http://www.voip-info.org/wiki/index.php?page=Asterisk+cmd+ExternalIVR

Thanks,
Steve Totaro



  ___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-10 Thread MFH
 From what I can tell Read allows for a floating point input which uses 
ast_waitfordigit that accepts milliseconds as input.

Douglas Garstang wrote:
 Admittedly I have not used the ExternalIVR app. Is it any good?

 I'm not sure I agree that Asterisk is GOOD for building IVR's. Sure, 
 it can do it, but boy it is UGLY. There's also the fact that you can't 
 call Backgound() in a macro, which forces you to use Read() which 
 won't accept a timeout of 1s. There's no DTMF background detection 
 while playing SayDigits so you have to roll your own by calling an 
 external AGI and concatenating sound files. Yuck. By the time you code 
 in logic for handling timeouts and incorrect responses to menu's with 
 all the gotos and what-not, it turns into a god aweful mess.

 Sure, you can do it.

 Doug.



 - Original Message 
 From: Steve Totaro [EMAIL PROTECTED]
 To: Asterisk Users Mailing List - Non-Commercial Discussion 
 asterisk-users@lists.digium.com
 Sent: Thursday, July 10, 2008 10:37:55 AM
 Subject: Re: [asterisk-users] Asterisk as an IVR solution



 On Thu, Jul 10, 2008 at 1:25 PM, Mark Carpenter [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED] wrote:

 Hi.

 We are building an application that will provide users with the
 ability to call in and report an absence. The caller will have to
 validate themselves and the call tree will be dynamic, based on
 data in a MySQL database. We will have many customers, each
 calling a separate phone number, each having a different call
 tree. New customers will be added regularly and we do not want a
 solution that requires extensive programming each time (the call
 trees are different in subtle ways from each other).

 Is Asterisk a great solution for this? If not do you know what
 would? If so, we need someone to help us set it up, can you
 suggest someone?

 Thanks in advance. Best.

 Mark


 Asterisk certainly is a great solution for this.  If you find you need 
 or want extra flexibility,  the external IVR app.  
 http://www.voip-info.org/wiki/index.php?page=Asterisk+cmd+ExternalIVR

 Thanks,
 Steve Totaro

 

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 AstriCon 2008 - September 22 - 25 Phoenix, Arizona
 Register Now: http://www.astricon.net

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-10 Thread Douglas Garstang
Don't know about Asterisk 1.4, but in Asterisk 1.2 it expects the input in 
seconds. If you try and use 0, it seems to drop back to a default of 5s.


- Original Message 
From: MFH [EMAIL PROTECTED]
To: Asterisk Users Mailing List - Non-Commercial Discussion 
asterisk-users@lists.digium.com
Sent: Thursday, July 10, 2008 12:37:31 PM
Subject: Re: [asterisk-users] Asterisk as an IVR solution

From what I can tell Read allows for a floating point input which uses 
ast_waitfordigit that accepts milliseconds as input.

Douglas Garstang wrote:
 Admittedly I have not used the ExternalIVR app. Is it any good?

 I'm not sure I agree that Asterisk is GOOD for building IVR's. Sure, 
 it can do it, but boy it is UGLY. There's also the fact that you can't 
 call Backgound() in a macro, which forces you to use Read() which 
 won't accept a timeout of 1s. There's no DTMF background detection 
 while playing SayDigits so you have to roll your own by calling an 
 external AGI and concatenating sound files. Yuck. By the time you code 
 in logic for handling timeouts and incorrect responses to menu's with 
 all the gotos and what-not, it turns into a god aweful mess.

 Sure, you can do it.

 Doug.



 - Original Message 
 From: Steve Totaro [EMAIL PROTECTED]
 To: Asterisk Users Mailing List - Non-Commercial Discussion 
 asterisk-users@lists.digium.com
 Sent: Thursday, July 10, 2008 10:37:55 AM
 Subject: Re: [asterisk-users] Asterisk as an IVR solution



 On Thu, Jul 10, 2008 at 1:25 PM, Mark Carpenter [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED] wrote:

 Hi.

 We are building an application that will provide users with the
 ability to call in and report an absence. The caller will have to
 validate themselves and the call tree will be dynamic, based on
 data in a MySQL database. We will have many customers, each
 calling a separate phone number, each having a different call
 tree. New customers will be added regularly and we do not want a
 solution that requires extensive programming each time (the call
 trees are different in subtle ways from each other).

 Is Asterisk a great solution for this? If not do you know what
 would? If so, we need someone to help us set it up, can you
 suggest someone?

 Thanks in advance. Best.

 Mark


 Asterisk certainly is a great solution for this.  If you find you need 
 or want extra flexibility,  the external IVR app.  
 http://www.voip-info.org/wiki/index.php?page=Asterisk+cmd+ExternalIVR

 Thanks,
 Steve Totaro

 

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 AstriCon 2008 - September 22 - 25 Phoenix, Arizona
 Register Now: http://www.astricon.net

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users



  ___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-10 Thread Al Baker
Why can't you call Background() from a MACRO ?
Isn't is just an Application like any other ?
Curious minds want to know !

Quote There's also the fact that you can't
  call Backgound() in a macro,

Douglas Garstang wrote:
 Don't know about Asterisk 1.4, but in Asterisk 1.2 it expects the 
 input in seconds. If you try and use 0, it seems to drop back to a 
 default of 5s.

 - Original Message 
 From: MFH [EMAIL PROTECTED]
 To: Asterisk Users Mailing List - Non-Commercial Discussion 
 asterisk-users@lists.digium.com
 Sent: Thursday, July 10, 2008 12:37:31 PM
 Subject: Re: [asterisk-users] Asterisk as an IVR solution

 From what I can tell Read allows for a floating point input which uses
 ast_waitfordigit that accepts milliseconds as input.

 Douglas Garstang wrote:
  Admittedly I have not used the ExternalIVR app. Is it any good?
 
  I'm not sure I agree that Asterisk is GOOD for building IVR's. Sure,
  it can do it, but boy it is UGLY. There's also the fact that you can't
  call Backgound() in a macro, which forces you to use Read() which
  won't accept a timeout of 1s. There's no DTMF background detection
  while playing SayDigits so you have to roll your own by calling an
  external AGI and concatenating sound files. Yuck. By the time you code
  in logic for handling timeouts and incorrect responses to menu's with
  all the gotos and what-not, it turns into a god aweful mess.
 
  Sure, you can do it.
 
  Doug.
 
 
 
  - Original Message 
  From: Steve Totaro [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED]
  To: Asterisk Users Mailing List - Non-Commercial Discussion
  asterisk-users@lists.digium.com 
 mailto:asterisk-users@lists.digium.com
  Sent: Thursday, July 10, 2008 10:37:55 AM
  Subject: Re: [asterisk-users] Asterisk as an IVR solution
 
 
 
  On Thu, Jul 10, 2008 at 1:25 PM, Mark Carpenter [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED]
  mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote:
 
 Hi.
 
 We are building an application that will provide users with the
 ability to call in and report an absence. The caller will have to
 validate themselves and the call tree will be dynamic, based on
 data in a MySQL database. We will have many customers, each
 calling a separate phone number, each having a different call
 tree. New customers will be added regularly and we do not want a
 solution that requires extensive programming each time (the call
 trees are different in subtle ways from each other).
 
 Is Asterisk a great solution for this? If not do you know what
 would? If so, we need someone to help us set it up, can you
 suggest someone?
 
 Thanks in advance. Best.
 
 Mark
 
 
  Asterisk certainly is a great solution for this.  If you find you need
  or want extra flexibility,  the external IVR app. 
  http://www.voip-info.org/wiki/index.php?page=Asterisk+cmd+ExternalIVR
 
  Thanks,
  Steve Totaro
 
  
 
  ___
  -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 
  AstriCon 2008 - September 22 - 25 Phoenix, Arizona
  Register Now: http://www.astricon.net
 
  asterisk-users mailing list
  To UNSUBSCRIBE or update options visit:
 http://lists.digium.com/mailman/listinfo/asterisk-users

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 AstriCon 2008 - September 22 - 25 Phoenix, Arizona
 Register Now: http://www.astricon.net

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

 

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 AstriCon 2008 - September 22 - 25 Phoenix, Arizona
 Register Now: http://www.astricon.net

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-10 Thread Al Baker
Yes , you could easily do this with asterisk.
If you have formal specs for this project, I would be interested in exactly
what you are trying to do. Email me off-line.

Steve Totaro wrote:


 On Thu, Jul 10, 2008 at 1:25 PM, Mark Carpenter [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED] wrote:

 Hi.

 We are building an application that will provide users with the
 ability to call in and report an absence. The caller will have to
 validate themselves and the call tree will be dynamic, based on
 data in a MySQL database. We will have many customers, each
 calling a separate phone number, each having a different call
 tree. New customers will be added regularly and we do not want a
 solution that requires extensive programming each time (the call
 trees are different in subtle ways from each other).

 Is Asterisk a great solution for this? If not do you know what
 would? If so, we need someone to help us set it up, can you
 suggest someone?

 Thanks in advance. Best.

 Mark


 Asterisk certainly is a great solution for this.  If you find you need 
 or want extra flexibility,  the external IVR app.  
 http://www.voip-info.org/wiki/index.php?page=Asterisk+cmd+ExternalIVR

 Thanks,
 Steve Totaro
 

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 AstriCon 2008 - September 22 - 25 Phoenix, Arizona
 Register Now: http://www.astricon.net

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-10 Thread Douglas Garstang
It's a known problem.

If you call Background() in a macro, then Asterisk will look for the extensions 
to jump to in the CALLING Macro/context and NOT the Macro that the Background() 
app was called in.

Eg:

[macro-DoSomething]
exten = s,1,Background(Prompt)
exten = 1,1,NoOP()

[context1]
exten = s,1,Macro(DoSomething)

If you press 1, Asterisk will look for an extension '1' in the context 
'context1', NOT the 'DoSomething' macro.

Doug.



- Original Message 
From: Al Baker [EMAIL PROTECTED]
To: Asterisk Users Mailing List - Non-Commercial Discussion 
asterisk-users@lists.digium.com
Sent: Thursday, July 10, 2008 4:50:19 PM
Subject: Re: [asterisk-users] Asterisk as an IVR solution

Why can't you call Background() from a MACRO ?
Isn't is just an Application like any other ?
Curious minds want to know !

Quote There's also the fact that you can't
 call Backgound() in a macro,

Douglas Garstang wrote:
 Don't know about Asterisk 1.4, but in Asterisk 1.2 it expects the 
 input in seconds. If you try and use 0, it seems to drop back to a 
 default of 5s.

 - Original Message 
 From: MFH [EMAIL PROTECTED]
 To: Asterisk Users Mailing List - Non-Commercial Discussion 
 asterisk-users@lists.digium.com
 Sent: Thursday, July 10, 2008 12:37:31 PM
 Subject: Re: [asterisk-users] Asterisk as an IVR solution

 From what I can tell Read allows for a floating point input which uses
 ast_waitfordigit that accepts milliseconds as input.

 Douglas Garstang wrote:
  Admittedly I have not used the ExternalIVR app. Is it any good?
 
  I'm not sure I agree that Asterisk is GOOD for building IVR's. Sure,
  it can do it, but boy it is UGLY. There's also the fact that you can't
  call Backgound() in a macro, which forces you to use Read() which
  won't accept a timeout of 1s. There's no DTMF background detection
  while playing SayDigits so you have to roll your own by calling an
  external AGI and concatenating sound files. Yuck. By the time you code
  in logic for handling timeouts and incorrect responses to menu's with
  all the gotos and what-not, it turns into a god aweful mess.
 
  Sure, you can do it.
 
  Doug.
 
 
 
  - Original Message 
  From: Steve Totaro [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED]
  To: Asterisk Users Mailing List - Non-Commercial Discussion
  asterisk-users@lists.digium.com 
 mailto:asterisk-users@lists.digium.com
  Sent: Thursday, July 10, 2008 10:37:55 AM
  Subject: Re: [asterisk-users] Asterisk as an IVR solution
 
 
 
  On Thu, Jul 10, 2008 at 1:25 PM, Mark Carpenter [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED]
  mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote:
 
 Hi.
 
 We are building an application that will provide users with the
 ability to call in and report an absence. The caller will have to
 validate themselves and the call tree will be dynamic, based on
 data in a MySQL database. We will have many customers, each
 calling a separate phone number, each having a different call
 tree. New customers will be added regularly and we do not want a
 solution that requires extensive programming each time (the call
 trees are different in subtle ways from each other).
 
 Is Asterisk a great solution for this? If not do you know what
 would? If so, we need someone to help us set it up, can you
 suggest someone?
 
 Thanks in advance. Best.
 
 Mark
 
 
  Asterisk certainly is a great solution for this.  If you find you need
  or want extra flexibility,  the external IVR app. 
  http://www.voip-info.org/wiki/index.php?page=Asterisk+cmd+ExternalIVR
 
  Thanks,
  Steve Totaro
 
  
 
  ___
  -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 
  AstriCon 2008 - September 22 - 25 Phoenix, Arizona
  Register Now: http://www.astricon.net
 
  asterisk-users mailing list
  To UNSUBSCRIBE or update options visit:
 http://lists.digium.com/mailman/listinfo/asterisk-users

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 AstriCon 2008 - September 22 - 25 Phoenix, Arizona
 Register Now: http://www.astricon.net

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users

 

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 AstriCon 2008 - September 22 - 25 Phoenix, Arizona
 Register Now: http://www.astricon.net

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona

Re: [asterisk-users] Asterisk as an IVR solution

2008-07-10 Thread Tilghman Lesher
On Thursday 10 July 2008 19:13:50 Douglas Garstang wrote:
 It's a known problem.

 If you call Background() in a macro, then Asterisk will look for the
 extensions to jump to in the CALLING Macro/context and NOT the Macro that
 the Background() app was called in.

I wouldn't call it a known problem.  It works precisely as it was designed to
work.  It may not work the way that you want it to, but it works like a Macro:
an independent set of instructions, with substitution, that acts as if it were
invoked inline with the calling location.  That is why Background will match
in the context of the calling location: it acts like it never left that
original context (and, in a way, it really didn't).

Subroutines are a different beast, and they are available with the Gosub/
Return set of routines in app_stack.so.

-- 
Tilghman

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk as an IVR solution

2008-07-10 Thread Steve Totaro
On Thu, Jul 10, 2008 at 9:07 PM, Tilghman Lesher 
[EMAIL PROTECTED] wrote:

 On Thursday 10 July 2008 19:13:50 Douglas Garstang wrote:
  It's a known problem.
 
  If you call Background() in a macro, then Asterisk will look for the
  extensions to jump to in the CALLING Macro/context and NOT the Macro that
  the Background() app was called in.

 I wouldn't call it a known problem.  It works precisely as it was designed
 to
 work.  It may not work the way that you want it to, but it works like a
 Macro:
 an independent set of instructions, with substitution, that acts as if it
 were
 invoked inline with the calling location.  That is why Background will
 match
 in the context of the calling location: it acts like it never left that
 original context (and, in a way, it really didn't).

 Subroutines are a different beast, and they are available with the Gosub/
 Return set of routines in app_stack.so.

 --
 Tilghman



See  this thread for info on  who  paid for ExternalIVR, who uses(used?) it
and some history.
http://www.asteriskguru.com/archives/image-vp255203.html


Thanks,
Steve Totaro
___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users