[Freeswitch-users] Call screen for call to multiple endpoints not hanging up other endpoints on ANSWER
Robert Hadley
robert.hadley at teotech.com
Fri Sep 14 22:06:08 MSD 2012
I am using call screen feature and it works great for calls to single endpoints. However when call bridges to multiple endpoints the other endpoints continue to ring after one endpoint is answered. They are hungup on the accept/reject, but they should be hungup on answer.
These are the variables I am setting up before call_screen:
switch_channel_set_variable(channel, "ignore_early_media", "true");
switch_channel_set_variable(channel, "send_silence_when_idle", "10000"); // Eliminates initial white noise
p = switch_channel_get_variable(channel, "caller_id_number");
s = switch_channel_get_variable(channel, "uuid");
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "screen_call: caller_id_number='%s', variable_uuid='%s'\n", p, s);
switch_snprintf(q, 256, "/tmp/%s-%s-name.wav", p, s);
switch_channel_set_variable(channel, "call_screen_filename", q);
switch_channel_set_variable(channel, "group_confirm_key", "exec");
switch_core_session_execute_application(session, "answer", NULL);
switch_core_session_execute_application(session, "sleep", "1000");
switch_snprintf(r, 256, "callscreen_record_name,%s", dn);
switch_core_session_execute_application(session, "phrase", r);
switch_core_session_execute_application(session, "playback", "tone_stream://%(500, 0, 640)");
switch_channel_set_variable(channel, "playback_terminators", "#*0123456789");
switch_snprintf(r, 256, "%s 7 200 2", q);
switch_core_session_execute_application(session, "record", r);
switch_core_session_execute_application(session, "set", "ringback=${hold_music}");
switch_core_session_execute_application(session, "set", "transfer_ringback=${hold_music}");
switch_channel_set_variable(channel, "group_confirm_key", "exec");
switch_channel_set_variable(channel, "group_confirm_cancel_timeout", "60");
switch_channel_set_variable(channel, "origination_cancel_key", "2");
switch_channel_set_variable(channel, "group_confirm_read_timeout", "60");
switch_channel_set_variable(channel, "group_confirm_error_file", "/opt/teoswitch/lang/en/vm/vm-goodbye.wav");
switch_channel_set_variable(channel, "fail_on_single_reject", "true");
switch_channel_set_variable(channel, "continue_on_fail", "true");
switch_channel_set_variable(channel, "call_timeout", "60");
p = switch_channel_get_variable(channel, "uuid");
switch_snprintf(r, 256, "callscreen %s %s", dn, p);
switch_channel_set_variable(channel, "group_confirm_file", r);
Thanks,
Robert Hadley
Software Engineer
[Description: Description: Teo Logos (R)]
Teo, formerly Tone Commander Systems
UC 425.349.1045
WEB www.teotech.com<http://www.teotech.com/>
CONNECT WITH US Facebook<http://facebook.com/TeoUC> | Twitter<http://twitter.com/TeoTechUC> | YouTube<http://youtube.com/TeoMedia>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20120914/72879612/attachment-0001.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.png
Type: image/png
Size: 4457 bytes
Desc: image001.png
Url : http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20120914/72879612/attachment-0001.png
Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users
mailing list