alsa-mixer: add support for Steelseries Arctis 5 headset

Submitted by Bert Hekman on Jan. 6, 2018, 2:03 p.m.

Details

Message ID 20180106140313.29456-1-demontpx@gmail.com
State New
Headers show
Series "alsa-mixer: add support for Steelseries Arctis 5 headset" ( rev: 1 ) in PulseAudio

Not browsing as part of any series.

Commit Message

Bert Hekman Jan. 6, 2018, 2:03 p.m.
---
 .../alsa/mixer/profile-sets/90-pulseaudio.rules    |  3 +-
 .../steelseries-arctis-5-usb-audio.conf            | 45 ++++++++++++++++++++++
 ...io.conf => steelseries-arctis-7-usb-audio.conf} |  0
 3 files changed, 47 insertions(+), 1 deletion(-)
 create mode 100644 src/modules/alsa/mixer/profile-sets/steelseries-arctis-5-usb-audio.conf
 rename src/modules/alsa/mixer/profile-sets/{steelseries-arctis-usb-audio.conf => steelseries-arctis-7-usb-audio.conf} (100%)

Patch hide | download patch | download mbox

diff --git a/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
index 2392ca50..2cec20fe 100644
--- a/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
+++ b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
@@ -99,6 +99,7 @@  ATTRS{idVendor}=="0763", ATTRS{idProduct}=="2012", ENV{PULSE_PROFILE_SET}="maudi
 ATTRS{idVendor}=="045e", ATTRS{idProduct}=="02bb", ENV{PULSE_PROFILE_SET}="kinect-audio.conf"
 ATTRS{idVendor}=="041e", ATTRS{idProduct}=="322c", ENV{PULSE_PROFILE_SET}="sb-omni-surround-5.1.conf"
 ATTRS{idVendor}=="0bda", ATTRS{idProduct}=="4014", ENV{PULSE_PROFILE_SET}="dell-dock-tb16-usb-audio.conf"
-ATTRS{idVendor}=="1038", ATTRS{idProduct}=="1260", ENV{PULSE_PROFILE_SET}="steelseries-arctis-usb-audio.conf"
+ATTRS{idVendor}=="1038", ATTRS{idProduct}=="1250", ENV{PULSE_PROFILE_SET}="steelseries-arctis-5-usb-audio.conf"
+ATTRS{idVendor}=="1038", ATTRS{idProduct}=="1260", ENV{PULSE_PROFILE_SET}="steelseries-arctis-7-usb-audio.conf"
 
 LABEL="pulseaudio_end"
diff --git a/src/modules/alsa/mixer/profile-sets/steelseries-arctis-5-usb-audio.conf b/src/modules/alsa/mixer/profile-sets/steelseries-arctis-5-usb-audio.conf
new file mode 100644
index 00000000..9eeda7e0
--- /dev/null
+++ b/src/modules/alsa/mixer/profile-sets/steelseries-arctis-5-usb-audio.conf
@@ -0,0 +1,45 @@ 
+# This file is part of PulseAudio.
+#
+# PulseAudio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of the
+# License, or (at your option) any later version.
+#
+# PulseAudio is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with PulseAudio; if not, see <http://www.gnu.org/licenses/>.
+
+; Steelseries Arctis 5 USB headset. The headset has a microphone and two output
+; devices. The first output device is meant for voice audio, and the second one
+; is meant for everything else. The purpose of this unusual design is to
+; provide separate volume controls for voice and other audio, which can be
+; useful in gaming.
+;
+; See default.conf for an explanation on the directives used here.
+
+[General]
+auto-profiles = yes
+
+[Mapping analog-chat]
+description = Chat
+device-strings = hw:%f,0,0
+channel-map = left,right
+paths-input = analog-input-mic
+paths-output = analog-output
+
+[Mapping analog-game]
+description = Game
+device-strings = hw:%f,1,0
+channel-map = left,right
+paths-output = analog-output
+direction = output
+
+[Profile output:analog-chat+output:analog-game+input:analog-chat]
+output-mappings = analog-chat analog-game
+input-mappings = analog-chat
+priority = 5100
+skip-probe = yes
diff --git a/src/modules/alsa/mixer/profile-sets/steelseries-arctis-usb-audio.conf b/src/modules/alsa/mixer/profile-sets/steelseries-arctis-7-usb-audio.conf
similarity index 100%
rename from src/modules/alsa/mixer/profile-sets/steelseries-arctis-usb-audio.conf
rename to src/modules/alsa/mixer/profile-sets/steelseries-arctis-7-usb-audio.conf

Comments

On Sat, 2018-01-06 at 15:03 +0100, Bert Hekman wrote:
> ---
>  .../alsa/mixer/profile-sets/90-pulseaudio.rules    |  3 +-
>  .../steelseries-arctis-5-usb-audio.conf            | 45 ++++++++++++++++++++++
>  ...io.conf => steelseries-arctis-7-usb-audio.conf} |  0
>  3 files changed, 47 insertions(+), 1 deletion(-)
>  create mode 100644 src/modules/alsa/mixer/profile-sets/steelseries-arctis-5-usb-audio.conf
>  rename src/modules/alsa/mixer/profile-sets/{steelseries-arctis-usb-audio.conf => steelseries-arctis-7-usb-audio.conf} (100%)
> 
> diff --git a/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
> index 2392ca50..2cec20fe 100644
> --- a/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
> +++ b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
> @@ -99,6 +99,7 @@ ATTRS{idVendor}=="0763", ATTRS{idProduct}=="2012", ENV{PULSE_PROFILE_SET}="maudi
>  ATTRS{idVendor}=="045e", ATTRS{idProduct}=="02bb", ENV{PULSE_PROFILE_SET}="kinect-audio.conf"
>  ATTRS{idVendor}=="041e", ATTRS{idProduct}=="322c", ENV{PULSE_PROFILE_SET}="sb-omni-surround-5.1.conf"
>  ATTRS{idVendor}=="0bda", ATTRS{idProduct}=="4014", ENV{PULSE_PROFILE_SET}="dell-dock-tb16-usb-audio.conf"
> -ATTRS{idVendor}=="1038", ATTRS{idProduct}=="1260", ENV{PULSE_PROFILE_SET}="steelseries-arctis-usb-audio.conf"
> +ATTRS{idVendor}=="1038", ATTRS{idProduct}=="1250", ENV{PULSE_PROFILE_SET}="steelseries-arctis-5-usb-audio.conf"
> +ATTRS{idVendor}=="1038", ATTRS{idProduct}=="1260", ENV{PULSE_PROFILE_SET}="steelseries-arctis-7-usb-audio.conf"
>  
>  LABEL="pulseaudio_end"
> diff --git a/src/modules/alsa/mixer/profile-sets/steelseries-arctis-5-usb-audio.conf b/src/modules/alsa/mixer/profile-sets/steelseries-arctis-5-usb-audio.conf
> new file mode 100644
> index 00000000..9eeda7e0
> --- /dev/null
> +++ b/src/modules/alsa/mixer/profile-sets/steelseries-arctis-5-usb-audio.conf
> @@ -0,0 +1,45 @@
> +# This file is part of PulseAudio.
> +#
> +# PulseAudio is free software; you can redistribute it and/or modify
> +# it under the terms of the GNU Lesser General Public License as
> +# published by the Free Software Foundation; either version 2.1 of the
> +# License, or (at your option) any later version.
> +#
> +# PulseAudio is distributed in the hope that it will be useful, but
> +# WITHOUT ANY WARRANTY; without even the implied warranty of
> +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
> +# General Public License for more details.
> +#
> +# You should have received a copy of the GNU Lesser General Public License
> +# along with PulseAudio; if not, see <http://www.gnu.org/licenses/>.
> +
> +; Steelseries Arctis 5 USB headset. The headset has a microphone and two output
> +; devices. The first output device is meant for voice audio, and the second one
> +; is meant for everything else. The purpose of this unusual design is to
> +; provide separate volume controls for voice and other audio, which can be
> +; useful in gaming.
> +;
> +; See default.conf for an explanation on the directives used here.
> +
> +[General]
> +auto-profiles = yes
> +
> +[Mapping analog-chat]
> +description = Chat
> +device-strings = hw:%f,0,0
> +channel-map = left,right
> +paths-input = analog-input-mic
> +paths-output = analog-output
> +
> +[Mapping analog-game]
> +description = Game
> +device-strings = hw:%f,1,0
> +channel-map = left,right
> +paths-output = analog-output
> +direction = output
> +
> +[Profile output:analog-chat+output:analog-game+input:analog-chat]
> +output-mappings = analog-chat analog-game
> +input-mappings = analog-chat
> +priority = 5100
> +skip-probe = yes
> diff --git a/src/modules/alsa/mixer/profile-sets/steelseries-arctis-usb-audio.conf b/src/modules/alsa/mixer/profile-sets/steelseries-arctis-7-usb-audio.conf
> similarity index 100%
> rename from src/modules/alsa/mixer/profile-sets/steelseries-arctis-usb-audio.conf
> rename to src/modules/alsa/mixer/profile-sets/steelseries-arctis-7-usb-audio.conf

The main difference to Arctis 7 seems to be that the "chat" device
supports stereo audio. Is there any difference in sound quality between
the "chat" and "game" devices?

Can you send the output of "amixer -c1" (replace 1 with the correct
card index if the headset card index is not 1)? Your configuration
probably doesn't handle volume correctly, because both devices have
been configured to use the analog-output path, which means that both
devices will control the same volumes in the alsa mixer. The volume
control needs to be separated for the two devices.
Between the Arctis 5 and 7, that seems to be the case.

I do not hear much of a difference between the sound quality. However, it
seems that the "chat" output doesn't go as loud as the game output. I can
change the volume of the chat output using alsamixer, but I can't in the
Ubuntu (17.10) gnome settings applet. (But that is probably the one you
mean.)

Here is the output of "amixer -c1":

Simple mixer control 'PCM',0 Capabilities: pvolume pswitch pswitch-joined
Playback channels: Front Left - Front Right Limits: Playback 0 - 55 Mono:
Front Left: Playback 33 [60%] [-17.00dB] [on] Front Right: Playback 33
[60%] [-17.00dB] [on] Simple mixer control 'Sidetone',0 Capabilities:
pvolume pvolume-joined pswitch pswitch-joined Playback channels: Mono
Limits: Playback 0 - 4096 Mono: Playback 94 [2%] [0.36dB] [on] Simple mixer
control 'Mic',0 Capabilities: cvolume cvolume-joined cswitch cswitch-joined
Capture channels: Mono Limits: Capture 0 - 29 Mono: Capture 29 [100%]
[-1.00dB] [on] Simple mixer control 'Com Speaker',0 Capabilities: pvolume
pswitch pswitch-joined Playback channels: Front Left - Front Right Limits:
Playback 0 - 55 Mono: Front Left: Playback 40 [73%] [-10.00dB] [on] Front
Right: Playback 40 [73%] [-10.00dB] [on]

2018-01-29 0:34 GMT+01:00 Tanu Kaskinen <tanuk@iki.fi>:

> On Sat, 2018-01-06 at 15:03 +0100, Bert Hekman wrote:
> > ---
> >  .../alsa/mixer/profile-sets/90-pulseaudio.rules    |  3 +-
> >  .../steelseries-arctis-5-usb-audio.conf            | 45
> ++++++++++++++++++++++
> >  ...io.conf => steelseries-arctis-7-usb-audio.conf} |  0
> >  3 files changed, 47 insertions(+), 1 deletion(-)
> >  create mode 100644 src/modules/alsa/mixer/profile-sets/steelseries-
> arctis-5-usb-audio.conf
> >  rename src/modules/alsa/mixer/profile-sets/{steelseries-arctis-usb-audio.conf
> => steelseries-arctis-7-usb-audio.conf} (100%)
> >
> > diff --git a/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
> b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
> > index 2392ca50..2cec20fe 100644
> > --- a/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
> > +++ b/src/modules/alsa/mixer/profile-sets/90-pulseaudio.rules
> > @@ -99,6 +99,7 @@ ATTRS{idVendor}=="0763", ATTRS{idProduct}=="2012",
> ENV{PULSE_PROFILE_SET}="maudi
> >  ATTRS{idVendor}=="045e", ATTRS{idProduct}=="02bb",
> ENV{PULSE_PROFILE_SET}="kinect-audio.conf"
> >  ATTRS{idVendor}=="041e", ATTRS{idProduct}=="322c",
> ENV{PULSE_PROFILE_SET}="sb-omni-surround-5.1.conf"
> >  ATTRS{idVendor}=="0bda", ATTRS{idProduct}=="4014",
> ENV{PULSE_PROFILE_SET}="dell-dock-tb16-usb-audio.conf"
> > -ATTRS{idVendor}=="1038", ATTRS{idProduct}=="1260",
> ENV{PULSE_PROFILE_SET}="steelseries-arctis-usb-audio.conf"
> > +ATTRS{idVendor}=="1038", ATTRS{idProduct}=="1250",
> ENV{PULSE_PROFILE_SET}="steelseries-arctis-5-usb-audio.conf"
> > +ATTRS{idVendor}=="1038", ATTRS{idProduct}=="1260",
> ENV{PULSE_PROFILE_SET}="steelseries-arctis-7-usb-audio.conf"
> >
> >  LABEL="pulseaudio_end"
> > diff --git a/src/modules/alsa/mixer/profile-sets/steelseries-arctis-5-usb-audio.conf
> b/src/modules/alsa/mixer/profile-sets/steelseries-arctis-5-usb-audio.conf
> > new file mode 100644
> > index 00000000..9eeda7e0
> > --- /dev/null
> > +++ b/src/modules/alsa/mixer/profile-sets/steelseries-
> arctis-5-usb-audio.conf
> > @@ -0,0 +1,45 @@
> > +# This file is part of PulseAudio.
> > +#
> > +# PulseAudio is free software; you can redistribute it and/or modify
> > +# it under the terms of the GNU Lesser General Public License as
> > +# published by the Free Software Foundation; either version 2.1 of the
> > +# License, or (at your option) any later version.
> > +#
> > +# PulseAudio is distributed in the hope that it will be useful, but
> > +# WITHOUT ANY WARRANTY; without even the implied warranty of
> > +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
> > +# General Public License for more details.
> > +#
> > +# You should have received a copy of the GNU Lesser General Public
> License
> > +# along with PulseAudio; if not, see <http://www.gnu.org/licenses/>.
> > +
> > +; Steelseries Arctis 5 USB headset. The headset has a microphone and
> two output
> > +; devices. The first output device is meant for voice audio, and the
> second one
> > +; is meant for everything else. The purpose of this unusual design is to
> > +; provide separate volume controls for voice and other audio, which can
> be
> > +; useful in gaming.
> > +;
> > +; See default.conf for an explanation on the directives used here.
> > +
> > +[General]
> > +auto-profiles = yes
> > +
> > +[Mapping analog-chat]
> > +description = Chat
> > +device-strings = hw:%f,0,0
> > +channel-map = left,right
> > +paths-input = analog-input-mic
> > +paths-output = analog-output
> > +
> > +[Mapping analog-game]
> > +description = Game
> > +device-strings = hw:%f,1,0
> > +channel-map = left,right
> > +paths-output = analog-output
> > +direction = output
> > +
> > +[Profile output:analog-chat+output:analog-game+input:analog-chat]
> > +output-mappings = analog-chat analog-game
> > +input-mappings = analog-chat
> > +priority = 5100
> > +skip-probe = yes
> > diff --git a/src/modules/alsa/mixer/profile-sets/steelseries-arctis-usb-audio.conf
> b/src/modules/alsa/mixer/profile-sets/steelseries-arctis-7-usb-audio.conf
> > similarity index 100%
> > rename from src/modules/alsa/mixer/profile-sets/steelseries-
> arctis-usb-audio.conf
> > rename to src/modules/alsa/mixer/profile-sets/steelseries-
> arctis-7-usb-audio.conf
>
> The main difference to Arctis 7 seems to be that the "chat" device
> supports stereo audio. Is there any difference in sound quality between
> the "chat" and "game" devices?
>
> Can you send the output of "amixer -c1" (replace 1 with the correct
> card index if the headset card index is not 1)? Your configuration
> probably doesn't handle volume correctly, because both devices have
> been configured to use the analog-output path, which means that both
> devices will control the same volumes in the alsa mixer. The volume
> control needs to be separated for the two devices.
>
> --
> Tanu
>
> https://liberapay.com/tanuk
> https://www.patreon.com/tanuk
> _______________________________________________
> pulseaudio-discuss mailing list
> pulseaudio-discuss@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss
>
On Mon, 2018-01-29 at 13:57 +0100, Bert Hekman wrote:
> Between the Arctis 5 and 7, that seems to be the case.
> 
> I do not hear much of a difference between the sound quality. However, it
> seems that the "chat" output doesn't go as loud as the game output. I can
> change the volume of the chat output using alsamixer, but I can't in the
> Ubuntu (17.10) gnome settings applet. (But that is probably the one you
> mean.)
> 
> Here is the output of "amixer -c1":
> 
> Simple mixer control 'PCM',0 Capabilities: pvolume pswitch pswitch-joined
> Playback channels: Front Left - Front Right Limits: Playback 0 - 55 Mono:
> Front Left: Playback 33 [60%] [-17.00dB] [on] Front Right: Playback 33
> [60%] [-17.00dB] [on] Simple mixer control 'Sidetone',0 Capabilities:
> pvolume pvolume-joined pswitch pswitch-joined Playback channels: Mono
> Limits: Playback 0 - 4096 Mono: Playback 94 [2%] [0.36dB] [on] Simple mixer
> control 'Mic',0 Capabilities: cvolume cvolume-joined cswitch cswitch-joined
> Capture channels: Mono Limits: Capture 0 - 29 Mono: Capture 29 [100%]
> [-1.00dB] [on] Simple mixer control 'Com Speaker',0 Capabilities: pvolume
> pswitch pswitch-joined Playback channels: Front Left - Front Right Limits:
> Playback 0 - 55 Mono: Front Left: Playback 40 [73%] [-10.00dB] [on] Front
> Right: Playback 40 [73%] [-10.00dB] [on]

(Plain text emails would be nice, less chance of formatting getting
messed up.)

If you change the volume with alsamixer, what volume do the PCM and Com
Speaker elements control? The "chat" or the "game" device, or both? I
guess PCM controls only the "game" device, since the gnome settings
applet will only change the PCM element volume.
On Sun, 2018-02-04 at 17:22 +0100, Bert Hekman wrote:
> In alsamixer, PCM only controls the "game" output and Com Speaker only
> controls the "chat" output.

Ok, could you make an updated patch that adds dedicated output path
configuration files for this card? The "game" path should use PCM for
volume control and the "chat" path should use Com Speaker.

It would be possible to use analog-output path for the "game" output,
but I imagine it will look nicer in user interfaces if the two choices
are "Game" and "Chat" rather than "Analog Output" and "Chat".

There's probably no need to write custom path configuration for the
input, you can use analog-input-mic as you did in the first version of
the patch.