* USB Wireless device support @ 2020-12-09 13:30 Bastien Nocera 2021-01-13 14:36 ` Bastien Nocera 0 siblings, 1 reply; 9+ messages in thread From: Bastien Nocera @ 2020-12-09 13:30 UTC (permalink / raw) To: alsa-devel Hey, I've recently bought a SteelSeries Arctis 1 wireless headset: https://steelseries.com/gaming-headsets/arctis-1-wireless-xbox and wanted to write a kernel driver to export a few features of the device, and needed some help getting started. The receiver shows up as a audio class USB device, with extra features on a separate USB interface.[1] The extra features that can be accessed are: - Presence detection. I wanted to use that so PulseAudio or Pipewire could make routing decisions based on whether the headset is available, or probably better, implementing a "jack detection" emulation for the main audio interface? - A slider to change the sidetone volume - Export the battery level The latter is the only one I know how to do, so I'd be happy with any pointers or examples about the first two items. Cheers [1]: User-space code that accesses those features: https://github.com/Sapd/HeadsetControl/blob/master/src/devices/steelseries_arctis_1_xbox.c ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: USB Wireless device support 2020-12-09 13:30 USB Wireless device support Bastien Nocera @ 2021-01-13 14:36 ` Bastien Nocera 2021-01-13 14:49 ` Takashi Iwai 0 siblings, 1 reply; 9+ messages in thread From: Bastien Nocera @ 2021-01-13 14:36 UTC (permalink / raw) To: alsa-devel Hey, On Wed, 2020-12-09 at 14:30 +0100, Bastien Nocera wrote: > Hey, > > I've recently bought a SteelSeries Arctis 1 wireless headset: > https://steelseries.com/gaming-headsets/arctis-1-wireless-xbox > and wanted to write a kernel driver to export a few features of the > device, and needed some help getting started. > > The receiver shows up as a audio class USB device, with extra > features > on a separate USB interface.[1] > > The extra features that can be accessed are: > - Presence detection. I wanted to use that so PulseAudio or Pipewire > could make routing decisions based on whether the headset is > available, > or probably better, implementing a "jack detection" emulation for the > main audio interface? > - A slider to change the sidetone volume > - Export the battery level > > The latter is the only one I know how to do, so I'd be happy with any > pointers or examples about the first two items. I sent this in December and didn't get any answers, and I would appreciate any guidance/examples if you have any into implementing this. I would imagine that the new features would be implemented through a separate ALSA device with few features, which PulseAudio/Pipewire could merge with the existing USB audio device. Cheers > [1]: User-space code that accesses those features: > > https://github.com/Sapd/HeadsetControl/blob/master/src/devices/steelseries_arctis_1_xbox.c ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: USB Wireless device support 2021-01-13 14:36 ` Bastien Nocera @ 2021-01-13 14:49 ` Takashi Iwai 2021-01-13 15:03 ` Bastien Nocera 0 siblings, 1 reply; 9+ messages in thread From: Takashi Iwai @ 2021-01-13 14:49 UTC (permalink / raw) To: Bastien Nocera; +Cc: alsa-devel On Wed, 13 Jan 2021 15:36:19 +0100, Bastien Nocera wrote: > > Hey, > > On Wed, 2020-12-09 at 14:30 +0100, Bastien Nocera wrote: > > Hey, > > > > I've recently bought a SteelSeries Arctis 1 wireless headset: > > https://steelseries.com/gaming-headsets/arctis-1-wireless-xbox > > and wanted to write a kernel driver to export a few features of the > > device, and needed some help getting started. > > > > The receiver shows up as a audio class USB device, with extra > > features > > on a separate USB interface.[1] > > > > The extra features that can be accessed are: > > - Presence detection. I wanted to use that so PulseAudio or Pipewire > > could make routing decisions based on whether the headset is > > available, > > or probably better, implementing a "jack detection" emulation for the > > main audio interface? > > - A slider to change the sidetone volume > > - Export the battery level > > > > The latter is the only one I know how to do, so I'd be happy with any > > pointers or examples about the first two items. > > > I sent this in December and didn't get any answers, and I would > appreciate any guidance/examples if you have any into implementing > this. Judging from the link, is it controlled through HID? If so, it's primarily done by a HID driver, and it doesn't belong to the sound card stuff, so far. Though.... > I would imagine that the new features would be implemented through a > separate ALSA device with few features, which PulseAudio/Pipewire could > merge with the existing USB audio device. ... given that it's implemented in a HID driver, the integration to the system is a different question. But unless it's implemented as a sound card device, the rest will become a totally different, e.g. another PA or PW module. thanks, Takashi > > Cheers > > > [1]: User-space code that accesses those features: > > > > https://github.com/Sapd/HeadsetControl/blob/master/src/devices/steelseries_arctis_1_xbox.c > > ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: USB Wireless device support 2021-01-13 14:49 ` Takashi Iwai @ 2021-01-13 15:03 ` Bastien Nocera 2021-01-13 15:08 ` Takashi Iwai 0 siblings, 1 reply; 9+ messages in thread From: Bastien Nocera @ 2021-01-13 15:03 UTC (permalink / raw) To: Takashi Iwai; +Cc: alsa-devel On Wed, 2021-01-13 at 15:49 +0100, Takashi Iwai wrote: > On Wed, 13 Jan 2021 15:36:19 +0100, > Bastien Nocera wrote: > > > > Hey, > > > > On Wed, 2020-12-09 at 14:30 +0100, Bastien Nocera wrote: > > > Hey, > > > > > > I've recently bought a SteelSeries Arctis 1 wireless headset: > > > https://steelseries.com/gaming-headsets/arctis-1-wireless-xbox > > > and wanted to write a kernel driver to export a few features of > > > the > > > device, and needed some help getting started. > > > > > > The receiver shows up as a audio class USB device, with extra > > > features > > > on a separate USB interface.[1] > > > > > > The extra features that can be accessed are: > > > - Presence detection. I wanted to use that so PulseAudio or > > > Pipewire > > > could make routing decisions based on whether the headset is > > > available, > > > or probably better, implementing a "jack detection" emulation for > > > the > > > main audio interface? > > > - A slider to change the sidetone volume > > > - Export the battery level > > > > > > The latter is the only one I know how to do, so I'd be happy with > > > any > > > pointers or examples about the first two items. > > > > > > I sent this in December and didn't get any answers, and I would > > appreciate any guidance/examples if you have any into implementing > > this. > > Judging from the link, is it controlled through HID? If so, it's > primarily done by a HID driver, and it doesn't belong to the sound > card stuff, so far. > Though.... > > > I would imagine that the new features would be implemented through > > a > > separate ALSA device with few features, which PulseAudio/Pipewire > > could > > merge with the existing USB audio device. > > ... given that it's implemented in a HID driver, the integration to > the system is a different question. But unless it's implemented as a > sound card device, the rest will become a totally different, > e.g. another PA or PW module. I think that it might be good to have the sidetone configuration implemented as a channel mixer, so it could be shown along with the device volume in sound settings. I believe there's already a device group feature in PulseAudio that could be used to merge the sidetone level with the rest of the USB audio mixers. Is there an example of a mixer like that implemented in a hid or another type of non-ALSA/sound driver? ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: USB Wireless device support 2021-01-13 15:03 ` Bastien Nocera @ 2021-01-13 15:08 ` Takashi Iwai 2021-01-13 15:13 ` Bastien Nocera 0 siblings, 1 reply; 9+ messages in thread From: Takashi Iwai @ 2021-01-13 15:08 UTC (permalink / raw) To: Bastien Nocera; +Cc: alsa-devel On Wed, 13 Jan 2021 16:03:39 +0100, Bastien Nocera wrote: > > On Wed, 2021-01-13 at 15:49 +0100, Takashi Iwai wrote: > > On Wed, 13 Jan 2021 15:36:19 +0100, > > Bastien Nocera wrote: > > > > > > Hey, > > > > > > On Wed, 2020-12-09 at 14:30 +0100, Bastien Nocera wrote: > > > > Hey, > > > > > > > > I've recently bought a SteelSeries Arctis 1 wireless headset: > > > > https://steelseries.com/gaming-headsets/arctis-1-wireless-xbox > > > > and wanted to write a kernel driver to export a few features of > > > > the > > > > device, and needed some help getting started. > > > > > > > > The receiver shows up as a audio class USB device, with extra > > > > features > > > > on a separate USB interface.[1] > > > > > > > > The extra features that can be accessed are: > > > > - Presence detection. I wanted to use that so PulseAudio or > > > > Pipewire > > > > could make routing decisions based on whether the headset is > > > > available, > > > > or probably better, implementing a "jack detection" emulation for > > > > the > > > > main audio interface? > > > > - A slider to change the sidetone volume > > > > - Export the battery level > > > > > > > > The latter is the only one I know how to do, so I'd be happy with > > > > any > > > > pointers or examples about the first two items. > > > > > > > > > I sent this in December and didn't get any answers, and I would > > > appreciate any guidance/examples if you have any into implementing > > > this. > > > > Judging from the link, is it controlled through HID? If so, it's > > primarily done by a HID driver, and it doesn't belong to the sound > > card stuff, so far. > > Though.... > > > > > I would imagine that the new features would be implemented through > > > a > > > separate ALSA device with few features, which PulseAudio/Pipewire > > > could > > > merge with the existing USB audio device. > > > > ... given that it's implemented in a HID driver, the integration to > > the system is a different question. But unless it's implemented as a > > sound card device, the rest will become a totally different, > > e.g. another PA or PW module. > > I think that it might be good to have the sidetone configuration > implemented as a channel mixer, so it could be shown along with the > device volume in sound settings. > > I believe there's already a device group feature in PulseAudio that > could be used to merge the sidetone level with the rest of the USB > audio mixers. > > Is there an example of a mixer like that implemented in a hid or > another type of non-ALSA/sound driver? Nothing so far, and that's the problem. HID is managed in a completely different layer, hence the integration needs to be done in a higher level like PA, I suppose. In theory we might be able to extend UCM to handle the other external devices, though. Takashi ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: USB Wireless device support 2021-01-13 15:08 ` Takashi Iwai @ 2021-01-13 15:13 ` Bastien Nocera 2021-01-13 15:17 ` Takashi Iwai 0 siblings, 1 reply; 9+ messages in thread From: Bastien Nocera @ 2021-01-13 15:13 UTC (permalink / raw) To: Takashi Iwai; +Cc: alsa-devel On Wed, 2021-01-13 at 16:08 +0100, Takashi Iwai wrote: > <snip> > Nothing so far, and that's the problem. HID is managed in a > completely different layer, hence the integration needs to be done in > a higher level like PA, I suppose. In theory we might be able to > extend UCM to handle the other external devices, though. hid-prodikeys.c seems to do some MIDI stuff... ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: USB Wireless device support 2021-01-13 15:13 ` Bastien Nocera @ 2021-01-13 15:17 ` Takashi Iwai 2021-01-13 15:41 ` Bastien Nocera 0 siblings, 1 reply; 9+ messages in thread From: Takashi Iwai @ 2021-01-13 15:17 UTC (permalink / raw) To: Bastien Nocera; +Cc: alsa-devel On Wed, 13 Jan 2021 16:13:40 +0100, Bastien Nocera wrote: > > On Wed, 2021-01-13 at 16:08 +0100, Takashi Iwai wrote: > > <snip> > > Nothing so far, and that's the problem. HID is managed in a > > completely different layer, hence the integration needs to be done in > > a higher level like PA, I suppose. In theory we might be able to > > extend UCM to handle the other external devices, though. > > hid-prodikeys.c seems to do some MIDI stuff... It creates its own sound card. But you want to use the mixer switch for the existing audio interface, right? Takashi ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: USB Wireless device support 2021-01-13 15:17 ` Takashi Iwai @ 2021-01-13 15:41 ` Bastien Nocera 2021-01-13 15:43 ` Takashi Iwai 0 siblings, 1 reply; 9+ messages in thread From: Bastien Nocera @ 2021-01-13 15:41 UTC (permalink / raw) To: Takashi Iwai; +Cc: alsa-devel On Wed, 2021-01-13 at 16:17 +0100, Takashi Iwai wrote: > On Wed, 13 Jan 2021 16:13:40 +0100, > Bastien Nocera wrote: > > > > On Wed, 2021-01-13 at 16:08 +0100, Takashi Iwai wrote: > > > <snip> > > > Nothing so far, and that's the problem. HID is managed in a > > > completely different layer, hence the integration needs to be > > > done in > > > a higher level like PA, I suppose. In theory we might be able to > > > extend UCM to handle the other external devices, though. > > > > hid-prodikeys.c seems to do some MIDI stuff... > > It creates its own sound card. But you want to use the mixer switch > for the existing audio interface, right? My idea was to create my own sound card (it's a separate USB interface after all) exporting the sidetone mixer, and figure out how to merge it with the USB audio interface at PulseAudio's level. Otherwise ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: USB Wireless device support 2021-01-13 15:41 ` Bastien Nocera @ 2021-01-13 15:43 ` Takashi Iwai 0 siblings, 0 replies; 9+ messages in thread From: Takashi Iwai @ 2021-01-13 15:43 UTC (permalink / raw) To: Bastien Nocera; +Cc: alsa-devel On Wed, 13 Jan 2021 16:41:04 +0100, Bastien Nocera wrote: > > On Wed, 2021-01-13 at 16:17 +0100, Takashi Iwai wrote: > > On Wed, 13 Jan 2021 16:13:40 +0100, > > Bastien Nocera wrote: > > > > > > On Wed, 2021-01-13 at 16:08 +0100, Takashi Iwai wrote: > > > > <snip> > > > > Nothing so far, and that's the problem. HID is managed in a > > > > completely different layer, hence the integration needs to be > > > > done in > > > > a higher level like PA, I suppose. In theory we might be able to > > > > extend UCM to handle the other external devices, though. > > > > > > hid-prodikeys.c seems to do some MIDI stuff... > > > > It creates its own sound card. But you want to use the mixer switch > > for the existing audio interface, right? > > My idea was to create my own sound card (it's a separate USB interface > after all) exporting the sidetone mixer, and figure out how to merge it > with the USB audio interface at PulseAudio's level. It would work, then. OTOH, if integrating in PA, it's not necessarily to be ALSA mixer interface but a simple input device, too... Takashi ^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2021-01-13 15:44 UTC | newest] Thread overview: 9+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2020-12-09 13:30 USB Wireless device support Bastien Nocera 2021-01-13 14:36 ` Bastien Nocera 2021-01-13 14:49 ` Takashi Iwai 2021-01-13 15:03 ` Bastien Nocera 2021-01-13 15:08 ` Takashi Iwai 2021-01-13 15:13 ` Bastien Nocera 2021-01-13 15:17 ` Takashi Iwai 2021-01-13 15:41 ` Bastien Nocera 2021-01-13 15:43 ` Takashi Iwai
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.