Impossible to record audio via external microphone on my Xperia model

First, I apologize in advance if this issue has already been discussed in the forum. For my part, I have not been able to find concrete information about my audio problem here.

I would like to know if the following issue is happening to some other sailors and, if so, how they have solved it:

I am unable to record audio from an external microphone neither with the recorders, nor with the cameras, native and non-native on my SF4.

My model is a Xperia XA2 Ultra Dual SIM (H4233). The external microphone is a BOYA BY-M1 (lavalier microphone).

In another thread specific to this latest update, a sailor told me that this is not a problem on this or previous versions. I have searched the last two days also outside this forum. But I have not found any information or clue to guide me.

In any case, maybe this is only happening to my device because it might be defective. But it could also be due to my unfamiliarity with Sailfish, as I am a newbie. If so, I would appreciate any pointers that would put me on the track of the solution.

I made a video about this limitation. There is no support for external microphones at all when it comes to video recording:

Sorry. I don’t know if I’m interpreting the question correctly, @sebix. If I have understood it properly, all I can add is that my XA2 Ultra has a socket for a mini jack on its top, and my microphone is connected via a mini plug jack. My BOYA BY-M1 has no other option to connect to my Xperia other than this way.

Thank you very much for your answer. I have been able to watch the video completely at last (yesterday I got your answer late at night here in Spain). It’s a pity that we can’t even record audio via USB-C socket.

For me i can record audio with the mic on a wired handsfree, both when connected over 3.5mm and USB-C to 3.5mm adapter.

I am also able to use my Rode NT-USB conneted over USB-C.
The only obvious difference i can see here is that all my devices happen to be combined mic and headphones/output. (The NT-USB has monitor-out) So either pure microphones are not detected properly, or more likely, something about priorities only considers composite devices, or has input following output.

Could be interesting to see what pacmd info shows when there is a mic connected, as opposed to a handsfree. Maybe something like what “Audio Output Chooser” does to outputs can be done to inputs as well.

All officially supported Xperias (probably all Xperias ever made too?) have a 3.5mm jack.

Damnit, I completely mixed up things.

1 Like

Yes, you are right.

I confirm also that with my handsfree it is recordable.

In my particular case, the recorded audio output is negligible due to the poor quality of the tiny microphone hanging from my headset, but this is a merely circumstantial detail, since it is at least minimally audible, while with the lavalier BOYA mic there is no output at all.

Don’t know if this helps, but I got better results recording audio on my xa2 using the genuine Jolla audio recorder in favor to the one from jolla store/openrepos. It can be installed through e.g. zypper install harbour-recorder

So, then it follows that you should probably be able to use that mic with a y-splitter separating out mic and headphone to separate 3.5mm connectors (at least if you connect headphones as well).
I also assume many USB-C to 3.5mm adapters doesn’t have the same (or any) detection of what is plugged in, and could work too.

And as a step towards a more proper solution, figuring out what if anything can be done to the pulseaudio config to make it work would be a good idea.
A fully analysed feature request tends to have an easier time getting picked up.

Yesterday afternoon I received the Y splitter from Amazon. This morning I have been trying this workaround. But it only recognizes my SONY earphones, not the BOYA microphone.

Too bad. I read somewhere that LineageOS fixed this problem with missing DRM’s via a patch. I hope Sailfish can do it someday too.

I had some moderate success with a y-splitter, but since all i had to test with as a mic was a handsfree, and the contacts didn’t line up, i got those speakers connected as a mic. (It expects a connector with just 2 segments not a TRRS with 4) It works, but is not really usable. However it suggests that given a better connector match it should work.
One oddity though, I had to connect the splitter to the headphones and phone first, and only after that connect the handsfree i used as a mic.

I’ll try to look in to what pulseaudio says about the situation (and i recommend you do the same), but no promises on when.

I can’t imagine DRM has anything to do with this. Especially not here, but not elsewhere either for that matter.

Umm… Tomorrow I will implement that process with the same sequence of connections. The only difference will be that I will replace your hands-free with my lavaliere microphone.

With which command can I check it?

If i saw accurate pictures of it, it still had 4-conductor TRRS, so it will likely mismatch too.
(and what, if anything, it has on the middle connectors is anyone’s guess)

pacmd info

and

pactl info

You are right: four connections :slightly_frowning_face:

Try this: pacmd set-source-port 2 input-wired_headset with just the mic connected.
(check pacmd info for the index of source.droid, but the setup is probably the same, so should be 2)

Yes, I have source.droid/#2: Droid source droid. I will try.

Just a preliminary question: is pacmd set-source-port a permanent change, or should we use it each boot? Or every time before I connect my mic?

For me it only persists until what is plugged in changes (which was expected). And you probably want to do it after connecting the mic.

Yes, you got that observation right:

Now that is curious. The command does not work for me to record video with the native camera or the advanced OpenRepos camera :neutral_face: (same no result as before). However now it is recognized by the native recorder :slightly_smiling_face: Can this suggest or provide some kind of clue?