[asterisk-users] play audio file within an active call

Vieri rentorbuy at yahoo.com
Tue Sep 29 04:20:13 CDT 2009


--- On Tue, 9/29/09, Benny Amorsen <benny+usenet at amorsen.dk> wrote:

> > I'm wondering if someone can share their thoughts on
> how to implement a system that periodically checks active
> channels which have been up for more than X minutes and
> plays/injects a sound file. The idea is to simply warn users
> that they've been on the phone for quite a while and maybe
> they should consider hanging up. If the call stays up for
> more than Y minutes, it is dropped automatically
> (softhangup).
> >
> > What's the simplest approach to playing a sound file
> within an active channel?
> 
> I think you should be able to do this with ChanSpy and the
> whisper
> option. However, Asterisk already has a facility for this.
> This is from
> core show application Dial
> 
>     L(x[:y][:z]) - Limit the call to 'x' ms. Play
> a warning when 'y' ms are
>            left. Repeat
> the warning every 'z' ms. The following special
>            variables can
> be used with this option:
>            *
> LIMIT_PLAYAUDIO_CALLER   yes|no (default
> yes)
>                
>                
>       Play sounds to the caller.
>            *
> LIMIT_PLAYAUDIO_CALLEE   yes|no
>                
>                
>       Play sounds to the callee.
>            *
> LIMIT_TIMEOUT_FILE       File to
> play when time is up.
>            *
> LIMIT_CONNECT_FILE       File to
> play when call begins.
>            *
> LIMIT_WARNING_FILE       File to
> play as warning if 'y' is defined.
>                
>                
>       The default is to say the time
> remaining.

Benny,
thanks a lot. Will try that out.

Vieri



      



More information about the asterisk-users mailing list