sox-users@lists.sourceforge.net unofficial mirror
 help / color / mirror / code / Atom feed
From: Jan Stary <hans@stare.cz>
To: sox-users@lists.sourceforge.net
Subject: Re: How to use microphone calibration file
Date: Tue, 16 Dec 2014 07:52:41 +0100	[thread overview]
Message-ID: <20141216065241.GA20666@www.stare.cz> (raw)
In-Reply-To: <548ED2E4.1010902@users.sourceforge.net>

On Dec 15 13:24:04, pander@users.sourceforge.net wrote:
> Hi all,
> 
> I have an UMIK-1 (a calibrated USB microphone) and use rec from sox for
> recording. I use a Raspberry Pi and try to get the most out of it in
> terms of quality. I am using the following commands:
> 
>   export AUDIODEV=hw:1,0
>   export AUDIODRIVER=alsa
>   rec -q -r 48000 -c 1 -b 24 --buffer 16384 test.wav trim 0 300
> 
> 1) Should I worry about the following message?
> 
>   rec WARN formats: can't set 1 channels; using 2
> 
> because the recording results in
> 
>   file test.wav
>   test.wav: RIFF (little-endian) data, WAVE audio, mono 48000 Hz

Record with 'rec -V' instead and show us the output.
The run soxi on the recorded file and show us the output.

> and Audacity reports
> 
>   Mono, 96000Hz
>   32-bit float
> 
> 2) I doubled the buffer size but sometimes I get
> 
>   rec WARN alsa: over-run
> 
> but that seems to be independent of the doubling of the buffer size and
> only occurs on start up. What is smart to do here?

Record without messing with the buffer first, and see if it is happening.
Do you have any 'sound daemon' running, such as alsad? In other words,
is SoX recording directly from the device, or is there a middleman?

> 3) How do I use the microphone calibration file? I can download it from
> 
>   http://www.minidsp.com/products/acoustic-measurement/umik-1
> 
> and looks like
> 
>   Sens Factor =.27710dB, SERNO: 7007***
>   10.054	-5.3961
>   10.179	-5.2292
>   10.306	-5.0655
>   ...
>   19527.604	-0.7159
>   19770.697	-0.7462
>   20016.816	-0.7772
> 
> A simple line plot of the entire files reveals as
> 
>   https://i.imgur.com/ISO0WHh.png

How do you suppose the calibration file should be "used"
and what do you picture as an output of such usage?

> 4) Are there more ways to optimise recording in this way?

What "this way"? You have a microphone. How do you suppose
to "optimize" recording with it using a calibration measurement?

> 5) As next step, I am using this command to create a spectrogram
> 
>   sox test.wav -n remix - rate .25k spectrogram -x 1776 -y 512 -c 125Hz

First of all, this command makes my 14.4.1 segfault.
Without the -x argument to the spectrogram effect, it works.
Without running 'rate' first, it works.

Why are you changing the rate (and why to .25k)
before running the spectrogram effect? Are you trying to make
a spectrogram of a low frequency band only? Why?

> Could the latter command also be optimised or should calibration
> correction take place here?

What would be an "optimized" spectrogram?

> 6) When calibration is used,

How do you think "calibration is used" here?

> does the spectrogram reflect dB properly or
> is more processing needed?

------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk

  reply	other threads:[~2014-12-16  6:53 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-15 12:24 How to use microphone calibration file Pander
2014-12-16  6:52 ` Jan Stary [this message]
2014-12-17  0:28   ` Pander
2014-12-17 13:54     ` Jan Stary
2014-12-17 14:24       ` Erich Eckner
2014-12-17 19:15         ` New effect - was: " fmiser
2014-12-18 15:57         ` Pander
2014-12-18 16:27           ` Jan Stary
2014-12-18 16:15       ` Pander
2015-01-01 19:59         ` Jan Stary
2014-12-20 16:48     ` Pander

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=20141216065241.GA20666@www.stare.cz \
    --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).