![]() | Audio Hello World, setDataSourceFD failed |
|
25 May 2011, 22:36
Wilhelm Fitzpatrick (2 posts) |
Ran into the following interesting problem with the Audio Hello World example: It worked in the emulator, but failed with an IOException (setDataSourceFD failed) on my Nexus S (2.3.4). After much headscratching, and discovering that the exception occurred for a.mp3, but not for example for f.mp3, I inspected the sample files with the Linux file command and discovered the following: a, d, down and enter reported as: while the rest of the files reported as: Using Audacity to re-encode the first four to match the remaining ones solved the problems. My assumption is that my phone doesn’t include a WAVE codec, although it would have been nice if the error message had been more informative. At any rate, I offer this detail in the hopes that anybody else stumbling over this will figure out how to move forward. |
|
26 May 2011, 18:57
Ed Burnette (1316 posts) |
Thanks for sharing the info, it’s very helpful. All the Galaxy S phones seem to have quirks in their audio system. Up to now I had just heard of problems on the recording side. I think next time I need audio I’m going to use the .ogg format. It goes through a simpler code path and has fewer problems overall. |
| You must be logged in to comment |

