Passing ANI from TCL to application Default

Version 1
    This document was generated from CDN thread

    Created by: David Chachanidze on 01-09-2013 07:27:34 AM
    Hello,

    Is there any way to pass ANI (generated in TCL) at the "proc Setup" state to Default Applications using the command  "handoff appl leg_all default"?

    I mean, that I want to change only ANI using TCL, and then pass the remaining part of the call to Default Application with that generated ANI number.
    I am using the following simple scripts section to pass the call to Default Application, but the ANI is not passed.
     
    proc act_Setup { } {
      global dnis
        global ani
        global callInfo
          set ani "012345678"
    set callInfo(originationNum) $ani
     leg setupack leg_incoming
      handoff appl leg_all default "DESTINATION=$dnis"
      act_Cleanup

    Subject: RE: Passing ANI from TCL to application Default
    Replied by: Raghavendra Gutty Veeranagappa on 01-09-2013 11:04:50 PM
    Hi David,

    you can use leg setup command and pass callInfo param, once call is established means after receiving ls_000 you can handoff to default application.
    set ani "012345678"
    set callInfo(originationNum) $ani
    leg setup $dest callInfo leg_incoming

    handoff appl leg_all default

    Thanks,
    Raghavendra

    Subject: RE: Passing ANI from TCL to application Default
    Replied by: David Chachanidze on 02-09-2013 02:38:39 AM
    Unfortunately, that does not fit my needs. Because in such case, I have to describe all possible events, like Busy, NoAN and etc in TCL (I need those events).

    I want to pass the call to Default Application at SETUP state, so that all those afterwards events will be processed by Default APP, instead of describing them in TCL.

    Also if I describe, for instace, Busy event in TCL, then TCL can only make a PlayTone, while I need the Router to respond with SIP Busy message rather then Playing Tones Inband.

    Subject: RE: Passing ANI from TCL to application Default
    Replied by: Raghavendra Gutty Veeranagappa on 02-09-2013 04:46:14 AM
    Hi David,

    try to do handoff once script receives the ev_setup_done event.

    Thanks,
    Raghavendra

    Subject: RE: Passing ANI from TCL to application Default
    Replied by: Raghavendra Gutty Veeranagappa on 02-09-2013 06:48:47 AM
    Hi David,
    please try as below and see if that helps

    proc act_Setup { } {
      set ani "012345678"
      set callInfo(originationNum) $ani
      leg setup $dest callInfo leg_incoming
    }

    proc act_CallSetupDone { } {    
        set status [infotag get evt_status]
        puts "\n STATUS=$status"
        handoff appl leg_all default
        call close    
    }

    Thanks,
    Raghavendra

    Subject: RE: Passing ANI from TCL to application Default
    Replied by: David Chachanidze on 02-09-2013 07:03:37 AM
    No, that does not help.

    I have already tryed to put "call close" command at the end, but still, Gateway makes 2 calls, one from TCL, and 1 from Default Application.
     

    Subject: RE: Passing ANI from TCL to application Default
    Replied by: David Chachanidze on 02-09-2013 05:56:05 AM
    That does not work  as well.

    If using Handoff on Setup Done step, the following happens in case of Busy:

    TCL tries to make a first call on Setup step, it gets busy, and goes to Setup Done step, where the handoff procedure is taking place. Then Default APP tries to make a call to that destination and again gets busy, So there are 2 calls in that case.

    It gets even worse in case of NoAnswer, where the first call is made by TCL and the phone rings, after Ring No Answer timeout, TCL gets NOAN status, and goes to Setup Done step, where again the Handoff is taking place. Now the Default APP is trying to ring the same destination and the destination rings again. So here also we got two calls.

    Subject: RE: Passing ANI from TCL to application Default
    Replied by: Raghavendra Gutty Veeranagappa on 03-09-2013 12:58:36 AM
    Hi David,
    could you please share your script, if you dont want share it here please send out to  developer-support@cisco.com
    Thanks,
    Raghavendra