Android webrtc not working with 3g, 4g

点点圈 提交于 2019-12-20 15:28:36

问题


In android application i have user webrtc for video calling app.

If mobile is connected with wifi then app work perfectly.

When i change wifi to mobile data and start app then app not work and also not display video .

I have user webrtc in my app and server side kurento.

Below list of scenario with status :

  1. Browser Client + Mobile Client -> Both on same Wifi network(KMS Server on same wifi network) -> Working fine.
  2. Mobile Client + Mobile Client -> Both on same Wifi network(KMS Server on same wifi network) -> Working fine.
  3. Browser Client + Mobile Client -> One of them on wifi(KMS Server on same wifi network) and other on mobile data network -> Not working
  4. Mobile Client + Mobile Client -> One of them on wifi (KMS Server on same wifi network) and other on mobile data network -> Not working

We have check candidate generated for all this scenario and found they are same only difference seen is multiple candidate getting generated.

We have crate Turn server as well as Stun but video not display in android client with 3g connection.

Any one have solution then help me out.

Thanks in advance.


回答1:


Theoretically the network type shouldn't influence if WebRTC works or not.

But, there are other factors influencing this. First of all if both devices are connected into the same Wi-fi network, then you don't need a TURN server. If connected through mobile data, this could not be the case, so you should have a STUN/TURN server configured. To test the server you can use https://webrtc.github.io/samples/src/content/peerconnection/trickle-ice/.

Secondly, the network quality could influence the connection. You should do a network speed test and remember that latency and jitter is even more important than download/upload speed. You could disable video and test only with audio which eats fewer bandwidth.



来源:https://stackoverflow.com/questions/40041981/android-webrtc-not-working-with-3g-4g

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!