Replies: 9 comments 30 replies
-
How do you retrieve the candidates generated by libdatachannel? |
Beta Was this translation helpful? Give feedback.
-
Hi, after manny hours testing I have meet several issues. I will try to explain here with some logs. I wil set here my configuration and steps I take to perform succesiful datachannel connection. Let see my initial configuration first Configuration set for PeerConnection: rtc::Configuration config;
config.iceServers.emplace_back(std::string("stun.xxxx.io"),3478);
config.iceServers[0].type=rtc::IceServer::Type::Stun;
config.enableIceUdpMux=true; Configuration set for Datachannel rtc::DataChannelInit data_channel_config;
data_channel_config.reliability.unordered=true;
data_channel_config.reliability.maxRetransmits=3;
data_channel_config.negotiated=true;
data_channel_config.protocol="udp"; When caller starts to communicate with calee, sends offer taking this steps:
Calee point of view
Caller point of view
Note1- peer1 (caller or calee) use libdatachannel C++ app<----------------> peer2(caller or calee) use webrtc javascript app Note2- Caller and calle are state of peers. As I said earlier i make test with two peers. First peer is called celler or calee in some point depend on test is libdatachannel C++ program. Other peer caller or calle depend on test is webrtc javasript application: I have met several issues using FireFox and Chrome as peer2 (caller/calee) javascript app. Peers are behind NAT not symetrical. First log is success log(extremly rare) between libdatachannel c++ app and Chrome javascript webrtc app.
|
Beta Was this translation helpful? Give feedback.
-
Thanks for your help. I will correct with suggestions you provide!!! |
Beta Was this translation helpful? Give feedback.
-
So I have set changes your suggest, but the problem with Chrome and FF remains. I mean with FF almost 100% connection is done via my C++ app using libdatachannel and webrtc using javascript app, but with Chrome 99% is oposite- connection creation is verry rare between peers under same conditions for Chrome and FF. Can you help me with something? 10x!! |
Beta Was this translation helpful? Give feedback.
-
Wait, I am not trying this. Ok I will and let you know. 10x. |
Beta Was this translation helpful? Give feedback.
-
Ok, my test case is like this: |
Beta Was this translation helpful? Give feedback.
-
Ok, I have new information about Chrome and FF connection. When I add 200ms delay in function where process Ice candidates before peerConn->addRemoteCandidate(candidate) conn is done in Chrome. Why is that?10x for your time! |
Beta Was this translation helpful? Give feedback.
-
Can you check this fragment of code located in https://github.com/paullouisageneau/libdatachannel/blob/master/src/impl/peerconnection.cpp#L1076 if (auto iceTransport = weakIceTransport.lock()) |
Beta Was this translation helpful? Give feedback.
-
Sorry I wasn't clear, I meant trying the web example with the client example, just to rule out an issue with Chrome.
This very probably means that there is a race condition in your signaling code. |
Beta Was this translation helpful? Give feedback.
-
I have wonder why candidates doesn not include srflx raddr of mine? For example I have ipv4 inner address and ipv6 inner address, but I have ipv4 and ipv6 real address bound to my Router interface for NAT. My configuration is:
rtc::Configuration config;
config.enableIceUdpMux = true;
config.iceServers.emplace_back(std::string("stun:stun.l.google.com:19302"));
config.certificateType=rtc::CertificateType::Default;
config.iceServers[0].type=rtc::IceServer::Type::Stun;
This is ice candidates generated from libdatachannel:
My ice candidate generated by libdatachannel
This is other side peer ice candidates generated by chrome
X.X.X.X is my realIP
And finally I cannot open a datachannel remotly (peer->INternet->peer)? But if I run all this locally the datachannel is open (peer->localNet->peer)
Beta Was this translation helpful? Give feedback.
All reactions