Le 28/03/2014 15:40, Richard Mudgett a écrit :



On Fri, Mar 28, 2014 at 4:01 AM, Administrator TOOTAI <[email protected] <mailto:[email protected]>> wrote:

    Hello,

    I would like to use AMD on outgoing calls using analog line. I
    tested with SPA3102 and cisco2811 as gw and asterisk 1.8.26.1 as
    well as 11.8.1 Other end is analog number behind another
    cisco/asterisk, also tested calling a mobile number with the same
    result.

    What I did: dial is done like exten => s,n,Dial(SIP/<IP
    gw>/<dialed number>,,M(myMacro)), which tell Asterisk to execute
    myMacro when the call is answered by calling party.

    [myMacro]

    exten => s,1,NoOP(Executed when call is answered)
     same => n,AMD()
     same => n,NoOp(Dial status=${DIALSTATUS})
     same => n,NoOp(AMD status=${AMDSTATUS} cause=${AMDCAUSE})
     same => n,MacroExit()

    Problem is that [myMacro] is executed as soon as the call is going
    out from the gw (cisco or linksys) and before called party
    answered. DIALSTATUS is empty (should be ANSWER),
    AMDSTATUS=NOTSURE and AMDCAUSE=TOOLONG-5000 which seems OK as
    DIALSTATUS isn't reliable.

    The same dialplan using a SIP trunk is working as expected.

    So question is, why, when using analog line, I dont get the right
    behavior.

    Thanks for any hint


Analog lines don't have a reliable way to know when the far end actually answers. Polarity reversals could signal when the far end actually answers, but it isn't normally available or standardized. Thus, the line is considered answered when dialing is complete.

OK, so it's a no way.

Thanks for your answer

--
Daniel

--
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
              http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users

Reply via email to