sox-users@lists.sourceforge.net unofficial mirror
 help / color / mirror / code / Atom feed
From: "George S. Williams" <ra@websterling.com>
To: sox-users@lists.sourceforge.net
Subject: Re: Duration of recorded file is longer than recording time using SoX
Date: Wed, 25 Dec 2019 20:02:53 -0500	[thread overview]
Message-ID: <0709217c-c34d-2ab5-19bb-bd8b44b8e066@websterling.com> (raw)
In-Reply-To: <20191225212334.GA64006@www.stare.cz>



On 12/25/2019 4:23 PM, Jan Stary wrote:
>>>>> I'm using SoX on Centos 7 to record the audio output from GQRX, a SDR
>>>>> application. I've selected Monitor of Built-in Audio Analog Stereo
>>>>> from the Recording Tab of the Pulseaudio Volume Control. I'm
>>>>> trying to
>>>>> save a .wav file with a sample rate of 6k. I'm using the command
>>>>>
>>>>> |sox -t pulseaudio 2 --rate 6k --channels 1 test.wav |
>>>> Does the presence of the 'pipe' character before "sox" mean that audio
>>>> was being generated by a previous command?
>>> The command is run by itself- the pipe characters are a consequence of
>>> copying and pasting that I didn't catch.
> OK, sou you start
>
> 	sox -t pulseaudio 2 --rate 6k --channels 1 test.wav
>
> at a terminal, and then start GQRX (whatever that is) to produce its
> output, and have PulseAudio (the system audio framwork) monitor
> the GQRX output as a recording. So that's what SoX gets. Right?
>
> But that is not a valid SoX command line. In SoX SYNOPSIS parlance,
> what is the "infile"? And what is "pulseaudio 2"? The "-t pulseaudio"
> specifies the type (-t); what is the "2"?
GQRX is a SDR (Software Defined Radio) application, as was mentioned in 
the OP

pulseaudio is a AUDIO DEVICE DRIVER, 2 is the device being monitored
See, for example, 'sox -h'

> Can you please post the output of your actual command line
> with sox -V3 (for verbosity)?
>
> Also, a command line like that will not stop recording its input
> just because the other side has stopped producing output
> (as opposed to reading a file as input). So how exactly
> is the above SoX process terminated?
SoX is terrminated with Ctrl-C
>>>> In your "too long" wave file, does it start with 1h 6m of something
>>>> else, or end with 1h 6m of something else?  Or what?
>>> The wave file contains what was recorded, nothing extra. It is
>>> 'stretched' to the longer duration.
> How can it "contain what was recorded, nothing extra"
> and at the same time be of different length? Is it the
> rate change? That is, are you recording a 6kHz channel
> at the specified rate of 6kHz?
The problem seems to be either with GQRX or Pulseaudio- probably not 
SoX. Using a different SDR and piping its output to SoX works fine, so 
I'm no longer working on this problem.

Thanks for the reply, but why the attitude?

George


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



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

  reply	other threads:[~2019-12-26  1:03 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-16  2:39 Duration of recorded file is longer than recording time using SoX George S. Williams
2019-12-16 16:14 ` Jeremy Nicoll - ml sox users
     [not found]   ` <f1382121-d632-9252-17a8-e7baed8913f2@websterling.com>
2019-12-16 20:53     ` Jeremy Nicoll - ml sox users
2019-12-25 21:23       ` Jan Stary
2019-12-26  1:02         ` George S. Williams [this message]
2019-12-28 15:52           ` Jan Stary

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://lists.sourceforge.net/lists/listinfo/sox-users

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0709217c-c34d-2ab5-19bb-bd8b44b8e066@websterling.com \
    --to=sox-users@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/sox.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).