Bug 489198

Summary: Unable to use internal microphone once headset is connected
Product: [Unmaintained] plasma-pa Reporter: BOF <bugs_kde_org.5.kuru>
Component: generalAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED NOT A BUG    
Severity: normal CC: isma.af, nate, nicolas.fella, sitter
Priority: NOR    
Version First Reported In: 6.1.0   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description BOF 2024-06-25 19:18:09 UTC
(I have no idea where to put this report, so feel free to move it wherever it fits)

SUMMARY
I have a PC with a dual purpose 3.5mm jack (headphone/microphone in one port).
As soon as I connect headphones to the PC (plug it into the port) I can no longer use my internal microphone (Audio Profile: Analog Stereo Duplex). Once I unplug the  headphones the internal microphone works again.

STEPS TO REPRODUCE
1. Have a PC with a dual purpose 3.5mm jack (in my case: Lenovo ThinkBook 16)
2. Plug in headphones
3. Try to record audio over the internal microphone

OBSERVED RESULT
The internal microphone does no longer work even I did nothing but connect the headphones to the combined audiojack. I did not find any way to 'force' the system to change the source for audio input (like you can do with speakers/headphones for the output).

EXPECTED RESULT
Internal microphones works no matter if headphones are plugged in or not.

SOFTWARE/OS VERSIONS
Operating System: KDE neon 6.0
KDE Plasma Version: 6.1.0
KDE Frameworks Version: 6.3.0
Qt Version: 6.7.0
Kernel Version: 6.5.0-41-generic (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 7530U with Radeon Graphics
Memory: 29.2 GiB of RAM
Graphics Processor: AMD Radeon Graphics
Manufacturer: LENOVO
Product Name: 21KK
System Version: ThinkBook 16 G6 ABP

ADDITIONAL INFORMATION
1)
I have no idea if this is caused by the laptop or not (I have also no idea how I could test this). Maybe the laptop does cut out the internal microphone once a something is plugged in to the audio jack no matter what it is. IMO a contra argument to that theory is the fact that when I connect the a standalone microphone (so occupy the audio jack) the internal microphone works fine.

2)
When I connect the headphones, open the pulse audio control center and take a look at the input devices, it says that the microphone is plugged in (looks like this is caused by my headphones) and the internal headphones are disconnected. Once I unplug my headphones it says the the microphone is disconnected and it auto-switches to the internal microphone. When I plug in my standalone microphone with 3.5mm jack it still says that the microphone is unplugged, but the internal microphone is working.

3)
I want to test a 3.5mm microphone/headphone splitter and see how (and if) this works. So far I don't have one at hand.

4)
My current workaround is to use a wireless headset over bluetooth. Not really a good solution, but it works for now.

5)
I found this old bugreport: "Can't record audio from built-in microphone while headphones are plugged into headphone jack" (https://bugs.kde.org/show_bug.cgi?id=411565)
-  Nate Graham closed it (2021-03-12) with the comment: "Fixed ages ago."
Comment 1 BOF 2024-06-27 16:30:12 UTC
Add 3)
I got an audio splitter for headphones/microphone and now i can use the *external* microphone. The internal microphone still does not work. When I switch to it in the setting app there is nothing but silence. While testing I double checked that the system was not using the microphone that is integrated to my laptop.

Audio splitter like this one: https://www.amazon.de/Jack-splitter-kabel-Microfoon-Audio/dp/B00JSR5OIE

add 4)
As my bluetooth headphones also have an integrated microphone, I can use this as audio input. So there wouldn't even be a need for an extra microphone. Yet if I connect an external microphone to the dual-use port of my laptop, I can not switch between them.

6)
I had an extra ~5 EUR in-ear headset with included microphone with a 3.5mm audio jack. This one worked fine for both audio and microphone. As in Add 3) I made sure that the system was not using the integrated microphone.
Comment 2 BOF 2024-06-27 19:40:11 UTC
7)
It turned out that the headphones I was using uses the plug of a headset (so no wonder the system acts like an external microphone is connected)
I used a 3.5mm extension cord (that is headphones only) and connected the same headset. Now I can use the headset and the internal mic.


So the main question for me now is question, whether it's KDE or my PC that mutes the internal microphone once an external microphone is connected.
Is there any way to find out if the internal microphone is 'connected' to the system or if something else goes wrong inside KDE?
Comment 3 Harald Sitter 2024-09-23 11:15:54 UTC
We do not have special code that handles this. It'd either be in pipewire or on hardware. I am not sure there is a good way to find out which.