Categories
Android ffmpeg linux Music Networking Solutions Stream

FFMpeg with Lame MP3 and streaming for the Arduino Yun

So, I’ve been trying to stream audio off of a USB microphone connected to an Arduino Yun.
Looking into it online I found some examples using ffserver & ffmpeg, which sounded like they could do the trick.
However right from the start I’ve had many problems with playing the streams on Android and iOS devices.
Seems Android likes a certain list of codecs (http://developer.android.com/guide/appendix/media-formats.html) and iOS like a different set of codecs (Link here), but they do have on codec in common – good ol’ MP3.
Unfortunately, the OpenWRT on the Arduino Yun has an ffmpeg build which does not provide MP3 encoding… it does have the MP3 muxer/container format, but streaming anything other then MP3 in it (for example MP2, which the Yun-ffmpeg does have) simply doesn’t work on the Android/iOS.
From experiments streaming from my PC a ffmpeg/libmp3lame MP3 stream, it looks like the mobile devices are quite happy with it – so I will need to recompile ffmpeg with Lame MP3 support to be able to stream it.

Categories
code linux python Recommended Software Solutions video Website

Download all your Last.fm loved tracks in two simple steps

I’m a fan of Last.fm online radio, and I have a habit of marking every good song that I hear as a “loved track”. Over the years I got quite a list, and so I decided to turn it into my jogging playlist. But for that, I need all the songs downloaded to my computer so I can put them on my mobile. While Last.fm does link to Amazon for downloading all the loved songs for pay, I’m going to walk the fine moral line here and suggest how you can download every song from existing free YouTube videos.
If it really bothers you, think of it as if I created a YouTube playlist and now I’m using my data plan to stream the songs off YT itself..
Moral issues resolved, we can move on to the scripting.
Update (4/27/12): youtube-dl.py has moved: https://github.com/rg3/youtube-dl/, and also added a very neat –extract-audio option so you can get the songs in audio right away (it basically does a conversion in a second step).