title: MediaPlayer Prepare Failed for playing from a remote URL via HTTP streaming
body: <p>I want to play a mp3 file that is hosted remotely. When I do the way shown in this  link <a href="http://developer.android.com/guide/topics/media/mediaplayer.html" rel="nofollow">http://developer.android.com/guide/topics/media/mediaplayer.html</a> , I get the error:</p>
  
  <p><code>java.io.IOException: Prepare failed.: status=0x1</code></p>
  
  <p>After searching through the Web, I found an alternative in this link <a href="http://blog.pocketjourney.com/2008/04/04/tutorial-custom-media-streaming-for-androids-mediaplayer/" rel="nofollow">http://blog.pocketjourney.com/2008/04/04/tutorial-custom-media-streaming-for-androids-mediaplayer/</a>, which does not work very well neither. It downloads the audio file via streaming and creates a temporary .dat file. Each time another increment of the file is downloaded, the MediaPlayer must be stopped so to set the fetched new data to the MediaPlayer. The process plays the audio, but it goes through some little pauses in the way. Its ok to have these pauses because not enough data is downloaded yet, but its not good to have the player paused each time new data is fetched.</p>
  
  <p>So my question is: is there another way to play a remote audio file? Why does this "prepare failed" error occur? I noticed it happens with some mp3's files, but not with others. Is there some kind of malformed mp3 for the MediaPlayer class (and a way to fix it)?</p>
  
  <p>Example: <a href="http://1cd.palco.fm/a/c/4/5/bandainovation-so-hoje.mp3" rel="nofollow">http://1cd.palco.fm/a/c/4/5/bandainovation-so-hoje.mp3</a>. You get the error with this mp3, but you can play it with other players (Banshee or Windows Media Player, for example).</p>
  
  <p>Many thanks in advance</p>