[Asterisk-Users] Background() problem (with queue(), etc.)

Adam Goryachev mailinglists at websitemanagers.com.au
Tue May 17 08:12:34 MST 2005


On Tue, 2005-05-17 at 11:35 +0100, Seb Auriol wrote:
> Hi all,
> 
> I want to be able to play messages while someone is in a queue.  From
> the documentation the Background() command should work:  From wiki:
> """Starts playing a given sound file, but immediately returns,
> permitting the sound file to play in the background while the next
> commands (if any) execute."""  But in my example below, it does not
> return until it has finished playing the prompt.  (Even if one puts a
> NoOp at priority 9, it doesn't execute until vm-intro has finished
> playing.)  This is no use to me, as I want to queue them immediately,
> and use Background to play an intro and then sales messages with music
> in the background (this is already mixed in one sound file).  Even if
> I do some ugly hack by changing  all the "queue-…" messages in
> queues.conf (all except one would be a blank file) and then using
> these, people don't really get put into the queue until these messages
> end.
> 
> Relevant entries from extensions.conf: 
> ... 
> exten => 2401,4,Ringing  
> exten => 2401,5,Wait,2 
> exten => 2401,6,Answer 
> exten => 2401,7,SetMusicOnHold(default) 
> exten => 2401,8,Background(vm-intro) ; Use this prompt just for
> testing... 
> exten => 2401,9,Queue(q1)
> 
> Anybody think of a way of solving this problem?

Yes, the obvious solution.... convert vm-intro to a mp3 file, and put it
in a directory by itself. Then you can setup musiconhold.conf with a
class pointing to this dir, fix up your step 7 as appropriate, and you
are all done.

PS, Background simply listens for DTMF while playing the file, but it
won't continue in the dialplan until after the file is finished. The
queue function is designed to play the file while at the same time,
calling agents to get the call delivered/answered.

Regards,
Adam
-- 
 -- 
Adam Goryachev
Website Managers
Ph:  +61 2 9345 4395                        adam at websitemanagers.com.au
Fax: +61 2 9345 4396                        www.websitemanagers.com.au




More information about the asterisk-users mailing list