zf8848 / libjingle

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

Call sample program problem! (call is established but no voice) #80

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Install libjingle-0.5
2. Execute call sample program (./call --d)
3. Call to someone

What is the expected output? What do you see instead?
Call to someone. The other side user receives the invitation and answers the 
call. The call is established but no voice can be heard from any side.

Below, you can see the XMPP messages exchanged executing call on debug mode:

Found online friend 'mahntalin78@gmail.com/Talk.v1044246CC00'
(call) SEND >>>>>>>>>>>>>>>> : Fri Oct 29 14:29:32 2010
   <iq to="mahntalin78@gmail.com/Talk.v1044246CC00" type="set" id="8">
     <jingle xmlns="urn:xmpp:jingle:1" action="session-initiate" id="1176914979" initiator="fe.mesquita88@gmail.com/call72EEBF71">
       <content name="audio" creator="initiator">
         <description xmlns="urn:xmpp:jingle:apps:rtp:1" media="audio"/>
         <transport xmlns="http://www.google.com/transport/p2p"/>
       </content>
     </jingle>
     <session xmlns="http://www.google.com/session" type="initiate" id="1176914979" initiator="fe.mesquita88@gmail.com/call72EEBF71">
       <description xmlns="http://www.google.com/session/phone"/>
     </session>
   </iq>
RECV <<<<<<<<<<<<<<<< : Fri Oct 29 14:29:33 2010
   <iq to="fe.mesquita88@gmail.com/call72EEBF71" id="8" type="result" from="mahntalin78@gmail.com/Talk.v1044246CC00"/>
RECV <<<<<<<<<<<<<<<< : Fri Oct 29 14:29:34 2010
   <iq to="fe.mesquita88@gmail.com/call72EEBF71" type="set" id="34" from="mahntalin78@gmail.com/Talk.v1044246CC00">
     <session type="candidates" id="1176914979" initiator="fe.mesquita88@gmail.com/call72EEBF71" xmlns="http://www.google.com/session">
       <candidate name="rtp" address="10.239.0.5" port="1687" preference="1" username="d/8K6PYWBCmyX2fG" protocol="udp" generation="0" password="fZJQmOJyeT4tOg6s" type="local" network="0"/>
     </session>
   </iq>
SEND >>>>>>>>>>>>>>>> : Fri Oct 29 14:29:34 2010
   <iq to="mahntalin78@gmail.com/Talk.v1044246CC00" id="34" type="error">
     <session type="candidates" id="1176914979" initiator="fe.mesquita88@gmail.com/call72EEBF71" xmlns="http://www.google.com/session">
       <candidate name="rtp" address="10.239.0.5" port="1687" preference="1" username="d/8K6PYWBCmyX2fG" protocol="udp" generation="0" password="fZJQmOJyeT4tOg6s" type="local" network="0"/>
     </session>
     <error type="modify">
       <sta:bad-request xmlns:sta="urn:ietf:params:xml:ns:xmpp-stanzas"/>
       <sta:text xml:lang="en" xmlns:sta="urn:ietf:params:xml:ns:xmpp-stanzas">
         channel named in candidate does not exist: rtp for content: audio
       </sta:text>
     </error>
   </iq>
RECV <<<<<<<<<<<<<<<< : Fri Oct 29 14:29:37 2010
   <iq to="fe.mesquita88@gmail.com/call72EEBF71" type="set" id="40" from="mahntalin78@gmail.com/Talk.v1044246CC00">
     <session type="accept" id="1176914979" initiator="fe.mesquita88@gmail.com/call72EEBF71" xmlns="http://www.google.com/session">
       <description xml:lang="en" xmlns="http://www.google.com/session/phone">
         <payload-type id="103" name="ISAC" clockrate="16000"/>
         <payload-type id="0" name="PCMU" clockrate="8000" bitrate="64000"/>
       </description>
     </session>
   </iq>
SEND >>>>>>>>>>>>>>>> : Fri Oct 29 14:29:37 2010
   <iq to="mahntalin78@gmail.com/Talk.v1044246CC00" id="40" type="result"/>

(mahntalin78@gmail.com/Talk.v1044246CC00) RECV <<<<<<<<<<<<<<<< : Fri Oct 29 
14:29:53 2010
   <iq to="fe.mesquita88@gmail.com/call72EEBF71" type="set" id="41" from="mahntalin78@gmail.com/Talk.v1044246CC00">
     <session type="candidates" id="1176914979" initiator="fe.mesquita88@gmail.com/call72EEBF71" xmlns="http://www.google.com/session">
       <candidate name="rtp" address="10.239.0.5" port="1698" preference="1" username="YsYQipLvXYa3k+9K" protocol="udp" generation="1" password="1pf5pPvIDy0xiGgr" type="local" network="0"/>
     </session>
   </iq>
SEND >>>>>>>>>>>>>>>> : Fri Oct 29 14:29:53 2010
   <iq to="mahntalin78@gmail.com/Talk.v1044246CC00" id="41" type="error">
     <session type="candidates" id="1176914979" initiator="fe.mesquita88@gmail.com/call72EEBF71" xmlns="http://www.google.com/session">
       <candidate name="rtp" address="10.239.0.5" port="1698" preference="1" username="YsYQipLvXYa3k+9K" protocol="udp" generation="1" password="1pf5pPvIDy0xiGgr" type="local" network="0"/>
     </session>
     <error type="modify">
       <sta:bad-request xmlns:sta="urn:ietf:params:xml:ns:xmpp-stanzas"/>
       <sta:text xml:lang="en" xmlns:sta="urn:ietf:params:xml:ns:xmpp-stanzas">
         channel named in candidate does not exist: rtp for content: audio
       </sta:text>
     </error>
   </iq>

(mahntalin78@gmail.com/Talk.v1044246CC00) RECV <<<<<<<<<<<<<<<< : Fri Oct 29 
14:30:04 2010
   <iq to="fe.mesquita88@gmail.com/call72EEBF71" type="set" id="46" from="mahntalin78@gmail.com/Talk.v1044246CC00">
     <session type="terminate" id="1176914979" initiator="fe.mesquita88@gmail.com/call72EEBF71" xmlns="http://www.google.com/session"/>
   </iq>
SEND >>>>>>>>>>>>>>>> : Fri Oct 29 14:30:04 2010
   <iq to="mahntalin78@gmail.com/Talk.v1044246CC00" id="46" type="result"/>

What version of the product are you using? On what operating system?
libjingle-0.5 on Ubuntu 10.04

Please provide any additional information below.
The logs shows an error:
'channel named in candidate does not exist: rtp for content: audio'
This message keeps repeating in a short period of interval

Any ideas?

Original issue reported on code.google.com by fe.mesqu...@gmail.com on 29 Oct 2010 at 4:42

GoogleCodeExporter commented 9 years ago
Thanks for the detailed log.  I just tested the latest libjingle call (in 
examples/call) calling a Google Talk windows native client, and it worked fine. 
 I also test calling gmail on a regular basis, and that works fine.  I'm unable 
to reproduce this.

This error would happen if the initiating client doesn't create a voice channel 
correct.  If you can debug your client a little (perhaps with a debugger), you 
ought to look at session/phone/call.cc line 210 where it calls 
"CreateVoiceChannel".  The value of "audio_offer->name" should be "audio", and 
the return value of voice_channel should non-NULL.  If those two things are 
true, you should not get the error about the channel not existing.  If the 
return value is NULL or the name is not "audio", then you will get that error.  
Or, of course, if Call::AddSession is never called in the first place.

Please debug a little and let me know what you find. 

Original comment by pthatc...@google.com on 2 Nov 2010 at 6:48

GoogleCodeExporter commented 9 years ago
Hi pthatcher@google.com, first of all thanks for your answer.

You said you've tested the 'call' program and it worked fine. But, you executed 
the 'call' program passing the voice.rtpdump file? I just found out that 
passing the voice.rtpdump file as line command, the other side can listen to 
the audio. Same using the video.rtpdump file, i.e: the other side can see the 
video recorded.
But now, without any rtpdump files, can you communicate to the other side, with 
your voice? I also found out that you guys removed the linphone files from 
version 0.4 to 0.5 (linphonemediaengine.cc and linphonemediaengine.h). Can this 
be the problem? Do I need the linphone files on version 0.5+ to be able to 
communicate with my voice to other party? I've already downloaded the 
linphone-dev libs
Am I missing anything?

Once again, thanks for your time.

Original comment by fe.mesqu...@gmail.com on 3 Nov 2010 at 4:39

GoogleCodeExporter commented 9 years ago
You don't need the linphone libraries.  I've been testing without them.  I've 
been testing with the test rtpdump files that are in session/phone/testdata. 

You can use rtpdump files for either input or output.  It sounds like you've 
successfully used them for input.  It's safe to use only input and no output.  
The call will still work.  You just won't hear or see anything from the other 
end.

I think the best way to figure out what's going on is to debug that link I 
mentioned in call.cc, either with a debugger or with print statement.  Either 
way, you need to know if the content_name is "audio" and if the voice channel 
was successfully created or not. 

Original comment by pthatc...@google.com on 3 Nov 2010 at 10:05

GoogleCodeExporter commented 9 years ago
Hi,

Can anyone please tell me how you got the logs for libjingle??i tried through 
wireshark but not able to get it.I get something like truncated string such as  
:  \x80O\x01\x03\x01     ......I this this is encrypted.
Please help me out.

Original comment by satya.bh...@gmail.com on 11 Nov 2010 at 9:18

GoogleCodeExporter commented 9 years ago
Hello satya.bhukar,

Try executing the program with --d option. E.g: ./call --d

This is the debug mode which will print all XMPP messages exchanged...

Good Luck.

Original comment by fe.mesqu...@gmail.com on 11 Nov 2010 at 11:34

GoogleCodeExporter commented 9 years ago
Hi All,

I implemented my own voice engine, and i tried to call my desktop gtalk client, 
it worked, but I got timeout error when i tried to call a gmail client. My 
gmail client can receive the call, can answer the call, but nothing happened on 
my own client side, about 10 seconds later, my client app got an error which is 
captured by Call::OnMessage in call.cc, and the error message is a 
"MSG_TERMINATECALL" message, and the comment in the code says "Signal to the 
user that a timeout has happened and the call should be sent to voicemail"

I checked the logs and found my client app successfully sent its candidate list 
to the gmail client, but the gmail client didn't send the candidate list to my 
client app, then my client app timed out.

Did i miss anything in my impl? Any help will be highly appreciated.

Cheers

Original comment by interfac...@gmail.com on 5 Mar 2011 at 11:03

GoogleCodeExporter commented 9 years ago
Hi pthatcher@google.com,

I met the same problem as fe.mesquita88. I debugged into method 
CreateVoiceChannel and found below things.

in "CreationParams params(session, content_name, rtcp, NULL);", it transfers 
"NULL" into "params.voice_channel" which cause voice_channel always to be null.

What should I do now?

BR

Original comment by xnh...@gmail.com on 21 Apr 2011 at 3:04

GoogleCodeExporter commented 9 years ago
If possible, please download and try it on the latest version of libjingle 
(0.5.6) for now. Also, please use file media engine with the following command:
call.exe -d --videoinput=..\..\..\session\phone\testdata\video.rtpdump 
--voiceinput=..\..\..\session\phone\testdata\voice.rtpdump 
--videooutput=vout.rtpdump --voiceoutput=aout.rtpdump

This should work. Please open another issue if you run into any problems.

Original comment by jun...@google.com on 15 Jun 2011 at 12:09