<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div>
<p>im trying to start a conference between a list of users, play a list of audio files and then close the conference. im using the event_socket_library in c++ and am doing the following:</p>
<pre><code><span>conference </span><span><uuid></span><span> dial user</span><span>/</span><span>user1
conference </span><span><uuid></span><span> dial user</span><span>/</span><span>user2
conference </span><span><uuid></span><span> dial user</span><span>/</span><span>user3
in a loop</span><span>:</span><span>
conference play </span><span><path_to_audio_file><br>conference hup all //will skip the stream and end the call, but i need to wait for the last playback to end.<br></span></code></pre>
<p>how do i know when the last file was played so i can close the conference? is there a way to do it programmatically? a dialplan script taking the users and the files and the conference name as parameters, starting and closing the conference automatically
would be fine, too. doing this im not sure on how to play a file to a conference and closing it.</p>
<p>i tried something like this: but its not playing the file and not closing the conference</p>
<pre><code><span><</span><span>extension name</span><span>=</span><span>"extension-playconf"</span><span>></span><span>
</span><span><</span><span>condition field</span><span>=</span><span>"destination_number"</span><span> expression</span><span>=</span><span>"^playconf$"</span><span>></span><span>
</span><span><</span><span>action application</span><span>=</span><span>"answer"</span><span>/></span><span>
</span><span><</span><span>action application</span><span>=</span><span>"conference_set_auto_outcall"</span><span> data</span><span>=</span><span>"user/1001"</span><span>/></span><span>
</span><span><</span><span>action application</span><span>=</span><span>"conference_set_auto_outcall"</span><span> data</span><span>=</span><span>"user/1002"</span><span>/></span><span>
</span><span><</span><span>action application</span><span>=</span><span>"playback"</span><span> data</span><span>=</span><span>"/home/freeswitch/regioaudio/audio.wav"</span><span>/></span><span>
</span><span><</span><span>action application</span><span>=</span><span>"conference"</span><span> data</span><span>=</span><span>"hup all"</span><span>></span><span>
</span><span></</span><span>condition</span><span>></span><span>
</span><span></</span><span>extension</span><span>></span></code></pre>
</div>
</body>
</html>