Hi,
I am pretty new to Asterisk. I am trying to make sure some human being
answers the phone not the voice mail machine. How can I programmatically
identify that?
Here is my Sub:
sub DialPhysician {
my ($self, $con, $PhysicianPhone, $call_id, $conv_id) = (@_);
to_log($self, "Inside Dial Physician", 2);
my $DocPhone = "1". $PhysicianPhone;
to_log($self, "Values: $DocPhone, $call_id, $conv_id", 2);
$self->agi->set_variable("STATE","NEXT");
$self->agi->set_variable("stat_vars","$call_id:$conv_id:$DocPhone");
my $response =
$self->agi->exec("Dial","Local/$docpho...@$out_context/n|20|g");
my $CallStatus = $self->agi->get_variable("DIALSTATUS");
my $ANSWEREDTIME=$self->agi->get_variable("ANSWEREDTIME");
to_log($self, "Physician Call Status: $CallStatus; ANSWEREDTIME:
$ANSWEREDTIME", 2);
return 0;
}
Is this not the correct way to do this? Or Are there any other methods?
Thanks
Bharath B. Reddy Bynagari
_______________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
AstriCon 2009 - October 13 - 15 Phoenix, Arizona
Register Now: http://www.astricon.net
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users