Search code examples
androidsipjain-sipsip-stack

How to make call to my mobile number in Android sip stack SipManager?


I am able to make call between sip address using Android sip stack sipManager. But not able to call from registered sip account to my mobile number. Highly appreicate for any suggestion. when i use any soft sip phone , i am able to register my sip account and make call , but not using below Android SipManager.

SipProfile.Builder builder;
            SipProfile toCall;
            try {
              builder = new SipProfile.Builder(SENDCALL.toString(), DOMAIN);
             //  builder = new SipProfile.Builder("0041766666"); 
             // how can i call to mobile number like above. i am able to call to sip address. but do not now how to call to fix mobile numbers.
                toCall = builder.build();
              // builder.setProtocol("UDP");
             //  builder.setPort(5090);
                SipSession.Listener ssl = new SipSession.Listener() {
                    @Override
                    public void onCallEnded(SipSession session) {
                        super.onCallEnded(session);
                        try {
                            call.endCall();
                        } catch (SipException e) {
                            e.printStackTrace();
                        }
                        session.endCall();
                    }
                };

                call.makeCall(toCall, manager.createSipSession(profile, ssl), 30);

Solution

  • i just came to know that Android sip Api sipManager is limited to call betwen only sip account. And only solution to this issue is I have to start using other sip library. I will be implementing with PJSIP