I have an issue with a wired headset using the TRRS input of the Reform2 not showing any input device. While I can change the output from “speaker” to “headset” in pavucontrol and hear the output as expected, there is no option for input whatsoever. It only says “no input devices available” when I select “show all except monitors”. I am running the A311D and have not messed with the system image in a meaningful way I believe (only recently reinstalled the system).
I can change the profile in the Configuration tab of pavucontrol from “Stereo” to “Audio Pro” which creates a bunch of output and input devices (3 each iirc) but that didn’t yield any success either. I didn’t try this config in detail though as I didn’t quite understand what this profile was supposed to do and how it reflected the available HW.
The headset does work with my Android phone and another soundcard, so the headset and connector should be fine. This is the first time I am trying a wired headset on the Reform, so I was worried it might be a hardware issue.
Does any one have any suggestion as to how to configure the input for a wired headset? Could this be a bug in the system image?
It could be an issue with the device tree on the A311D Reform. I have a iMX8MQ machine and the Built-in Audio Stereo input shows up in pavucontrol.
The “Pro Audio” profile just exposes more options for complex sound devices that PipeWire typically hides for normal PC used, but are useful to people doing stuff with music production/sound engineering.
Honestly, no clue. The Device Tree stuff is still largely a mystery to me even after working on it to fix recording on the imx8mq Reform.
You could start with the docs.
That’s what I did and it was helpful to understand that the “sound card” as Linux sees it has actually (at least) 2 parts. One that’s the codec chip on the motherboard (WM8960), and the other that’s part of the SoC, connected via I2S(?).
My guess is, your problem is on the SoC side, but it’s just a largely unfounded hunch and I don’t have a A311D machine here to play with.
Actually, something worth checking is arecord -l and see if ALSA thinks there are any capture devices. If it does, but PipeWire doesn’t see them, then maybe there’s just a software problem.
You might be in the realm of software land where stuff (should be) easier to fix.
Probably one is for the unpopulated JST plug on the motherboard for the stereo line input. Or maybe two of them if the channels got separated at birth.
Try recording from each of those and see if any of them contain your mic input.
If that works, then the only thing you have to figure out is how to convince Pipewire to see it for what it is.
Ok, I have been messing with trying to record directly from the Alsa input devices for some time now, but do not get anywhere: basically, arecord fails with the message Sample format non available whatever I do.
This would look like this:
$ arecord --verbose -D "hw:CARD=MNTREFORM2BPICM,DEV=3" mon.wav
Warning: Some sources (like microphones) may produce inaudible results
with 8-bit sampling. Use '-f' argument to increase resolution
e.g. '-f S16_LE'.
arecord: set_params:1387: Sample format non available
Available formats:
- S8
- S16_LE
- S24_LE
- S32_LE
- IEC958_SUBFRAME_LE
- S20_LE
$ arecord --verbose -f S16_LE -D "hw:CARD=MNTREFORM2BPICM,DEV=3" mon.wav
arecord: set_params:1456: Unable to install hw params:
ACCESS: RW_INTERLEAVED
FORMAT: S16_LE
SUBFORMAT: STD
SAMPLE_BITS: 16
FRAME_BITS: 16
CHANNELS: 1
RATE: 8000
PERIOD_TIME: 125000
PERIOD_SIZE: 1000
PERIOD_BYTES: 2000
PERIODS: 4
BUFFER_TIME: 500000
BUFFER_SIZE: 4000
BUFFER_BYTES: 8000
TICK_TIME: 0
I have tried different devices (among others hw:0,3, plughw:0,3 as well as 4 or 5 instead for 3), different formats and different rates. I have stopped pipewire-socket, pipewire, pipewire-pulse.socket and pipewire-pulse services, to make sure they don’t interfere. And I have tried to use the info in Record Audio without Pulseaudio/Pipewire - #2 by soulsource but am not sure it is really relevant (though the error seems to be the same). I have even tried sudo in case this is some weird permission problem.
I could not find anything online with respect to this error message that sounded relevant to my problem, either.
If I omit the device, then PipeWire PCM I/O Plugin is used, and a completely silent waveform is recorded.
Maybe (that is to say probably) I am doing something stupid and that is why it is failing… but right now, I don’t quite know where to continue investigating so ideas, hunches and advice are all very much welcome!
If anyone with an A311D (on a Reform2) could confirm that there is no input device visible in pavucontrol, that would also ease my mind that it is not something I messed up when installing some package..
You probably need to set the sampling rate as well. The IMX8 Reform requires that too. Try -r 48000
Older sound cards and their drivers like the SB Audigy museum piece in my desktop PC have no trouble recording or playing whatever you ask of them, but newer stuff, particularly embedded, are very picky about it. I think the drivers are written with the assumption that there will be a userspace sound server doing all of that work so why bother trying.
I tried different DEV values and different formats (just for the sake of trying), but I always get the same error message and no output file is written.
Is there some introspection in the system, i.e. a way to find out what the HW supports similar to how arecord would suggest supported formats?