Only the first 2 prompts play

Version 1
    This document was generated from CDN thread

    Created by: Mark Alliban on 09-05-2013 08:54:51 AM
    So, another project, I have a very simple TCL code:   proc init { } { } proc act_Setup { } { global tries set tries 0 infotag set med_language 1 leg setupack leg_incoming leg connect leg_incoming act_PlayNext } proc act_PlayNext { } { global tries incr tries puts "Playing $tries.au" media play leg_incoming "$tries.au" } proc act_Close { } { call close } init set fsm(CALL_INIT,ev_setup_indication) "act_Setup same_state" set fsm(any_state,ev_media_done) "act_PlayNext same_state" set fsm(any_state,ev_disconnected) "act_Close same_state" fsm define fsm CALL_INIT   It should just count upwards, indefinitely. What actually happens is that it says "one two", but no further, it just goes quiet.   The prompts definitely exist... if I set tries to start at 2 in setup, it says "three four" and then silence. The debug looks as though it should be playing them all, and it is waiting the correct amount of time (about half a second per number)... but always, only the first two prompts play.   May  9 13:41:48.417: //7//TCL :/tcl_PutsObjCmd: Playing 1.au May  9 13:41:49.029: //7//TCL :/tcl_PutsObjCmd: Playing 2.au May  9 13:41:49.537: //7//TCL :/tcl_PutsObjCmd: Playing 3.au May  9 13:41:50.085: //7//TCL :/tcl_PutsObjCmd: Playing 4.au May  9 13:41:50.713: //7//TCL :/tcl_PutsObjCmd: Playing 5.au May  9 13:41:51.321: //7//TCL :/tcl_PutsObjCmd: Playing 6.au May  9 13:41:52.009: //7//TCL :/tcl_PutsObjCmd: Playing 7.au  

    Subject: RE: Only the first 2 prompts play
    Replied by: Yaw-Ming Chen on 09-05-2013 11:34:34 AM
    I tried the following and didn't see any problem. I only have  1 to 4 prompts but it plays all.
     
    proc init { } {
    }
    proc act_Setup { } {
    global tries
    set tries 0
    leg setupack leg_incoming
    leg connect leg_incoming
    act_PlayNext
    }
    proc act_PlayNext { } {
    global tries
    incr tries
    puts "Playing $tries.au"
    media play leg_incoming flash:$tries.au
    }
    proc act_Close { } {
    call close
    }
    init
    set fsm(CALL_INIT,ev_setup_indication) "act_Setup same_state"
    set fsm(any_state,ev_media_done) "act_PlayNext same_state"
    set fsm(any_state,ev_disconnected) "act_Close same_state"
    fsm define fsm CALL_INIT

    Subject: RE: Only the first 2 prompts play
    Replied by: Mark Alliban on 10-05-2013 03:12:05 AM
    OK thanks for trying it, any reason it would work on yours but not on mine?
    Whatever I do, I can't get it to play more than 2 prompts. Whether they are short or long, have digit collection or other functions in between, the first 2 play but the rest play silently.
     

    Subject: RE: Only the first 2 prompts play
    Replied by: Mark Alliban on 10-05-2013 04:51:57 AM
    Log attached.  

    Subject: RE: Only the first 2 prompts play
    Replied by: Raghavendra Gutty Veeranagappa on 10-05-2013 04:32:33 AM
    Hi Mark,
     
    please send us the below debugs.
     
    debug voip app
     
    Thanks,
    Raghavendra

    Subject: RE: Only the first 2 prompts play
    Replied by: Mark Alliban on 10-05-2013 07:47:37 AM
    Neither of those helps. In fact if I play the same prompt over and over ie. "one one one one one...." then I still only hear the first 2 times!
     

    Subject: RE: Only the first 2 prompts play
    Replied by: Raghavendra Gutty Veeranagappa on 10-05-2013 07:22:40 AM
    Hi Mark,
    Thanks sharing the logs, please try with below command also try to play prompts from flash instead of ftp server.
    ivr prompt memory 128
    Thanks,
    Raghavendra

    Subject: RE: Only the first 2 prompts play
    Replied by: Yaw-Ming Chen on 10-05-2013 10:21:01 AM
    Did you try the following exactly ? A little bit different from yours.
    And use aduio file name is 1.au, 2.au exactly
    There is a little prolem in your script to get the right file name.
    May 10 09:47:30.700: //159//TCL :/tcl_PutsObjCmd: Playing 3.au
    May 10 09:47:30.700: //159//PACK:/tcl_MediaObjCmd:  media play leg_incoming 3.au
    May 10 09:47:30.700: //159//PACK:/tcl_MediaPlayObjCmd:  play leg_incoming 3.au
    May 10 09:47:30.700: //159//AFW_:/vtd_lg_incoming: argc 3
    May 10 09:47:30.700: //159//AFW_:/vtd_lg_incoming: Legs [159 ]
    May 10 09:47:30.700: //159//Tcl :/tcl_parseCallID_vartagObj: VARTAG Translation Leg Count=1
    May 10 09:47:30.700: //-1//DPM P107:/pc_mc_addToDynamicS: (1) 3.au
    May 10 09:47:30.700: //-1//DPM P107:/pc_mc_addToDynamicS: Doing : 3.au
    May 10 09:47:30.700: //-1//DPM :/mcTokenizerGetNext: savedcharptr=_ endptrptr=3.au
    May 10 09:47:30.700: //-1//DPM P107:/pc_mc_addToDynamicS: Token : 3.au status 1
    May 10 09:47:30.700: //-1//DPM P107:/dp_mcDQfromFileDynamic:  pLanguage=en FileName=3.au
    May 10 09:47:30.700: //-1//DPM P107:/dp_mcDQfromURL:  file=ftp://192.168.1.100/prompts/en/en3.au
    May 10 09:47:30.700: //-1//MCM :/mc_createFromFileUrl: Getting a media content: name=en3.au

    proc init { } {
    }
    proc act_Setup { } {
    global tries
    set tries 0
    leg setupack leg_incoming
    leg connect leg_incoming
    act_PlayNext
    }
    proc act_PlayNext { } {
    global tries
    incr tries
    puts "Playing $tries.au"
    media play leg_incoming flash:$tries.au
    }
    proc act_Close { } {
    call close
    }
    init
    set fsm(CALL_INIT,ev_setup_indication) "act_Setup same_state"
    set fsm(any_state,ev_media_done) "act_PlayNext same_state"
    set fsm(any_state,ev_disconnected) "act_Close same_state"
    fsm define fsm CALL_INIT

    Subject: RE: Only the first 2 prompts play
    Replied by: Mark Alliban on 14-05-2013 07:24:32 AM
    OK, to get around all of these issues I have simplified it even further.
     
    proc init { } {
    }
    proc act_Setup { } {
    leg setupack leg_incoming
    leg connect leg_incoming
    act_PlayNext
    }
    proc act_PlayNext { } {
    puts "Playing flash:en1.au"
    media play leg_incoming flash:en1.au
    }
    proc act_Close { } {
    call close
    }
    init 
    set fsm(CALL_INIT,ev_setup_indication) "act_Setup same_state"
    set fsm(any_state,ev_media_done) "act_PlayNext same_state"
    set fsm(any_state,ev_disconnected) "act_Close same_state"
    fsm define fsm CALL_INIT
     
    This should just play "one one one one one one one......" until I hang up.
    I just hear "one one" then it goes silent.
     

    Subject: RE: Only the first 2 prompts play
    Replied by: Yaw-Ming Chen on 14-05-2013 10:06:33 AM
    Of cause, you only have "media play leg_incoming flash:en1.au" one audio file.
    Try exactly the follwoing, do not modify and prepare a few audio file in flash (you can modify and move once it works for you)
    name audio file 1.au, 2.au, 3.au...
    proc init { } {
    }
    proc act_Setup { } {
    global tries
    set tries 0
    leg setupack leg_incoming
    leg connect leg_incoming
    act_PlayNext
    }
    proc act_PlayNext { } {
    global tries
    incr tries
    puts "Playing $tries.au"
    media play leg_incoming flash:$tries.au
    }
    proc act_Close { } {
    call close
    }
    init
    set fsm(CALL_INIT,ev_setup_indication) "act_Setup same_state"
    set fsm(any_state,ev_media_done) "act_PlayNext same_state"
    set fsm(any_state,ev_disconnected) "act_Close same_state"
    fsm define fsm CALL_INIT

    Subject: RE: Only the first 2 prompts play
    Replied by: Mark Alliban on 14-05-2013 10:25:52 AM
    Yaw-Ming Chen:
    Of cause, you only have "media play leg_incoming flash:en1.au" one audio file.

    Huh? It should play this one audio file over and over shouldn't it? Because the function is called again on ev_media_done event, it should keep on repeating "one one one one one one one..." until I hang up, right?
     
    I've tried your code. It just says "one two" and then silence. And yes 3.au and 4.au are there! If I change "set tries 0" to "set tries 2", then it does say "three four" and then stops, which proves that it is NOT a prompt file issue.
     
     

    Subject: RE: Only the first 2 prompts play
    Replied by: Mark Alliban on 14-05-2013 11:06:34 AM
    Inserting silence does not help. Log attached, this forum won't let me attach .au files, but they work.
     

    Subject: RE: Only the first 2 prompts play
    Replied by: Yaw-Ming Chen on 14-05-2013 10:55:26 AM
    You script should be fine.
    Something different on your router. Can you please attached you en1.au ? Also the same dubu as you collected before for your last "one one one ..." test.
    Also try put some silence delay see if it helps.
    media play leg_incoming %s500 flash:en1.au"
     

    Subject: RE: Only the first 2 prompts play
    Replied by: Yaw-Ming Chen on 14-05-2013 11:35:11 AM
    I saw script play 1 2 3 4 in log what did you actually hear ?
     
     

    Subject: RE: Only the first 2 prompts play
    Replied by: Mark Alliban on 15-05-2013 03:24:03 AM
    I hear "one two" and then no more. I've run the test multiple times with the same result.
     

    Subject: RE: Only the first 2 prompts play
    Replied by: Mark Alliban on 15-05-2013 07:24:20 AM
    Yes it does play all four prompts when I use that line.
     
    But if I insert that line into the above code, ie. change "media play leg_incoming flash:$tries.au" into "media play leg_incoming flash:1.au %s10 flash:2.au %s10 flash:3.au %s10 flash:4.au", then it should keep on saying "one two three four" repeatedly until I hang up... but it doesn't... it says  "one two three four one two three four" then goes quiet!!!
     
    The first 2 media play commands work, but all subsequent ones are silent, although the logs seem to show the prompts are playing I don't hear them!

    Subject: RE: Only the first 2 prompts play
    Replied by: Raghavendra Gutty Veeranagappa on 15-05-2013 07:00:28 AM
    Hi Mark,
    please try below command and see if it plays all  prompts.
    media play leg_incoming 1.au %s10 2.au %s10 3.au %s10 4.au
    Thanks,
    Raghavendra
     

    Subject: RE: Only the first 2 prompts play
    Replied by: Raghavendra Gutty Veeranagappa on 15-05-2013 07:38:25 AM
    Hi Mark,
    Which IOS version your using, is it possible to share "sh version" and running config.
    Thanks,
    Raghavendra

    Subject: RE: Only the first 2 prompts play
    Replied by: Mark Alliban on 15-05-2013 08:01:49 AM
    Attached.
     

    Subject: RE: Only the first 2 prompts play
    Replied by: Raghavendra Gutty Veeranagappa on 16-05-2013 01:55:21 AM
    Hi Mark,
    thanks for sharing the info, i don't find any issue with your config or with the script.
    Thanks,
    Raghavendra

    Subject: RE: Only the first 2 prompts play
    Replied by: Mark Alliban on 16-05-2013 03:27:48 AM
    Yeah it all should work, hence the reason I have posted here... any ideas?