Hello,
I’m not sure if this is the right place to place my question, I trying to make a call using a SIP between two regular phones and I’m using a JavaAsterisk example. This is a snapshot for the JAva’s code:
public ManagerResponse genCall( String numTel1, String numTel2, int timeOut ) throws IOException, IllegalArgumentException, TimeoutException{
OriginateAction originateAction1 = new OriginateAction();
originateAction1.setChannel("SIP/"+this.troncal+numTel1);
originateAction1.setContext("phones"); //phones
originateAction1.setExten(numTel2);
originateAction1.setPriority( new Integer(1) );
originateAction1.setVariable("VAR1", numTel1);
originateAction1.setVariable("VAR2", numTel2);
originateAction1.setAsync(Boolean.TRUE);
ManagerResponse response = manager.sendAction(originateAction1,timeOut);
return response;
}//fin de genCall()
public static void main(String[] args) throws IOException, AuthenticationFailedException,TimeoutException {
JavaAsterisk dial = new JavaAsterisk("Royner","200.xx.xx.xxx","x7b2p910");
dial.setTroncal("13058539786/");
dial.login();
//String numTel1 = JOptionPane.showInputDialog("Add the phone number: ");
//String numTel2 = JOptionPane.showInputDialog("Add the phone the dest phone number: ");
String numTel1 = "72347940";
String numTel2 = "89510259";
ManagerResponse response = dial.genCall("+"+numTel1, "+"+numTel2, 15000);
dial.logOff();
}//fin de main
But when running I’m getting following error:
run:
04-jul-2014 14:24:41 org.asteriskjava.manager.internal.ManagerConnectionImpl connect
INFO: Connecting to 200.91.92.140:5038
04-jul-2014 14:24:42 org.asteriskjava.manager.internal.ManagerConnectionImpl setProtocolIdentifier
INFO: Connected via Asterisk Call Manager/1.1
04-jul-2014 14:24:42 org.asteriskjava.manager.internal.ManagerConnectionImpl doLogin
INFO: Successfully logged in
04-jul-2014 14:24:42 org.asteriskjava.manager.internal.ManagerConnectionImpl doLogin
INFO: Determined Asterisk version: Asterisk 1.6
04-jul-2014 14:24:42 org.asteriskjava.manager.internal.EventBuilderImpl buildEvent
INFO: No event class registered for event type ‘fullybooted’, attributes: {status=Fully Booted, event=FullyBooted, privilege=system,all}. Please report at jira.reucon.org/browse/AJ
04-jul-2014 14:24:42 org.asteriskjava.manager.internal.ManagerConnectionImpl disconnect
INFO: Closing socket.
04-jul-2014 14:24:42 org.asteriskjava.manager.internal.ManagerReaderImpl run
INFO: Terminating reader thread: socket closed
BUILD SUCCESSFUL (total time: 1 second)
I don’t have any idea how to start the debug for this issue. I’m suspecting it might be related to the Channel configuration (SIP) but not sure how to isolate the problem . I’m newbie on this, any help is highly appreciate.
Regards