Audio recorded too silent and noisy on my intel NUC (NUC6CAYS)

Issues related to hardware problems
Post Reply
janvda
Posts: 4
Joined: 2020/07/20 06:46:37

Audio recorded too silent and noisy on my intel NUC (NUC6CAYS)

Post by janvda » 2020/07/20 07:23:51

I have CentOS 8 installed on my intel NUC (NUC6CAYS)

This intel NUC model features a dual-array front mic but I don't succeed in properly recording sound from this microphone.

The problem:
It is recording sound with a lot of noise.
Using alsamixer I have found a setting to reduce the noise but then the recorded audio is also recorded very silently.

Alsamixer is showing multiple capture settings that I can tune (Mic Boost, Capture (L and R), Digital, Internal Mic Boost).
I also don't know how I can best tweak these settings to get best result.

My recording options with best results
I have tried a limited set of combinations and the below settings gave best result.

Code: Select all

arecord -f S16_LE -r16000 -t raw -d 5 output.raw
alsamixer capture settings.png
alsamixer capture settings.png (37.54 KiB) Viewed 136 times
My intel NUC setup

Code: Select all

[root@nuc-jan ~]# uname -r
4.18.0-193.6.3.el8_2.x86_64
[root@nuc-jan ~]# 

Code: Select all

[root@nuc-jan ~]# arecord -L
surround21
    2.1 Surround output to Front and Subwoofer speakers
surround40
    4.0 Surround output to Front and Rear speakers
surround41
    4.1 Surround output to Front, Rear and Subwoofer speakers
surround50
    5.0 Surround output to Front, Center and Rear speakers
surround51
    5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71
    7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
null
    Discard all samples (playback) or generate zero samples (capture)
default:CARD=PCH
    HDA Intel PCH, ALC283 Analog
    Default Audio Device
sysdefault:CARD=PCH
    HDA Intel PCH, ALC283 Analog
    Default Audio Device
front:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    Front speakers
[root@nuc-jan ~]# 

Code: Select all

[root@nuc-jan ~]# dnf list installed | grep -E 'audio|alsa'
Modular dependency problems:

 Problem 1: conflicting requests
  - nothing provides module(perl:5.26) needed by module perl-DBD-MySQL:4.046:8010020191114030811:073fa5fe-0.x86_64
 Problem 2: conflicting requests
  - nothing provides module(perl:5.26) needed by module perl-DBD-SQLite:1.58:8010020191114033549:073fa5fe-0.x86_64
 Problem 3: conflicting requests
  - nothing provides module(perl:5.26) needed by module perl-DBI:1.641:8010020191113222731:16b3ab4d-0.x86_64
alsa-lib.x86_64                                    1.2.1.2-3.el8                                  @AppStream       
alsa-utils.x86_64                                  1.2.1-2.el8                                    @AppStream       
pcaudiolib.x86_64                                  1.1-2.el8                                      @AppStream       
pulseaudio.x86_64                                  11.1-23.el8                                    @AppStream       
pulseaudio-libs.x86_64                             11.1-23.el8                                    @AppStream       
pulseaudio-libs-glib2.x86_64                       11.1-23.el8                                    @AppStream       
pulseaudio-module-bluetooth.x86_64                 11.1-23.el8                                    @AppStream       
pulseaudio-utils.x86_64                            11.1-23.el8                                    @AppStream       
webrtc-audio-processing.x86_64                     0.3-8.el8                                      @AppStream       
[root@nuc-jan ~]# 

Code: Select all

[root@nuc-jan ~]# lspci -vv | grep -i audio
00:0e.0 Audio device: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series Audio Cluster (rev 0b) (prog-if 80)
[root@nuc-jan ~]# 

Code: Select all

[root@nuc-jan ~]# tree /proc/asound -L 2
/proc/asound
├── card0
│   ├── codec#0
│   ├── codec#2
│   ├── eld#2.0
│   ├── eld#2.1
│   ├── eld#2.2
│   ├── eld#2.3
│   ├── eld#2.4
│   ├── eld#2.5
│   ├── eld#2.6
│   ├── eld#2.7
│   ├── eld#2.8
│   ├── id
│   ├── pcm0c
│   ├── pcm0p
│   ├── pcm10p
│   ├── pcm1p
│   ├── pcm3p
│   ├── pcm7p
│   ├── pcm8p
│   └── pcm9p
├── cards
├── devices
├── hwdep
├── modules
├── oss
│   ├── devices
│   └── sndstat
├── PCH -> card0
├── pcm
├── seq
│   ├── clients
│   ├── drivers
│   ├── queues
│   └── timer
├── timers
└── version

12 directories, 25 files
[root@nuc-jan ~]# 

Code: Select all

[root@nuc-jan ~]# sudo lshw -class multimedia
  *-multimedia              
       description: Audio device
       product: Celeron N3350/Pentium N4200/Atom E3900 Series Audio Cluster
       vendor: Intel Corporation
       physical id: e
       bus info: pci@0000:00:0e.0
       version: 0b
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress bus_master cap_list
       configuration: driver=snd_hda_intel latency=0
       resources: irq:131 memory:91410000-91413fff memory:91000000-910fffff
[root@nuc-jan ~]# 

Code: Select all

[root@nuc-jan ~]# lspci
00:00.0 Host bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series Host Bridge (rev 0b)
00:02.0 VGA compatible controller: Intel Corporation HD Graphics 500 (rev 0b)
00:0e.0 Audio device: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series Audio Cluster (rev 0b)
00:0f.0 Communication controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series Trusted Execution Engine (rev 0b)
00:12.0 SATA controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series SATA AHCI Controller (rev 0b)
00:13.0 PCI bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series PCI Express Port A #1 (rev fb)
00:13.1 PCI bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series PCI Express Port A #2 (rev fb)
00:13.2 PCI bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series PCI Express Port A #3 (rev fb)
00:15.0 USB controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series USB xHCI (rev 0b)
00:16.0 Signal processing controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series I2C Controller #1 (rev 0b)
00:18.0 Signal processing controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series HSUART Controller #1 (rev 0b)
00:19.0 Signal processing controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series SPI Controller #1 (rev 0b)
00:19.1 Signal processing controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series SPI Controller #2 (rev 0b)
00:19.2 Signal processing controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series SPI Controller #3 (rev 0b)
00:1c.0 SD Host controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series eMMC Controller (rev 0b)
00:1f.0 ISA bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series Low Pin Count Interface (rev 0b)
00:1f.1 SMBus: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series SMBus Controller (rev 0b)
01:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS5229 PCI Express Card Reader (rev 01)
02:00.0 Network controller: Intel Corporation Dual Band Wireless-AC 3168NGW [Stone Peak] (rev 10)
03:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 15)
[root@nuc-jan ~]# 

janvda
Posts: 4
Joined: 2020/07/20 06:46:37

Re: Audio recorded too silent and noisy on my intel NUC (NUC6CAYS)

Post by janvda » 2020/07/20 13:04:30

The problem seems to be caused by recording at 16000 Hz instead of 44100Hz.

The Fix:

I have used the following command to properly record :

Code: Select all

arecord -f S16_LE -r44100 -t raw -d 60 output.raw
I have also set "internal mic boost" to 20 using alsamixer to increase the recorded audio volume:
proper alsamixer capture settings.png
proper alsamixer capture settings.png (61.37 KiB) Viewed 122 times

lightman47
Posts: 1160
Joined: 2014/05/21 20:16:00
Location: Central New York, USA

Re: Audio recorded too silent and noisy on my intel NUC (NUC6CAYS)

Post by lightman47 » 2020/07/20 13:57:32

Wonder why it defaulted to 16K - well within the range of human hearing. No wonder it sounded terrible.
Remember - importing/building packages will likely "byte you in the butt" come update time, long after you'd forgotten you did that! Use repos whenever possible.

janvda
Posts: 4
Joined: 2020/07/20 06:46:37

Re: Audio recorded too silent and noisy on my intel NUC (NUC6CAYS)

Post by janvda » 2020/07/20 14:11:04

lightman47 wrote:
2020/07/20 13:57:32
Wonder why it defaulted to 16K - well within the range of human hearing. No wonder it sounded terrible.
It is not that it defaulted to 16K. I explicitly set it to the 16K in the arecord command.
I did that because that was the recommended input format for my next processing step (machine learning algorithm).

So I might need to use another utility (sox,...) to down sample it to 16K but that is not relevant for this forum topic.

Post Reply

Return to “CentOS 8 - Hardware Support”