Yep, I found about that a few hours after I posted - I guess it's only
use for outbound calls - sad
However, I was able to do some math in the set command using EPOCH to
solve the problem
For those that might seek a solution:
exten => _X.,n,Set(STIME=${EPOCH}) ; save the start time
...do some stuff...
exten => _X.,n,Set(ETIME=${EPOCH}) ; save the end time
exten => _X.,n,Set(DUR=$[${ETIME}-${STIME}]) ; set DUR to difference
(seconds)
Bart
Joshua Colp wrote:
Barton Fisher wrote:
No matter what I do, ${ANSWEREDTIME} is always 0, even on the most
simplest dial plan such as:
Using Asterisk 1.2.13
exten => 77,1,Answer
exten => 77,2,Playback(custom/dax/S300) ; one minute file
exten => 77,3,Noop(${ANSWEREDTIME})
exten => 77,4,Hangup
-- Executing Answer("SIP/5402-b7b45f58", "") in new stack
-- Executing Playback("SIP/5402-b7b45f58", "custom/dax/S300") in
new stack
-- Playing 'custom/dax/S300' (language 'en')
-- Executing NoOp("SIP/5402-b7b45f58", "") in new stack
-- Executing Hangup("SIP/5402-b7b45f58", "") in new stack
What gives on this simple thing?
Bart
Slight correction: It is NULL, not 0. Something can't be broken that
was never expected to work or coded to work... ANSWEREDTIME only gets
set by app_dial when you dial something else and it is answered or not
answered.
Joshua Colp
Software Developer
Digium, Inc.
__________ NOD32 2247 (20070507) Information __________
This message was checked by NOD32 antivirus system.
http://www.eset.com
_______________________________________________
--Bandwidth and Colocation provided by Easynews.com --
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users