Closed Emefar closed 1 year ago
Hi @Emefar ,
I think this is normal condition, WebRTC is base on STUN, TURN and ICE tech You can read this article to understand the principle STUN TURN ICE Principle
You can't use the same p2p tunnel, because the private/public IP and NAT are changed after you change network interface from WIFI to LTE
So you need to create a new connection (p2p) after network interface is changed
If you can understand Chinese, you can refer to my blog post P2P tech
I hope you find this information helpful!
@nickhuang9527 Kinesis is generating STUN, TURN and ICE Servers for connection. I think this is a not normal condition. WebRTC apps can change the network state at any time with using TURN.
When a network change occurs, you would need to renegotiate the connection.
See https://stackoverflow.com/questions/68233305/how-to-ice-restart-in-android-peerconnection-client
If the signaling WebSocket is closed, you would also need to re-connect to that so that master can exchange offer/answer/icecandidates with the viewer.
I started live stream with WIFI and i turned off my WIFI and opened LTE. Live stream was frozen. When i turn on WIFI again, everything is good.