-1

Hi tried to stream an audio but i am getting the following error constantly for two days... plz tell me where i am going wrong....plz clear me how to overcome this...

  DEBUG/MediaPlayer(497): Couldn't open file on client side, trying server side
  INFO/StagefrightPlayer(34): setDataSource('http://stream.radiosai.net:8002/')
  DEBUG/AudioDemo(497): LoadClip Done
  DEBUG/dalvikvm(115): GC_EXPLICIT freed 689 objects / 39080 bytes in 150ms
  INFO/AwesomePlayer(34): calling prefetcher->prepare()
  INFO/Prefetcher(34): [0x677328] cache below low water mark, filling cache.
  INFO/AwesomePlayer(34): prefetcher is done preparing
  DEBUG/AudioDemo(497): Stream is prepared
  DEBUG/AudioSink(34): bufferCount (4) is too small and increased to 12
  WARN/AudioFlinger(34): write blocked for 77 msecs, 4773 delayed writes, thread 0xb3f0
  ERROR/AwesomePlayer(34): Not sending buffering status because duration is unknown.
  DEBUG/dalvikvm(387): GC_EXPLICIT freed 167 objects / 11832 bytes in 141ms
  WARN/AudioFlinger(34): write blocked for 82 msecs, 4804 delayed writes, thread 0xb3f0
  DEBUG/dalvikvm(262): GC_EXPLICIT freed 44 objects / 2032 bytes in 143ms
  WARN/AudioFlinger(34): write blocked for 73 msecs, 4841 delayed writes, thread 0xb3f0
user1051599
  • 371
  • 2
  • 7
  • 18

3 Answers3

0

http://stream.radiosai.net:8002/ is not a valid media file, it's a website (html file).

Also check if the media format is supported by Android: http://developer.android.com/guide/appendix/media-formats.html

Mathias Conradt
  • 28,420
  • 21
  • 138
  • 192
  • sorry i am using this following link stream.radiosai.net:8002/listen.pls this also not playing is this file supported in android.. – user1051599 Nov 22 '11 at 12:59
0

http://stream.radiosai.net:8002/ this Shoutcast type. link opens only on android 2.2+ !!!

alezhka
  • 738
  • 2
  • 12
  • 29
0

open .pls link:

 public ArrayList<String> readURLs(String url) {             
            if(url == null) return false;
            ArrayList<String> allURls = new ArrayList<String>();
            try {

                URL urls = new URL(url);
                BufferedReader in = new BufferedReader(new InputStreamReader(urls
                        .openStream()));
                String str;
                while ((str = in.readLine()) != null) {
                    allURls.add(str);
                }
                in.close();
                return allURls ;
            } catch (Exception e) {
                e.printStackTrace();
                return null;
            } 
        }

then parse link and playing.

alezhka
  • 738
  • 2
  • 12
  • 29
  • steps: 1. readURLs, 2. parse link 3. prepare stream 4. play http://stackoverflow.com/questions/6688758/streaming-m3u-audio – alezhka Nov 22 '11 at 13:23