[Asterisk-Users] Problem with getting the value of variable DIALSTATUS in AGI script

Artem Stepanoff Artem.Stepanoff at nbi.com.ua
Tue May 17 06:00:21 MST 2005


 Hello.
 Есть небольшой скрипт на перле, который просто, для проверки, звонит на определённый номер, а потом получает
 +информацию о статусе звонка.

 I wrote a small perl script, that just calls to the specified number and then receives the information about
 +the status of the call.
 This script is below:

  #!/usr/bin/perl
  use Asterisk::AGI;
  $AGI = new Asterisk::AGI;
  my %input = $AGI->ReadParse();
  open (TEST,">>/home/kesha/ast_test");
  $AGI->exec("DIAL OH323/232313124\@ip.address.of.the.gateway");
  $status=$AGI->get_variable("DIALSTATUS");
  print TEST $status;
  close (TEST);

   When I call to the specified upper number, I am successfully connecting with the subscriber and have
   a conversation with him. When the person, who is talking to me, hangs up a receiver the value
   of $status variable is ANSWER, but when I do this - I receive $status='noresponse'.

-- 
 --------------------------------------------------------------
 Artem Stepanoff   |   System Administrator   |     KESH-RIPE
 ISP "National Bureau of Information"         |     KESH-UANIC
 --------------------------------------------------------------



More information about the asterisk-users mailing list