Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

USB Microphone

New to Debian (Or Linux in general)? Ask your questions here!
Message
Author
Fxy
Posts: 14
Joined: 2022-09-14 18:58

Re: USB Microphone

#21 Post by Fxy »

i tried the usb on the back of my pc and it changed the mics name but still no audio

User avatar
FreewheelinFrank
Global Moderator
Global Moderator
Posts: 2082
Joined: 2010-06-07 16:59
Has thanked: 38 times
Been thanked: 225 times

Re: USB Microphone

#22 Post by FreewheelinFrank »

Fxy wrote: 2022-09-24 14:58 nevermind its usb 2
According to the Amazon specs, the microphone is USB 2, so that wouldn't have helped, sorry.

User avatar
FreewheelinFrank
Global Moderator
Global Moderator
Posts: 2082
Joined: 2010-06-07 16:59
Has thanked: 38 times
Been thanked: 225 times

Re: USB Microphone

#23 Post by FreewheelinFrank »

I believe that if we can find the right configuration for Alsa the microphone will work. A pain in the nether regions I know, but if you are willing to keep trying, modify your .asoundrc file to

Code: Select all

pcm.!default {
  type asym
  capture.pcm "mic"
}
pcm.mic {
  type plug
  slave {
    pcm "hw:2,0"
  }
}
Restart Alsa. with:

Code: Select all

# alsa force-reload
Test with:

Code: Select all

arecord --format=S16_LE --rate=16000 --file-type=wav out.wav

Code: Select all

aplay out.wav
Post an errors because they may help to tweak the configuration.

Source:

https://pimylifeup.com/raspberrypi-microphone/

You may need to add configuration options:

Code: Select all

pcm.!default {
  type asym
  capture.pcm "mic"
}
pcm.mic {
  type plug
  slave {
    pcm "hw:2,0]"
    format S16_LE
    rate 44100
    channels 1
  }
}
If that doesn't work, you probably need advice from somebody who understands the technicalities of Alsa configuration.

https://www.alsa-project.org/alsa-doc/a ... ugins.html

You could try posting at a more general Linux forum with a title such as "Need help configuring Alsa to use USB microphone" and post output of arecord -l and the asoundrc files you have tried.

https://unix.stackexchange.com

Edit: typo
Last edited by FreewheelinFrank on 2022-09-26 12:05, edited 4 times in total.

Fxy
Posts: 14
Joined: 2022-09-14 18:58

Re: USB Microphone

#24 Post by Fxy »

I dont know what to do

User avatar
FreewheelinFrank
Global Moderator
Global Moderator
Posts: 2082
Joined: 2010-06-07 16:59
Has thanked: 38 times
Been thanked: 225 times

Re: USB Microphone

#25 Post by FreewheelinFrank »

Fxy wrote: 2022-09-25 06:20 I dont know what to do
Put

Code: Select all

pcm.!default {
  type asym
  capture.pcm "mic"
}
pcm.mic {
  type plug
  slave {
    pcm "hw:2,0"
  }
}
in

Code: Select all

~/.asoundrc
And try that first.

Restart Alsa or reboot.

Test and report what you get.

Edit: typo
Last edited by FreewheelinFrank on 2022-09-26 11:56, edited 1 time in total.

Fxy
Posts: 14
Joined: 2022-09-14 18:58

Re: USB Microphone

#26 Post by Fxy »

nope didin't work

User avatar
FreewheelinFrank
Global Moderator
Global Moderator
Posts: 2082
Joined: 2010-06-07 16:59
Has thanked: 38 times
Been thanked: 225 times

Re: USB Microphone

#27 Post by FreewheelinFrank »

What error messages did you get from

Code: Select all

arecord --format=S16_LE --rate=16000 --file-type=wav out.wav
with those configuration settings?

Fxy
Posts: 14
Joined: 2022-09-14 18:58

Re: USB Microphone

#28 Post by Fxy »

ALSA lib conf.c:5545:(parse_args) Parameter DEV must be an integer
ALSA lib conf.c:5687:(snd_config_expand) Parse arguments error: Invalid argument
ALSA lib pcm.c:2664:(snd_pcm_open_noupdate) Unknown PCM hw:2,0]
arecord: main:867: audio open error: Invalid argument

Fxy
Posts: 14
Joined: 2022-09-14 18:58

Re: USB Microphone

#29 Post by Fxy »

ok so i removed the "]" from hw:2,0] and now it returns this
arecord: main:867: audio open error: No such file or directory

User avatar
FreewheelinFrank
Global Moderator
Global Moderator
Posts: 2082
Joined: 2010-06-07 16:59
Has thanked: 38 times
Been thanked: 225 times

Re: USB Microphone

#30 Post by FreewheelinFrank »

Fxy wrote: 2022-09-26 11:46 ok so i removed the "]" from hw:2,0] and now it returns this
arecord: main:867: audio open error: No such file or directory
Sorry, my fault - I made a couple of typos.

Yes, the "]" shouldn't have been there, and the command is

Code: Select all

aplay out.wav
not out.wave.

Corrected in original post.

Try

Code: Select all

aplay out.wav
Many apologies. I have a cold and my brain isn't functioning 100%.

Fxy
Posts: 14
Joined: 2022-09-14 18:58

Re: USB Microphone

#31 Post by Fxy »

Code: Select all

ALSA lib pcm_asym.c:105:(_snd_pcm_asym_open) playback slave is not defined
aplay: main:867: audio open error: Invalid argument

User avatar
FreewheelinFrank
Global Moderator
Global Moderator
Posts: 2082
Joined: 2010-06-07 16:59
Has thanked: 38 times
Been thanked: 225 times

Re: USB Microphone

#32 Post by FreewheelinFrank »

From the error message, it looks like playback needs to be defined, as per the example from the original link.

Code: Select all

pcm.!default {
    type asym
    playback.pcm {
        type plug
        slave.pcm "hw:3,0"
    }
    capture.pcm {
        type plug
        slave.pcm "hw:2,0" 
    }
}
https://wiki.audacityteam.org/wiki/USB_mic_on_Linux

If that isn't working, you probably need to try a more general Linux forum and hope to find somebody with a deeper understanding of configuring Alsa inputs.

Post Reply