alexchengalan / csipsimple

Automatically exported from code.google.com/p/csipsimple
0 stars 0 forks source link

Call cut when using 3G if known WiFi becomes available #121

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
Make 3G call.  Move towards WiFi router until in range.

What is the expected output? What do you see instead?
Ideally, call should continue over 3G until finished preventing WiFi from 
taking over.  Perhaps disable WiFi during 3G calls, although that might 
conflict with my Y5 Battery Saver or similar.  Even better would be to forward 
call to WiFi interface once connection made.

What version of the product are you using? On what operating system?
0.00-12-06, Nexus 2.2

Original issue reported on code.google.com by kro...@gmail.com on 31 Jul 2010 at 1:32

GoogleCodeExporter commented 9 years ago
Yes, the second solution should be the correct behavior.
There is some piece of code that already re-register each time network is 
changed.
But never tested. Probably something to be deeply tested.
I think that there is a brief instant while there is no connection available at 
all. And so, the sip stack just teardown instead of staying connected and 
waiting a while for a new connection (that will allow, just by re-registration 
to update voice path sending the good new sdp offers).

Maybe difficult to test for me (my gsm provider block 3G SIP calls). But will 
try with wifi to another wifi spot. (Maybe same the thing can be observed). Or 
if Bob or Micheal want to take the point, they would be welcome.

Original comment by r3gis...@gmail.com on 9 Aug 2010 at 4:07

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
http://trac.pjsip.org/repos/wiki/Symbian_AP_Reconnection < Technical article 
from pjsip to follow to manage this issue.

My first comment was wrong (I didn't remember this article very well since).
The good way seems to be stop the stack and then, restart it. But as I 
previously said, I never tested it, and there is maybe consistency issues with 
the user interface.

Original comment by r3gis...@gmail.com on 10 Aug 2010 at 9:25

GoogleCodeExporter commented 9 years ago
Please note that if the peer does *not* have the "capability to switch its 
RTP/RTCP transmission to the source address of the RTP/RTCP packets" mentioned 
in the article that you cited, you will need to modify existing SIP and SDP 
sessions (give them the new IP address of yourself) with a new INVITE, 
mentioned as pjsip_inv_reinvite() in the article, that is said to be not fully 
working.

This is my understanding of the issue (but I must say that I only have 
theoretical knowledge of the protocol).

Original comment by egcros...@gmail.com on 14 Aug 2010 at 8:29

GoogleCodeExporter commented 9 years ago
I've tested a 3g call swapping over to wifi and it works.  So it can be marked 
as solved.  However if you move out of wifi range (or switch it off) it doesn't 
switch back to 3g, as there's no connection to do handover.  I suppose the 
solution would be enable 3g when a call starts, having it ready for switch over 
if wifi connection drops below a certain level or fails.

Thoughts?

Original comment by kro...@gmail.com on 16 Aug 2010 at 8:09

GoogleCodeExporter commented 9 years ago
Strange that now it works.
I didn't change anything on that point keeping my old method that just destroy 
the sip stack and start it again when connection is lost. (This is one of the 
solution proposed by pjsip guys - the other described by egcrosser is not fully 
working).
What is possible is that my method is not stable enough (probably the first 
time you get the issue it was a 3G -> Wifi and this time 3G -> Nothing -> Wifi. 
(the nothing force the sip stack to restart).
I should probably do thing cleaner on that point. So I'll not close this issue 
yet, still work to do on it.

For your second point Wifi -> No 3G I have this one sometimes too. Maybe linked 
to the fact an app keep a wifi lock (that's the case of csispimple while in 
call) or maybe keep some open sockets. So there is also clean things to do on 
that point to cleanly stop the stack when connection is lost.

Original comment by r3gis...@gmail.com on 16 Aug 2010 at 9:56

GoogleCodeExporter commented 9 years ago
Issue 1033 has been merged into this issue.

Original comment by r3gis...@gmail.com on 11 Jun 2011 at 12:01

GoogleCodeExporter commented 9 years ago
As per issue 1033, should also ensure this does not break outgoing calls too.

Original comment by r3gis...@gmail.com on 11 Jun 2011 at 12:02

GoogleCodeExporter commented 9 years ago
Info Request:

Regis, 

I have a few questions on the following works in PjSip and if it does how is it 
done in CSipSimple as I did not find any code references to it.

1. Re-register with the new IP address when switching between 3g and WiFi 
(manually or moving in-out of coverage). 
2. IP address change when on 3g. How do you get notified on IP address change  
and what action do you take?
3. How to re-invite in the middle of a call with new IP address if WiFi becomes 
available and is in range for use.

Your answers with references to your code blocks are highly appreciated. I am 
studying your code to potentially do similar to what Keyyo-VoIP has done and 
want to make sure you have it all covered as those are some of the requirements 
that my product management is putting on me.

Thanks,
Perry

Original comment by perry.lu...@gmail.com on 1 Jul 2011 at 4:33

GoogleCodeExporter commented 9 years ago
r3gis: you cant use sip over your 3g if your carrier sees it as sip, try 
openvpn =]

Original comment by grndcntr...@gmail.com on 2 Sep 2011 at 9:19

GoogleCodeExporter commented 9 years ago
Im new here, pleas help me. Im im using CSIPsimple on my Galaxy Note as a 
remote extension of my own PBX system, it worked well for few days, but 
suddenly it disconnected and cant register to my SIP account anymore. I 
switched to Wifi (ADSL internet) and now t works only on Wifi but not on 3G, so 
my 3G provider confirmed they dont allow voip calls. is there any possibility 
to overcome my 3G operator's restriction?

Original comment by 7778...@gmail.com on 29 Mar 2013 at 5:37

GoogleCodeExporter commented 9 years ago
Hi Regis, can you sum up? What you do when network changes during call ? Do you 
destroy and create pjsip again? Or do you send reINVITE ?

Original comment by onmyway...@gmail.com on 21 Aug 2013 at 8:21

GoogleCodeExporter commented 9 years ago
If *during a call*, nothing. If ICE is enabled or remote side supports (like 
pjsip) rtp sources changes, media will be updated as soon as only one change 
its network (which should be sufficient to get media of the call still active). 
Nothing is done currently to update dialog contact.

In general, the implementation in csipsimple is made with mind the pjsip 
guidelines that you can read here :
http://trac.pjsip.org/repos/wiki/IPAddressChange

Original comment by r3gis...@gmail.com on 21 Aug 2013 at 8:29

GoogleCodeExporter commented 9 years ago
Have you stumbled upon rtpproxy? Many devices nowadays are behind "Symmetric 
NAT", so using rtpproxy is a must. Unfortunately, its default behavior is to 
NOT accept rtp packets from new IP.
Also, I read that you said, NDK native socket is still using 3G interface even 
if we turn on Wifi, right ?

Original comment by onmyway...@gmail.com on 22 Aug 2013 at 11:14