sox-users@lists.sourceforge.net unofficial mirror
 help / color / Atom feed
* Recording in chunks using sox
       [not found] <790552421.2332795.1503680652651.ref@mail.yahoo.com>
@ 2017-08-25 17:04 ` Eyob Yirdaw via Sox-users
  2017-08-25 17:20   ` Graff, David E
                     ` (3 more replies)
  0 siblings, 4 replies; 9+ messages in thread
From: Eyob Yirdaw via Sox-users @ 2017-08-25 17:04 UTC (permalink / raw)
  To: sox-users; +Cc: Eyob Yirdaw

[-- Attachment #1.1: Type: text/plain, Size: 491 bytes --]

Hi all,
I want to record 24/7 transmission of FM radios using DVB-T dongles.  I want to direct the input audio from some dongle to sox, eg. something like
rtl_fm -f 88.8M -d 0 -M wbfm | sox -r 32k -t s16 - -t ogg device_0.ogg
here am using the rtl_fm terminal program.

Can sox help me save the continuous FM audio that comes from rtl_fm to be saved in some time length chunks, say 10 minute long chunks?It means that sox would write to disc every 10 minutes.

Thanks for any help!

[-- Attachment #1.2: Type: text/html, Size: 1407 bytes --]

<html><head></head><body><div style="color:#000; background-color:#fff; font-family:標楷體, dfkai-sb;font-size:16px"><div id="yui_3_16_0_ym19_1_1503680124999_6593" dir="ltr">Hi all,</div><div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6680"><br></div><div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6679">I want to record 24/7 transmission of FM radios using DVB-T dongles.&nbsp; I want to direct the input audio from some dongle to sox, eg. something like</div><div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6619"><br></div><div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6620">rtl_fm -f 88.8M -d 0 -M wbfm | sox -r 32k -t s16 - -t ogg device_0.ogg</div><div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6656"><br></div><div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6657">here am using the rtl_fm terminal program.<br></div><div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6658"><br></div><div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6659">Can sox help me save the continuous FM audio that comes from rtl_fm to be saved in some time length chunks, say 10 minute long chunks?</div><div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6670">It means that sox would write to disc every 10 minutes.<br></div><div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6661"><br></div><div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6662">Thanks for any help!<br></div></div></body></html>

[-- Attachment #2: Type: text/plain, Size: 202 bytes --]

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot

[-- Attachment #3: Type: text/plain, Size: 158 bytes --]

_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Recording in chunks using sox
  2017-08-25 17:04 ` Recording in chunks using sox Eyob Yirdaw via Sox-users
@ 2017-08-25 17:20   ` Graff, David E
  2017-08-25 18:11   ` Peter P.
                     ` (2 subsequent siblings)
  3 siblings, 0 replies; 9+ messages in thread
From: Graff, David E @ 2017-08-25 17:20 UTC (permalink / raw)
  To: Eyob Yirdaw, sox-users

[-- Attachment #1.1: Type: text/plain, Size: 1339 bytes --]

My first intuition on this would be to have your continuous a/d process pipe to some custom process (not sox), which simply takes a binary stream on stdin and creates a continuous series of data files on disk of equal length (e.g. 20 minutes worth of samples, or whatever seems like a good interval), using some reasonable template pattern for file names.


Then, there'd be a separate process (running continuously) that scans for new files at regular intervals, and runs sox on each new file, converting it from raw to whatever format you want as a final product.


  Dave Graff

________________________________
From: Eyob Yirdaw via Sox-users <sox-users@lists.sourceforge.net>
Sent: Friday, August 25, 2017 1:04:12 PM
To: sox-users@lists.sourceforge.net
Cc: Eyob Yirdaw
Subject: [SoX-users] Recording in chunks using sox

Hi all,

I want to record 24/7 transmission of FM radios using DVB-T dongles.  I want to direct the input audio from some dongle to sox, eg. something like

rtl_fm -f 88.8M -d 0 -M wbfm | sox -r 32k -t s16 - -t ogg device_0.ogg

here am using the rtl_fm terminal program.

Can sox help me save the continuous FM audio that comes from rtl_fm to be saved in some time length chunks, say 10 minute long chunks?
It means that sox would write to disc every 10 minutes.

Thanks for any help!

[-- Attachment #1.2: Type: text/html, Size: 2911 bytes --]

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
</head>
<body>
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<p>My first intuition on this would be to have your continuous a/d process pipe to some custom process (not sox), which simply takes a&nbsp;binary stream on stdin and creates a continuous series of data files on disk of equal length (e.g. 20 minutes worth of samples,
 or whatever seems like a good interval), using some reasonable template pattern for file names.</p>
<p><br>
</p>
<p>Then, there'd be a separate process (running continuously) that scans for new files at regular intervals, and runs sox on each new&nbsp;file, converting it from raw to whatever format you want as a final product.</p>
<p><br>
</p>
<p>&nbsp; Dave Graff</p>
</div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Eyob Yirdaw via Sox-users &lt;sox-users@lists.sourceforge.net&gt;<br>
<b>Sent:</b> Friday, August 25, 2017 1:04:12 PM<br>
<b>To:</b> sox-users@lists.sourceforge.net<br>
<b>Cc:</b> Eyob Yirdaw<br>
<b>Subject:</b> [SoX-users] Recording in chunks using sox</font>
<div>&nbsp;</div>
</div>
<div>
<div style="color:#000; background-color:#fff; font-family:&#27161;&#26999;&#39636;, dfkai-sb;font-size:16px">
<div id="yui_3_16_0_ym19_1_1503680124999_6593" dir="ltr">Hi all,</div>
<div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6680"><br>
</div>
<div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6679">I want to record 24/7 transmission of FM radios using DVB-T dongles.&nbsp; I want to direct the input audio from some dongle to sox, eg. something like</div>
<div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6619"><br>
</div>
<div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6620">rtl_fm -f 88.8M -d 0 -M wbfm | sox -r 32k -t s16 - -t ogg device_0.ogg</div>
<div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6656"><br>
</div>
<div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6657">here am using the rtl_fm terminal program.<br>
</div>
<div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6658"><br>
</div>
<div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6659">Can sox help me save the continuous FM audio that comes from rtl_fm to be saved in some time length chunks, say 10 minute long chunks?</div>
<div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6670">It means that sox would write to disc every 10 minutes.<br>
</div>
<div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6661"><br>
</div>
<div dir="ltr" id="yui_3_16_0_ym19_1_1503680124999_6662">Thanks for any help!<br>
</div>
</div>
</div>
</body>
</html>

[-- Attachment #2: Type: text/plain, Size: 202 bytes --]

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot

[-- Attachment #3: Type: text/plain, Size: 158 bytes --]

_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Recording in chunks using sox
  2017-08-25 17:04 ` Recording in chunks using sox Eyob Yirdaw via Sox-users
  2017-08-25 17:20   ` Graff, David E
@ 2017-08-25 18:11   ` Peter P.
  2017-08-25 18:18     ` Graff, David E
  2017-08-25 18:12   ` Jan Stary
  2017-08-26 13:54   ` Jeremy Nicoll - ml sox users
  3 siblings, 1 reply; 9+ messages in thread
From: Peter P. @ 2017-08-25 18:11 UTC (permalink / raw)
  To: sox-users

* Eyob Yirdaw via Sox-users <sox-users@lists.sourceforge.net> [2017-08-25 19:08]:
> Hi all,
> I want to record 24/7 transmission of FM radios using DVB-T dongles.  I want to direct the input audio from some dongle to sox, eg. something like
> rtl_fm -f 88.8M -d 0 -M wbfm | sox -r 32k -t s16 - -t ogg device_0.ogg
> here am using the rtl_fm terminal program.
> 
> Can sox help me save the continuous FM audio that comes from rtl_fm to be saved in some time length chunks, say 10 minute long chunks?It means that sox would write to disc every 10 minutes.
Perhaps look at the examples for the commands "newfile" and "restart" in
SoX's manpage.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Recording in chunks using sox
  2017-08-25 17:04 ` Recording in chunks using sox Eyob Yirdaw via Sox-users
  2017-08-25 17:20   ` Graff, David E
  2017-08-25 18:11   ` Peter P.
@ 2017-08-25 18:12   ` Jan Stary
  2017-08-25 18:18     ` Jan Stary
  2017-08-26 13:54   ` Jeremy Nicoll - ml sox users
  3 siblings, 1 reply; 9+ messages in thread
From: Jan Stary @ 2017-08-25 18:12 UTC (permalink / raw)
  To: sox-users

On Aug 25 17:04:12, sox-users@lists.sourceforge.net wrote:
> I want to record 24/7 transmission of FM radios

Why?

> using DVB-T dongles.  I want to direct the input audio
> from some dongle to sox, eg. something like
> rtl_fm -f 88.8M -d 0 -M wbfm | sox -r 32k -t s16 - -t ogg device_0.ogg
> here am using the rtl_fm terminal program.

Why do you want to convert from the original format to ogg?

> Can sox help me save the continuous FM audio that comes from rtl_fm to be saved in some time length chunks, say 10 minute long chunks?

Yes


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Recording in chunks using sox
  2017-08-25 18:12   ` Jan Stary
@ 2017-08-25 18:18     ` Jan Stary
  0 siblings, 0 replies; 9+ messages in thread
From: Jan Stary @ 2017-08-25 18:18 UTC (permalink / raw)
  To: sox-users

On Aug 25 20:12:44, hans@stare.cz wrote:
> > I want to direct the input audio
> > from some dongle to sox, eg. something like
> > rtl_fm -f 88.8M -d 0 -M wbfm | sox -r 32k -t s16 - -t ogg device_0.ogg
> > here am using the rtl_fm terminal program.
> 
> Why do you want to convert from the original format to ogg?

See the attached script and its config.
This is what I call from cron as in 

00 06 * * 6   radio jazz   3600 $RADIO/`date +\%Y\%m\%d`-jazzrock.mp3

to download the radio shows I like. Note that this functionality
has nothing to do with SoX - the stream is just dumped to a file.

	Jan


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Recording in chunks using sox
  2017-08-25 18:11   ` Peter P.
@ 2017-08-25 18:18     ` Graff, David E
  2017-08-26 12:42       ` Eyob Yirdaw via Sox-users
  0 siblings, 1 reply; 9+ messages in thread
From: Graff, David E @ 2017-08-25 18:18 UTC (permalink / raw)
  To: sox-users

[-- Attachment #1.1: Type: text/plain, Size: 1342 bytes --]

Note to self: read the man page before acting on the "initial intuition".  Thanks, Peter!


  Dave G.

________________________________
From: Peter P. <peterparker@fastmail.com>
Sent: Friday, August 25, 2017 2:11:14 PM
To: sox-users@lists.sourceforge.net
Subject: Re: [SoX-users] Recording in chunks using sox

* Eyob Yirdaw via Sox-users <sox-users@lists.sourceforge.net> [2017-08-25 19:08]:
> Hi all,
> I want to record 24/7 transmission of FM radios using DVB-T dongles.  I want to direct the input audio from some dongle to sox, eg. something like
> rtl_fm -f 88.8M -d 0 -M wbfm | sox -r 32k -t s16 - -t ogg device_0.ogg
> here am using the rtl_fm terminal program.
>
> Can sox help me save the continuous FM audio that comes from rtl_fm to be saved in some time length chunks, say 10 minute long chunks?It means that sox would write to disc every 10 minutes.
Perhaps look at the examples for the commands "newfile" and "restart" in
SoX's manpage.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users

[-- Attachment #1.2: Type: text/html, Size: 2536 bytes --]

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from text --><style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<meta content="text/html; charset=UTF-8">
<style type="text/css" style="">
<!--
p
	{margin-top:0;
	margin-bottom:0}
-->
</style>
<div dir="ltr">
<div id="x_divtagdefaultwrapper" dir="ltr" style="font-size:12pt; color:#000000; font-family:Calibri,Helvetica,sans-serif">
<p>Note to self: read the man page before acting on the &quot;initial intuition&quot;. &nbsp;Thanks, Peter!</p>
<p><br>
</p>
<p>&nbsp; Dave G.</p>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="x_divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> Peter P. &lt;peterparker@fastmail.com&gt;<br>
<b>Sent:</b> Friday, August 25, 2017 2:11:14 PM<br>
<b>To:</b> sox-users@lists.sourceforge.net<br>
<b>Subject:</b> Re: [SoX-users] Recording in chunks using sox</font>
<div>&nbsp;</div>
</div>
</div>
<font size="2"><span style="font-size:10pt;">
<div class="PlainText">* Eyob Yirdaw via Sox-users &lt;sox-users@lists.sourceforge.net&gt; [2017-08-25 19:08]:<br>
&gt; Hi all,<br>
&gt; I want to record 24/7 transmission of FM radios using DVB-T dongles.&nbsp; I want to direct the input audio from some dongle to sox, eg. something like<br>
&gt; rtl_fm -f 88.8M -d 0 -M wbfm | sox -r 32k -t s16 - -t ogg device_0.ogg<br>
&gt; here am using the rtl_fm terminal program.<br>
&gt; <br>
&gt; Can sox help me save the continuous FM audio that comes from rtl_fm to be saved in some time length chunks, say 10 minute long chunks?It means that sox would write to disc every 10 minutes.<br>
Perhaps look at the examples for the commands &quot;newfile&quot; and &quot;restart&quot; in<br>
SoX's manpage.<br>
<br>
------------------------------------------------------------------------------<br>
Check out the vibrant tech community on one of the world's most<br>
engaging tech sites, Slashdot.org! <a href="http://sdm.link/slashdot">http://sdm.link/slashdot</a><br>
_______________________________________________<br>
Sox-users mailing list<br>
Sox-users@lists.sourceforge.net<br>
<a href="https://lists.sourceforge.net/lists/listinfo/sox-users">https://lists.sourceforge.net/lists/listinfo/sox-users</a><br>
</div>
</span></font>
</body>
</html>

[-- Attachment #2: Type: text/plain, Size: 202 bytes --]

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot

[-- Attachment #3: Type: text/plain, Size: 158 bytes --]

_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Recording in chunks using sox
  2017-08-25 18:18     ` Graff, David E
@ 2017-08-26 12:42       ` Eyob Yirdaw via Sox-users
  2017-08-27 14:37         ` Jan Stary
  0 siblings, 1 reply; 9+ messages in thread
From: Eyob Yirdaw via Sox-users @ 2017-08-26 12:42 UTC (permalink / raw)
  To: sox-users; +Cc: Eyob Yirdaw

[-- Attachment #1.1: Type: text/plain, Size: 2412 bytes --]

Well thanks so much guys! I really love the open source community. You really are so awesome to find the time to help guys in need.

@Peter: i will try ur suggestion. I still have to order the dongle by the way. I just needed to be sure the overall process of recording it in batches.
@David: I think ur idea is excellent too! I ll go with Peter's idea first.
@Jan: Well am not getting any attachment in your message.
 

    On Friday, 25 August 2017, 21:19, "Graff, David E" <graff@ldc.upenn.edu> wrote:
 

 #yiv9726572776 #yiv9726572776 -- .yiv9726572776EmailQuote {margin-left:1pt;padding-left:4pt;border-left:#800000 2px solid;}#yiv9726572776 #yiv9726572776 #yiv9726572776 --p {margin-top:0;margin-bottom:0;}#yiv9726572776 Note to self: read the man page before acting on the "initial intuition".  Thanks, Peter!
  Dave G.From: Peter P. <peterparker@fastmail.com>
Sent: Friday, August 25, 2017 2:11:14 PM
To: sox-users@lists.sourceforge.net
Subject: Re: [SoX-users] Recording in chunks using sox * Eyob Yirdaw via Sox-users <sox-users@lists.sourceforge.net> [2017-08-25 19:08]:
> Hi all,
> I want to record 24/7 transmission of FM radios using DVB-T dongles.  I want to direct the input audio from some dongle to sox, eg. something like
> rtl_fm -f 88.8M -d 0 -M wbfm | sox -r 32k -t s16 - -t ogg device_0.ogg
> here am using the rtl_fm terminal program.
> 
> Can sox help me save the continuous FM audio that comes from rtl_fm to be saved in some time length chunks, say 10 minute long chunks?It means that sox would write to disc every 10 minutes.
Perhaps look at the examples for the commands "newfile" and "restart" in
SoX's manpage.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users


   

[-- Attachment #1.2: Type: text/html, Size: 5283 bytes --]

<html><head></head><body><div style="color:#000; background-color:#fff; font-family:標楷體, dfkai-sb;font-size:16px"><div id="yui_3_16_0_ym19_1_1503743096374_19843">Well thanks so much guys! I really love the open source community. You really are so awesome to find the time to help guys in need.<br></div><div id="yui_3_16_0_ym19_1_1503743096374_19844"><br></div><div id="yui_3_16_0_ym19_1_1503743096374_21407">@Peter: i will try ur suggestion. I still have to order the dongle by the way. I just needed to be sure the overall process of recording it in batches.</div><div id="yui_3_16_0_ym19_1_1503743096374_21435"><br></div><div id="yui_3_16_0_ym19_1_1503743096374_24854">@David: I think ur idea is excellent too! I ll go with Peter's idea first.</div><div id="yui_3_16_0_ym19_1_1503743096374_24855"><br></div><div id="yui_3_16_0_ym19_1_1503743096374_26477">@Jan: Well am not getting any attachment in your message.<br></div><div id="yui_3_16_0_ym19_1_1503743096374_21529"><span></span></div> <div class="qtdSeparateBR"><br><br></div><div style="display: block;" class="yahoo_quoted"> <div style="font-family: 標楷體, dfkai-sb; font-size: 16px;"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, Sans-Serif; font-size: 16px;"> <div dir="ltr"><font face="Arial" size="2"> On Friday, 25 August 2017, 21:19, "Graff, David E" &lt;graff@ldc.upenn.edu&gt; wrote:<br></font></div>  <br><br> <div class="y_msg_container"><div id="yiv9726572776"><style>#yiv9726572776 #yiv9726572776 -- .yiv9726572776EmailQuote {margin-left:1pt;padding-left:4pt;border-left:#800000 2px solid;}#yiv9726572776 </style><div>
</div><style type="text/css">
#yiv9726572776 #yiv9726572776 --
p
	{margin-top:0;margin-bottom:0;}
#yiv9726572776 
</style><div><div dir="ltr">
<div dir="ltr" id="yiv9726572776x_divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri, Helvetica, sans-serif;">
<div>Note to self: read the man page before acting on the "initial intuition". &nbsp;Thanks, Peter!</div>
<div><br clear="none">
</div>
<div>&nbsp; Dave G.</div>
</div>
<hr tabindex="-1" style="display:inline-block;width:98%;">
<div class="yiv9726572776yqt1008334259" id="yiv9726572776yqt70463"><div dir="ltr" id="yiv9726572776x_divRplyFwdMsg"><font style="font-size:11pt;" face="Calibri, sans-serif" color="#000000"><b>From:</b> Peter P. &lt;peterparker@fastmail.com&gt;<br clear="none">
<b>Sent:</b> Friday, August 25, 2017 2:11:14 PM<br clear="none">
<b>To:</b> sox-users@lists.sourceforge.net<br clear="none">
<b>Subject:</b> Re: [SoX-users] Recording in chunks using sox</font>
<div>&nbsp;</div>
</div></div>
</div>
<font size="2"><span style="font-size:10pt;">
</span></font><div class="yiv9726572776yqt1008334259" id="yiv9726572776yqt14194"><div class="yiv9726572776PlainText">* Eyob Yirdaw via Sox-users &lt;sox-users@lists.sourceforge.net&gt; [2017-08-25 19:08]:<br clear="none">
&gt; Hi all,<br clear="none">
&gt; I want to record 24/7 transmission of FM radios using DVB-T dongles.&nbsp; I want to direct the input audio from some dongle to sox, eg. something like<br clear="none">
&gt; rtl_fm -f 88.8M -d 0 -M wbfm | sox -r 32k -t s16 - -t ogg device_0.ogg<br clear="none">
&gt; here am using the rtl_fm terminal program.<br clear="none">
&gt; <br clear="none">
&gt; Can sox help me save the continuous FM audio that comes from rtl_fm to be saved in some time length chunks, say 10 minute long chunks?It means that sox would write to disc every 10 minutes.<br clear="none">
Perhaps look at the examples for the commands "newfile" and "restart" in<br clear="none">
SoX's manpage.<br clear="none">
<br clear="none">
------------------------------------------------------------------------------<br clear="none">
Check out the vibrant tech community on one of the world's most<br clear="none">
engaging tech sites, Slashdot.org! <a rel="nofollow" shape="rect" target="_blank" href="http://sdm.link/slashdot">http://sdm.link/slashdot</a><br clear="none">
_______________________________________________<br clear="none">
Sox-users mailing list<br clear="none">
Sox-users@lists.sourceforge.net<br clear="none">
<a rel="nofollow" shape="rect" target="_blank" href="https://lists.sourceforge.net/lists/listinfo/sox-users">https://lists.sourceforge.net/lists/listinfo/sox-users</a><br clear="none">
</div></div>

</div></div><div class="yqt1008334259" id="yqt26432">------------------------------------------------------------------------------<br clear="none">Check out the vibrant tech community on one of the world's most<br clear="none">engaging tech sites, Slashdot.org! <a shape="rect" href="http://sdm.link/slashdot" target="_blank">http://sdm.link/slashdot</a></div><div class="yqt1008334259" id="yqt27484">_______________________________________________<br clear="none">Sox-users mailing list<br clear="none"><a shape="rect" ymailto="mailto:Sox-users@lists.sourceforge.net" href="mailto:Sox-users@lists.sourceforge.net">Sox-users@lists.sourceforge.net</a><br clear="none"><a shape="rect" href="https://lists.sourceforge.net/lists/listinfo/sox-users" target="_blank">https://lists.sourceforge.net/lists/listinfo/sox-users</a><br clear="none"></div><br><br></div>  </div> </div>  </div></div></body></html>

[-- Attachment #2: Type: text/plain, Size: 202 bytes --]

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot

[-- Attachment #3: Type: text/plain, Size: 158 bytes --]

_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Recording in chunks using sox
  2017-08-25 17:04 ` Recording in chunks using sox Eyob Yirdaw via Sox-users
                     ` (2 preceding siblings ...)
  2017-08-25 18:12   ` Jan Stary
@ 2017-08-26 13:54   ` Jeremy Nicoll - ml sox users
  3 siblings, 0 replies; 9+ messages in thread
From: Jeremy Nicoll - ml sox users @ 2017-08-26 13:54 UTC (permalink / raw)
  To: Eyob Yirdaw, sox-users

On 2017-08-25 18:04, Eyob Yirdaw via Sox-users wrote:

> It means that sox would write to disc every 10 minutes.

Does it mean that?  I'd have thought that sox (or perhaps I should
say the underlying file system or OS) would write data more often
than that, but every ten minutes close the current output file and
open a new one.

-- 
Jeremy Nicoll - my opinions are my own

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Recording in chunks using sox
  2017-08-26 12:42       ` Eyob Yirdaw via Sox-users
@ 2017-08-27 14:37         ` Jan Stary
  0 siblings, 0 replies; 9+ messages in thread
From: Jan Stary @ 2017-08-27 14:37 UTC (permalink / raw)
  To: sox-users

[-- Attachment #1: Type: text/plain, Size: 142 bytes --]

On Aug 26 12:42:27, sox-users@lists.sourceforge.net wrote:
> @Jan: Well am not getting any attachment in your message.

sorry, attaching now


[-- Attachment #2: radio --]
[-- Type: text/plain, Size: 836 bytes --]

#!/bin/sh

fatal() {
	echo $@ >&2
	exit 1
}

[ $# -ge 1 ] || fatal "usage: $0 station [length [outfile]]"

STATION=${1}
SECONDS=${2}
OUTFILE=${3}

CONFIG="$HOME/.radiorc"
. $CONFIG || fatal "Config file $CONFIG not found, no stations defined"
grep "^$STATION=" $CONFIG > /dev/null || fatal "Station '$STATION' not defined"
eval URL=\$$STATION

[ -z "$OUTFILE" ] && OUTFILE="$STATION-`date +%Y%m%d%H%M%S`.${URL##*.}"
[ -e "$OUTFILE" ] && fatal "$OUTFILE already exists"

if [ $# -eq 1 ] ; then
	play=`which play` || fatal "play(1) not found"
	$play $URL
else
	ftp -g -p -V -o $OUTFILE $URL >/dev/null 2>&1 &
	PID=$! && [ "$PID" ] && ps -p $PID >/dev/null 2>&1 ||
		fatal "Error downloading $URL"
	sleep $SECONDS && ps -p $PID >/dev/null 2>&1 ||
		fatal "Process $PID downloading $OUTFILE already exited"
	kill -9 $PID >/dev/null 2>&1
fi

[-- Attachment #3: .radiorc --]
[-- Type: text/plain, Size: 433 bytes --]

# Stations recognized by radio(1). This config file is
# sourced directly, so keep it in valid sh(1) syntax.

praha="http://icecast6.play.cz/cro2-128.mp3"
vltava="http://icecast5.play.cz/cro3-128.mp3"
wave="http://icecast5.play.cz/crowave-128.mp3"
ddur="http://icecast5.play.cz/croddur-128.mp3"
jazz="http://icecast1.play.cz/crojazz128.mp3"
radio1="http://icecast1.play.cz/radio1.mp3"
slow="http://icecast1.play.cz/slowradio160.mp3"

[-- Attachment #4: Type: text/plain, Size: 202 bytes --]

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot

[-- Attachment #5: Type: text/plain, Size: 158 bytes --]

_______________________________________________
Sox-users mailing list
Sox-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-users

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, back to index

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <790552421.2332795.1503680652651.ref@mail.yahoo.com>
2017-08-25 17:04 ` Recording in chunks using sox Eyob Yirdaw via Sox-users
2017-08-25 17:20   ` Graff, David E
2017-08-25 18:11   ` Peter P.
2017-08-25 18:18     ` Graff, David E
2017-08-26 12:42       ` Eyob Yirdaw via Sox-users
2017-08-27 14:37         ` Jan Stary
2017-08-25 18:12   ` Jan Stary
2017-08-25 18:18     ` Jan Stary
2017-08-26 13:54   ` Jeremy Nicoll - ml sox users

sox-users@lists.sourceforge.net unofficial mirror

Archives are clonable: git clone --mirror https://public-inbox.org/sox-users

Newsgroups are available over NNTP:
	nntp://news.public-inbox.org/inbox.comp.audio.sox
	nntp://ou63pmih66umazou.onion/inbox.comp.audio.sox
	nntp://news.gmane.org/gmane.comp.audio.sox

 note: .onion URLs require Tor: https://www.torproject.org/

AGPL code for this site: git clone https://public-inbox.org/ public-inbox