invoso.com Report post Posted 11/13/2014 11:42 AM We have problems with play prompts after terminating one call leg. We are recording call using: set vg = CreateObject("vgServices.CommandLink")vg.Admin_TraceLogAdd $RV[Conf_LineId_1], 0, "rec_2lines $RV[session_id] call"strRet = vg.Record_2Lines_Start($RV[Conf_LineId_1], $RV[Conf_LineId_1], $RV[Conf_LineId_2], "C:\callrecord\$RV[session_id].wav", "")vg.Admin_TraceLogAdd $RV[Conf_LineId_1], 0, "rec_2lines $RV[session_id] returned"vg.Run_ResultReturn $RV[Conf_LineId_1], "success"set vg = Nothing during call in prompt empty Capture Entered Module (until end of call) we have an option (0) to follow to voice questionnaire. to follow to questionnaire we use disconnecting second leg module: set vg = CreateObject("vgServices.CommandLink")vg.Bridge_Disconnect $RV_LINEID, $RV[Conf_LineId_2]vg.Line_Hangup $RV[Conf_LineId_2]vg.Run_ResultReturn $RV_LINEID, "success"set vg = Nothing then we skip to next script but this not playing prompt in first play module. I think its connected with recording function. In attached log file call on second channel. vg not playing 122433.625 7 4 2 state [ankieta_intro] Playing wav (manager11\ankieta_intro98.wav) but next 122433.640 7 4 2 state [answer] Playing wav (manager11\ankieta273.wav) working properly. Maybe I should to terminate recording and next to follow to next script? vgEngine.zip Share this post Link to post
SupportTeam Report post Posted 11/13/2014 11:54 AM (edited) The recording is using voice resources from the '1st' leg of the call ( $RV[Conf_LineId_1] ), so that recording process will need to be stopped first before that voice resource can be used to play any sound files. Recommend you amend the script that hangs up the 2nd leg of the call to also stop the recording done on the 1st leg, like this: set vg = CreateObject("vgServices.CommandLink") vg.Play_Stop $RV[Conf_LineId_1] vg.Bridge_Disconnect $RV_LINEID, $RV[Conf_LineId_2]vg.Line_Hangup $RV[Conf_LineId_2]vg.Run_ResultReturn $RV_LINEID, "success"set vg = Nothing Edited 11/13/2014 09:13 PM by SupportTeam Play_Stop was the wrong command to use. see below. Share this post Link to post
invoso.com Report post Posted 11/13/2014 12:19 PM still no progress. vg not playing 131153.062 7 2 1 FindSoundFile start [manager11\ankieta_intro98.wav] but 131153.078 7 2 1 FindSoundFile start [manager11\ankieta273.wav] properly vgEngine_01.zip Share this post Link to post
SupportTeam Report post Posted 11/13/2014 12:33 PM Can you please post the ktTel trace capturing this call. We can then see what happened. Please .ZIP the trace (as before) before posting. The vgEngine trace shows that file manager11\ankieta_intro98.wav cannot be played. The ktTel trace will show why it could not be played. 131153.062 7 2 1 state [ankieta_intro] Playing wav (manager11\ankieta_intro98.wav) 131153.062 7 2 1 FindSoundFile start [manager11\ankieta_intro98.wav] 131153.063 7 2 1 t timer clear (force=False) 131153.063 7 2 1 q_tel + cmd_PlayStart 40122 ,C:\Program Files (x86)\VoiceGuide\Scripts\manager\manager11\ankieta_intro98.wav [] 131153.063 7 2 1 play start ok, playId=40122 131153.063 8 2 1 q_tel run cmd_PlayStart 0 00:00:00 max:4|00:00:00.1830105 131153.077 8 2 1 ev PlayEnd 2 40122 Share this post Link to post
invoso.com Report post Posted 11/13/2014 06:32 PM Attached ktTel 1113_ktTel.zip Share this post Link to post
SupportTeam Report post Posted 11/13/2014 09:05 PM The command to use should be Record_Stop The command that was advised before was wrong. Please use the script as below: set vg = CreateObject("vgServices.CommandLink") vg.Record_Stop $RV[Conf_LineId_1]vg.Bridge_Disconnect $RV_LINEID, $RV[Conf_LineId_2]vg.Line_Hangup $RV[Conf_LineId_2]vg.Run_ResultReturn $RV_LINEID, "success"set vg = Nothing 245 131152.992 1420 2 fn PlayStop(iLineId=2, iActionID=0, iParam1=0, iParam1=0, sParam1=, sParam1=) 246 131152.992 1420 2 PlayStop(hLine=2, iPlayId=0(0x0), iParam1=0, iParam2=0, zsParam1=, zsParam2=) 247 131152.992 1420 2 not calling dx_stopch as hli->dwPlayId==0 ... 277 131153.063 1420 2 fn PlayStart(iLineId=2, sFileList=,C:\Program Files (x86)\VoiceGuide\Scripts\manager\manager11\ankieta_intro98.wav, sXMLOptions=) 278 131153.063 1420 2 PlayStart(hLine=2, strSoundFile=,C:\Program Files (x86)\VoiceGuide\Scripts\manager\manager11\ankieta_intro98.wav, iPlayId=40122(0x9cba), iParam1=0, iParam2=0, zsParam1=, zsParam2=, keys-notused) 279 131153.063 1420 2 play start (hli=0A73A728, strSoundFile=,C:\Program Files (x86)\VoiceGuide\Scripts\manager\manager11\ankieta_intro98.wav, iPlayId=40122(0x9cba), iParam1=0, iParam2=0, zsParam1=, zsParam2=) 280 131153.063 1420 2 play readin loop: idx=0/500, fnamelen=79 281 131153.063 1420 wav: format=1, channels=1, hz=8000, bytes/sec=16000, bytes/sample=2, bits/sample=16, DataBlockSize=147550 C:\Program Files (x86)\VoiceGuide\Scripts\manager\manager11\ankieta_intro98.wav 282 131153.063 1420 leading: 0x00 0x00, remaining data_size=147548 (from start=2) 283 131153.063 1420 convert to 8 bit as sample_rate = 8000 Hz (!=11025) 284 131153.063 1420 BytesPerSample=2 ptrVoiceData_Current=0x13150d78 (16bit->8bit conversion) data_size_div2=73774, 285 131153.073 1420 2 iXpbSampleRateDRT_FirstFile = DRT_8KHZ 286 131153.073 1420 2 iXpbBitsPerSample_FirstFile = 8 (as per returned data) 287 131153.073 1420 2 XpbDataFormat: DATA_FORMAT_PCM (default), rate_const=0x40, bits=8 (iWavFilesEncodingFormat_LastFile=1) 288 131153.073 1420 2 buffer merge add loop hPlayIott_Curr=0x130d6798, ptrVoiceData=0x13305008, io_bufp=0x13150d78, io_length=73774 289 131153.073 1420 2 buffer merge end. calc=73774, copied=73774. hPlayIott_Start=0x130d6798 290 131153.074 1420 2 dx_setevtmsk dev=3 => 0 291 131153.076 1420 2 dx_clrsvcond dev=3 => -1 292 131153.077 1420 2 dx_adjsv dev=3, speed, reset => 0 (no speed keys set on play) 293 131153.077 1420 2 play xpb: wDataFormat=8, wFileFormat=1, nSamplesPerSec=0x40, wBitsPerSample=8 () 294 131153.077 1420 2 play(3, iott=0x130d6798 (len=73774, buff=0x13305008), tpt=0x0, xpb=0xa73b7f8) call 295 131153.077 1420 2 ERROR play (3, 0x130d6798, tpt=0x0, xpb=0xa73b7f8) => -1, err=9:Device busy, hli=0A73A728 296 131153.077 1420 3 play issuing dx_stopch as error is 'device busy' 297 131153.077 1420 2 hPlayIott_Start=0x130d6798 hli->hPlayRec_IottChainStart=0x130d6798 298 131153.077 1420 2 free IottChainStart=0x130d6798, io_bufp=013305008 299 131153.077 1420 2 Event_PlayEnd begin 300 131153.077 1420 2 r PlayEnd 40122 Share this post Link to post
invoso.com Report post Posted 11/14/2014 06:22 AM Thanks a lot. Now working properly. Share this post Link to post