Forums - Getting Audio Data from network

4 posts / 0 new
Last post
Getting Audio Data from network
sashwatkumar.p
Join Date: 14 Nov 17
Posts: 9
Posted: Tue, 2018-01-23 23:10

Hi,

Does MSDC provide an API to retrieve audio data from network? I am trying to implement eMBMS in MCPTT calls and looking for a way to retrieve and process audio data being sent from the server/network. Is there any API which might take an ip and port as parameters and let me retrieve audio data coming from that ip/port?

  • Up0
  • Down0
AnkitK Moderator
Join Date: 20 Aug 14
Posts: 61
Posted: Wed, 2018-01-24 14:36

Dear Customer,

   MSDC SDK 4.2 provides the API to activate the TMGI corresponding to streaming service and UI returns the IP/PORT that UI should bind to to read the data.

Please refer to the MSDC SDK 4.2 documentation.

 

Thanks

Ankit

 

  • Up0
  • Down0
sashwatkumar.p
Join Date: 14 Nov 17
Posts: 9
Posted: Sun, 2018-04-01 18:01

Hi Ankit,

I am using Groupcall Service in order to make eMBMS group calls for our MCPTT application. Once I get the groupcallservicestarted() callback , if i have the IP and PORT information with me, then in order to get audio/rtp data from that ip/port , which msdc api i need to call exactly? As per your suggestion , i checked the MSDC API 4.2 doc, but couldn't find any specific API which talks about get the audio data from the ip/port. When you say "that UI should bind to to read the data" , how do you bind it actually? Kindly help me with this. N.B: I have the activated tmgi information also.

  • Up0
  • Down0
AnkitK Moderator
Join Date: 20 Aug 14
Posts: 61
Posted: Mon, 2018-04-02 13:30

Please refer to the section 5.6.5.2 and the sample code there:

public void groupCallServiceStarted(long tmgi) {

   

         if(mSocket == null){

       //open a multicast socket

       mSocket = new MulticastSocket(PORT);

 

       //Create SocketAddress

       SocketAddress socketAddress =

                                 new InetSocketAddress(MULTICAST_GROUP, PORT);

 

       //Get the NetworkInterface from the interfaceName

       NetworkInterface networkInterface =

                                 NetworkInterface.getByName(interfaceName);

 

       //join the multicast group on given interface name

       mSocket.joinGroup(socketAddress, networkInterface);

  }

 

  if(mLibVLC == null){

       mLibVLC = new LibVLC(this,null);

  }

 

  // To play with LibVLC, we need a media player object.

  if(mMediaPlayer == null){

       mMediaPlayer = new MediaPlayer(mLibVLC);

  }

 

  //Forming the rtp url using multicast group and port

  String mediaURI = "rtp://"++MULTICAST_GROUP+":"+PORT;

 

  // Create a new Media object for the file.

  if(media == null){

        media = new Media(mLibVLC, Uri.parse(mediaURI));

  }

 

  // Tell the media player to play the new Media.

  mMediaPlayer.setMedia(media);

 

  // Finally, play it!

  mMediaPlayer.play();

 

 

     }

Thanks

Ankit

 

  • Up0
  • Down0
or Register

Opinions expressed in the content posted here are the personal opinions of the original authors, and do not necessarily reflect those of Qualcomm Incorporated or its subsidiaries (“Qualcomm”). The content is provided for informational purposes only and is not meant to be an endorsement or representation by Qualcomm or any other party. This site may also provide links or references to non-Qualcomm sites and resources. Qualcomm makes no representations, warranties, or other commitments whatsoever about any non-Qualcomm sites or third-party resources that may be referenced, accessible from, or linked to this site.