#258616 - 21/06/2005 10:58
ASF stream ripper for Linux?
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
A couple of my hometown radio stations just started broadcasting online, and I'd like to record some programs. I've used streamripper in the past for Shoutcast streams, but this station is using Windows (ASF) format. Anyone know of any command-line based stream ripping utils for Linux? The ASF file plays fine in MPlayer, so it should be possible, I just don't know of any such programs for Linux. I'd rather not use some kind of "play it and record the sound card output" solution, I'd like something that goes right from ASF to WAV, MP3, or whatever.
|
Top
|
|
|
|
#258617 - 21/06/2005 11:20
Re: ASF stream ripper for Linux?
[Re: tonyc]
|
carpal tunnel
Registered: 13/07/2000
Posts: 4180
Loc: Cambridge, England
|
Quote: I'd like something that goes right from ASF to WAV, MP3, or whatever.
ASF files are WMA files. If you rename them, the car-player might well be able to play them anyway. Otherwise, if you don't mind transcoding losses, can't you just pipe mplayer's output straight into Lame?
Peter
|
Top
|
|
|
|
#258618 - 21/06/2005 11:22
Re: ASF stream ripper for Linux?
[Re: tonyc]
|
carpal tunnel
Registered: 17/01/2002
Posts: 3996
Loc: Manchester UK
|
I've used Kaffeine under KDE which allowed me to record a show that was in ASF format. It saved it as a WMA file so as peter says it should play on the empeg.
_________________________
Cheers,
Andy M
|
Top
|
|
|
|
#258619 - 21/06/2005 12:20
Re: ASF stream ripper for Linux?
[Re: peter]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Yeah, I know WMA == ASF for all intents and purposes. To be clear (and somewhat heretical) playing on the empeg isn't the concern here. These aren't ASF or WMV files. they're ASF streams. If they were files this would be a non-issue. The software I want would function like streamripper does for Shoutcast, that is, listen to live streams, and save them as some kind of audio format on disk. WMV would be fine for my purposes.
I'll look into Kaffeine, but I'm hoping for something command-line based so I can run it with cron jobs to record specific programs at specific times.
|
Top
|
|
|
|
#258620 - 21/06/2005 12:37
Re: ASF stream ripper for Linux?
[Re: tonyc]
|
carpal tunnel
Registered: 13/07/2000
Posts: 4180
Loc: Cambridge, England
|
Quote: The software I want would function like streamripper does for Shoutcast, that is, listen to live streams, and save them as some kind of audio format on disk. WMV would be fine for my purposes.
Ah, sorry, that wasn't the bit I thought you were having trouble with. Depending on the exact stream format, mplayer is probably still the answer though: mplayer <mms: URL> -dumpstream -dumpfile <outfile>. Not sure how you tell it to only record for a certain duration though -- I got bored of the manpage after the first forty screens.
Peter
|
Top
|
|
|
|
#258621 - 21/06/2005 12:53
Re: ASF stream ripper for Linux?
[Re: peter]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Hmm. That seems to work perfectly. I did scan the mplayer manpage but somehow missed the dumpstream argument.
As for recording duration, I'll see if I can find the magic argument, but if not, I'll just send it SIGQUIT when the time has elapsed.
Thanks!
Edited by tonyc (21/06/2005 12:56)
|
Top
|
|
|
|
#258623 - 21/06/2005 15:43
Re: ASF stream ripper for Linux?
[Re: tonyc]
|
carpal tunnel
Registered: 29/08/2000
Posts: 14493
Loc: Canada
|
No need for a PIDfile.. just have the script that launches it also terminate it.
For example, here (attached) is my bash script I use to record CBC radio, or any other stream.
Eg. save_stream.sh -seconds 20 cbc1
Cheers
Attachments
258219-save_stream.sh (275 downloads)
|
Top
|
|
|
|
#258624 - 21/06/2005 17:05
Re: ASF stream ripper for Linux?
[Re: mlord]
|
carpal tunnel
Registered: 17/01/2002
Posts: 3996
Loc: Manchester UK
|
Nice, shame I can't use it with dvbradio (what I used to record Brads NIN stuff) as there are no command line options that do anything usefull. I just set it recording and stuck a killall -s 9 dvbradio in my crontab at the desired time.
_________________________
Cheers,
Andy M
|
Top
|
|
|
|
#258625 - 21/06/2005 17:14
Re: ASF stream ripper for Linux?
[Re: andym]
|
carpal tunnel
Registered: 29/08/2000
Posts: 14493
Loc: Canada
|
Do you mplayer with the DVB stuff (it apparently supports it)?
|
Top
|
|
|
|
#258626 - 21/06/2005 17:26
Re: ASF stream ripper for Linux?
[Re: mlord]
|
carpal tunnel
Registered: 17/01/2002
Posts: 3996
Loc: Manchester UK
|
Might have to have a look. I'm supposed to be recording another show for him tonight.
_________________________
Cheers,
Andy M
|
Top
|
|
|
|
#258627 - 21/06/2005 18:18
Re: ASF stream ripper for Linux?
[Re: mlord]
|
carpal tunnel
Registered: 27/06/1999
Posts: 7058
Loc: Pittsburgh, PA
|
Indeed, that's almost exactly how I ended up doing it, minus the business with the cache.
|
Top
|
|
|
|
|
|