How do I set a default (hardware) device for my Microphone mute key/ mute all microphones at once?

I have the echo-cancel module loaded in pulse audio on startup, which creates a virtual microphone and sets that as “default device” for microphone in the system. All well and good but when I press the mic mute button on my keyboard or in the bottom bar it only mutes the virtual microphone and my actual “hardware” microphone is unphased and still recording. I tried setting up a custom hotkey but I’m just lost in the sauce there.

I would appreciate it if I don’t have to download any additional software that has to run in the background if possible.

Thanks in advance!!!

Hi and Welcome to the Forum :+1:
(In case you were not welcomed yet)


Maybe you need to select that virtual microphone as input device to record from in the app you are using :wink:
Otherwise your echo-cancle module is not used as you are bypassing that modules device…

On Linux you are not only able to select different output devices per application but also input devices…

See the menu below that pops-up when you click the speaker icon in bottom right of your taskbar:
(THis is how to select output device per app)
image
The input device is most likely configured in the app itself.

Please post more information about configuration of audio sources

pacmd dump | grep -e echo -e source

module-echo-cancel is a filter module for acoustic echo cancellation between a designated sink and source. The module creates a virtual source on top of the hardware for recording filtered (echo-cancelled) audio
The echo-cancelled virtual sink should be set as default source to record processed audio

If default source is changed to use hardware input device, or default source is overruled by user changing to hardware input device, audio will be recorded before echo-cancellation

To record direct from hardware input device without processing it would be simpler to unload module-echo-cancel temporarily

pactl unload module-echo-cancel

and restart pulseaudio systemd units to reload again

systemctl --user restart pulseaudio

The hardware input device should not be muted when using module-echo-cancel
If audio from microphone is muted before module-echo-cancel there is nothing for the module to do
and it will probably be suspended

heyo, the only purpose i wanted this hotkey for was to mute my actual source microphone the virtual mic was using as a source to ensure my mic is actually off when i want it to.

Anyways I found out that the script I’ve been copying from a guide also set the new mic as default so I just deleted that part.

Sounds stupid; is stupid, but solved the problem. Thanks to everyone who tried to help. Love y’all stay awesome!

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.