Using volume controls over the audio jack

Does the audio system on on Librem 15 support using the play/pause and volume controls found on most headsets? Someone suggested using evtest to check for the events. I see an event on insert and remove, for example:

Event: time 1557028671.036426, type 5 (EV_SW), code 2 (SW_HEADPHONE_INSERT), value 1

But I see no events on volume or play/pause actions. Is there a way to make this work on the Librem 15?

1 Like

Try the acpi_listen command, to see if it registers as an acpi event and then you can script around it.
Basically this is the way to start:
However it will be highly dependent on the application. I believe VLC will support that.

It does not… I only see events for plug/unplug and not for volume change or play/pause.

jack/headphone HEADPHONE plug
jack/headphone HEADPHONE unplug

I’m am wondering of the librem audio chip can detect those events at all or if it a driver or configuration error.

These events are not actually related to the driver, but to the sound subsystem.
In case you use Alsamixer, there is a switch called “Headphone Jack Sense” for that.
Run gnome-alsamixer in the terminal to see if it’s enabled.
I am not sure how to do in in PulseAudio.

I don’t see any “Headphone Jack Sense” in the elements I can control in alsamixer, even after I selected “All” with F5.