[Freeswitch-dev] Couple of questions about esl in C

adam harris admharris at gmx.com
Thu Oct 20 05:02:43 MSD 2011


I want to try one more thing to see if it solves my problem

int response_timeout = (10 * 1000);
esl_status_t status;
status = esl_recv_event_timed(call_info->global_handle, response_timeout, 0, xxxxx); 

The note for the last paramter is:
\param[out] save_event If this is not NULL, will return the event received

What type of varible do I need to pass as the paramter and where will the return data go and how to access it.


I have noticed this channel variable
Application-Response: FILE%20PLAYED
which possibly might indicate playback completion?


> ----- Original Message -----
> From: Michael Collins
> Sent: 10/19/11 10:30 PM
> To: freeswitch-dev at lists.freeswitch.org
> Subject: Re: [Freeswitch-dev] Couple of questions about esl in C
> 
> On Wed, Oct 19, 2011 at 12:21 PM, adam harris <admharris at gmx.com> wrote:
> 
> > A few questions about esl in C
> >
> > 1, After sending api playback command I want to wait until the file is done
> > playing. How do I do this is C
> 
> 
> > 2, Whats the proper way to use esl_recv_event_timed and esl_recv_even I
> > tried it like this esl_recv_event_timed(call_info->global_handle, 10, 0,
> > NULL); but that printed the complete event on screen. I want to do this in a
> > while loop to check for event-name
> >
> > Would you mind putting some code snippets here or in
> pastebin.freeswitch.org?
> -MC




Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-dev mailing list