How to route SIP call from wifi to mobile network (3G,4G) and versa?


#1

My goal is to reach the routing of VOIP call like it do famous VOIP apps like LINE, VIBER…
Scenario is: If im on the street and entering in home with my wifi the VOIP call isn’t drop but it is routed from 4G to wifi without interuption of call or minimum gap of 1-2 second, and versa.

This not happening with asterisk.
When it jump from wifi to 4G it stay sthe silence, but connection is still alive.
I did the MANGLE setup in MikroTik to monitor the connections:
Mangle
https://s19.postimg.cc/aebszqn6r/Mangle.jpg

If for example I start the call from 4G in connection in firewall in MT I can catch with connection mark the next connection:

Firewall 4G

If I migrate from 4G to wifi I see:

Firewall 4G -> wifi

The complete log wit option sip debug is here:
full.log

The number what is called is: 3735

Can someone tell me what is the problem?
What do I need to edit to achieve goal?
Thx


#2

I don’t see what Asterisk has to do with your project.

It would be up to the soft client on your phone to handle transitioning between networks.


#3

As above. Also, you don’t want to handoff to wifi, because wifi has too high a jitter to be a good medium to use for voice.


#4

Huff…
But I tried with more client, as Zoiper, CSipsimple, Mizudroid, and everywere is the same situation.
So , I think that it is directly in relationship with asterisk.

@david551
I do not understad your post.
You telling me than on wifi (what is my home network) the jitter is bigger than on 4G where the ping is always bigger?


#5

I don’t know if your 4G service is suitable for VoIP. Of course the network operators telephone service is optimised for voice and they have no incentive to make the data service handle voice well. However Wifi is definitely bad for VoIP.

Also note we are talking jitter, not latency.

On your first point, the phone has to handle the handoff, or support multi-homing, as it is the only part that understands what is rally happening. For a handoff, the phone will have to volunteer SDP with the new media address for its end . It is unlikely that the, basically consumer, environment, that you describe, would support the sophisticated routing protocols that are needed for multihoming. gated will run on Linux, but it is unlikely to run on the phone and a consumer 4G service is most unlikely to support border gateway protocol.


#6

It seams that I wasn’t enough clear.
Im speaking about mobile phone. What is better than wifi connection on mobile phone?
It isn’t posible to connect the LAN cable.
Second, yes it is posible to use over 4G and my provider do not filter the traffic.
All this story is if I’m on the range of wifi and I’m closing to place where will my mobile phone automaticlly connect to wifi and the call is active then the call will become “deaf”

Maybe it is important to tell that I’m using asterisk connected to chain_dongle with SIM card inside and with client (CSIPSimple) communicate with other (gsm or fix phone), over chan_dongle usb modem (Huawei 1550)


#7

I think it was fairly clear, you want to save money by using one, almost certainly unsuitable physical layer, and then handing the calls off to an even cheaper and definitely unsuitable physical layer.

Although SIP has no way by which a phone could initiate a handoff to such technologies, appropriate technologies for the local case would be DECT or Bluetooth (and for the distant case, the standard mobile phone speech service).

(Wifi may work with reasonable quality, if you are in a wifi desert so have no traffic contending for the wifi channel.


#8

Sorry but I didn’t understand what u want to tell me…
I asked how to do this, and not about DECT and Bluetooth systems how it can be.
Is it imposible?

Btw in tis way I can use my sim card in one country till I am in another country for free, that is the logic of all my project!
And, of course that it save the money, but Im using just for personal needs!


#9

We don’t want to put you down, but the fact that you don’t understand the information that is given to you means that you are a bit out of your league to be building a system you want to build.

This handover between gsm data network and another data network is like a “holy grale”…

You need to realize that what you want to do is switch from ip network without you noticing …while you are talking…

This could be done, but your sip client would have to notice that you are either entering a leaving your wifi zone, then put the call you have on hold… Then the sip client changes network an retrieve the hold call…

Think that would mean you have to write a sip client that can do that… If you an do that… think you will get a lot of job offers…

Hope this clarifies things a bit.


#10

There is no need to put on hold for just the media, a simple re-invite will do, but the point remains that it is the phone that controls this, not Asterisk.


#11

@meightee
Thx now it is clear in this way of explanation.
I already knew for everything u explained me. I understand whats happening, and that call jumping from one ip to another.
What is not clear to me, how can it be that I tried almost all clients software but neither of them do not have this option? Is it a Holy grail? Why all other VOIP software like LINE, Viber have this option and neither of client for asterisk have not.

I still do not understand, is it posible to achieve my request with changeing in exstension.conf, sip.conf?


#12

LINE and Viber use their own technology and can fully control the experience, they can also invest in doing this. There’s nothing configuration wise in Asterisk to explicitly support this, and if the client on the phone can’t do it then no.


#13

Thx for clean answer then!