I have an application that needs to vary the menu choices available based upon the availability of an external resource at a given time. What I have in mind is a system that can uplink a user to one of many different satellites. Due to the nature of orbital mechanics a satellite may be out of range at any given time. I only want to present a menu of available satellites. I can query an external program for a list of available satellites, but how can I use that list to present menu options for selection? What's the best way of doing this? Does anyone know of similar examples? Thanks, Eric -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20090413/08be6735/attachment-0001.htm
On Mon, 13 Apr 2009, Eric Fort wrote:> I have an application that needs to vary the menu choices available > based upon the availability of an external resource at a given time. > What I have in mind is a system that can uplink a user to one of many > different satellites. Due to the nature of orbital mechanics a > satellite may be out of range at any given time. I only want to present > a menu of available satellites. I can query an external program for a > list of available satellites, but how can I use that list to present > menu options for selection? What's the best way of doing this? Does > anyone know of similar examples?If availability is defined purely by time, Asterisk has an IFTIME function available in the dialplan. If availability is defined by a "ping," write a daemon to ping the birds that should be in view and update that status in a database. When a call is processed, call an AGI that queries the database. Depending on what your needs are, either have the AGI set a series of channel variables to be processed by the dialplan or have the AGI present the options and accept the caller's choice. I've done both. My current project is a third party verification system. Dozens of channel variables (STEP-x-PROMPT, STEP-x-RETRY-PROMPT, STEP-x-MAX-LENGTH, etc.) are set in an AGI based on the DNIS. The channel variables then control processing in an AEL "while" loop. Thanks in advance, ------------------------------------------------------------------------ Steve Edwards sedwards at sedwards.com Voice: +1-760-468-3867 PST Newline Fax: +1-760-731-3000
hi you can use AGI or a database internal or external then if you know all the satellites and are a few you can if(${SAT1}=1) playback(SAT1) if(${SAT2}=1) playback(SAT2) . . . or you can use an agi David 2009/4/14 Eric Fort <eric.fort at gmail.com>> I have an application that needs to vary the menu choices available based > upon the availability of an external resource at a given time. What I have > in mind is a system that can uplink a user to one of many different > satellites. Due to the nature of orbital mechanics a satellite may be out > of range at any given time. I only want to present a menu of available > satellites. I can query an external program for a list of available > satellites, but how can I use that list to present menu options for > selection? What's the best way of doing this? Does anyone know of similar > examples? > > Thanks, > > Eric > > _______________________________________________ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users >-- (\__/) (='.'=)This is Bunny. Copy and paste bunny into your (")_(")signature to help him gain world domination. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20090414/a90dd225/attachment.htm