All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: hid: microsoft: Add rumble support for Xbox One S controller
@ 2018-09-26 15:23 ` dollinger.florian
  0 siblings, 0 replies; 5+ messages in thread
From: dollinger.florian @ 2018-09-26 15:23 UTC (permalink / raw)
  To: 'Bastien Nocera', andrew.smirnov
  Cc: linux-kernel, linux-input-owner, linux-input

Hey Bastien,

> Probably because he didn't know about it, and how would he?

Hum, it's the first hit when you search for something like 'xbox one s driver linux' since half an year or longer 😊

> I spent quite a bit of time trying to get the XBox One S controller working over Bluetooth, without success, and I see that you have a patch for that which you didn't send upstream either:
https://github.com/atar-axis/xpadneo/blob/master/misc/kernel_patches/0001-fix_bluetooth_reconnect.patch

Jap, I just never pushed it because I never pushed anything to the linux kernel and I don't really know how the whole process works^^ Furthermore I wanted to fix possible before, but it looks like the driver is stable enough to push it now.

> I can imagine that a large portion of the driver can be integrated in the existing XBox pad driver, with each feature added in individual patches.

Would be great! But ist the xpad driver really the right place?

First of all, the BT interface is using HID, USB does not.
Furthermore, the driver is currently around 1,3k lines long - for a single device and only BT... (okay yes, there are a lot of comments in it).
But anyway, is it really a good idea to put everything into hid-microsoft?
Moreover, there is another interface which I am trying to support at the moment - the one which is used by the XBOX (WiFi).

I think in the end the whole hid-microsoft thingy will get blown-up a bit - right?
Or, everything is scattered over many places (hid-microsoft, xpad, another driver fort he wifi-interface).

Isn't it possible to use "one driver per device" in the kernel too, like I did?

> If I get the time, there are good chances I will send a patch to integrate the battery reporting in the existing driver at least, and then add support for missing buttons if there's a problem there (I see that mentioned in the README).

Jap, the wrong mapping is possibly the biggest problem of all. Battery support and FF is more "nice to have" but not really crucial. 

> "Trigger Force Feedback" is likely something that would need to be integrated at a lower level, this is probably not something we'd want to have replicated in each driver.

True.


Best regards, Flo




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: hid: microsoft: Add rumble support for Xbox One S controller
@ 2018-09-26 15:23 ` dollinger.florian
  0 siblings, 0 replies; 5+ messages in thread
From: dollinger.florian @ 2018-09-26 15:23 UTC (permalink / raw)
  To: 'Bastien Nocera', andrew.smirnov
  Cc: linux-kernel, linux-input-owner, linux-input

Hey Bastien,

> Probably because he didn't know about it, and how would he?

Hum, it's the first hit when you search for something like 'xbox one s driver linux' since half an year or longer 😊

> I spent quite a bit of time trying to get the XBox One S controller working over Bluetooth, without success, and I see that you have a patch for that which you didn't send upstream either:
https://github.com/atar-axis/xpadneo/blob/master/misc/kernel_patches/0001-fix_bluetooth_reconnect.patch

Jap, I just never pushed it because I never pushed anything to the linux kernel and I don't really know how the whole process works^^ Furthermore I wanted to fix possible before, but it looks like the driver is stable enough to push it now.

> I can imagine that a large portion of the driver can be integrated in the existing XBox pad driver, with each feature added in individual patches.

Would be great! But ist the xpad driver really the right place?

First of all, the BT interface is using HID, USB does not.
Furthermore, the driver is currently around 1,3k lines long - for a single device and only BT... (okay yes, there are a lot of comments in it).
But anyway, is it really a good idea to put everything into hid-microsoft?
Moreover, there is another interface which I am trying to support at the moment - the one which is used by the XBOX (WiFi).

I think in the end the whole hid-microsoft thingy will get blown-up a bit - right?
Or, everything is scattered over many places (hid-microsoft, xpad, another driver fort he wifi-interface).

Isn't it possible to use "one driver per device" in the kernel too, like I did?

> If I get the time, there are good chances I will send a patch to integrate the battery reporting in the existing driver at least, and then add support for missing buttons if there's a problem there (I see that mentioned in the README).

Jap, the wrong mapping is possibly the biggest problem of all. Battery support and FF is more "nice to have" but not really crucial. 

> "Trigger Force Feedback" is likely something that would need to be integrated at a lower level, this is probably not something we'd want to have replicated in each driver.

True.


Best regards, Flo

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: hid: microsoft: Add rumble support for Xbox One S controller
  2018-09-26 18:02       ` Bastien Nocera
@ 2018-09-26 22:50         ` Florian Dollinger
  0 siblings, 0 replies; 5+ messages in thread
From: Florian Dollinger @ 2018-09-26 22:50 UTC (permalink / raw)
  To: Bastien Nocera, andrew.smirnov; +Cc: linux-kernel, linux-bluetooth, linux-input

> Sure it is, but:
> - it's not an "XBox One S controller", it's a variant of the "XBox One
> controller" shipped with the XBox One S.
> - we discussed this on the linux-bluetooth mailing-list in August 2016:
>    https://www.spinics.net/lists/linux-bluetooth/msg68102.html
>    revived the thread in 2017:
>    https://www.spinics.net/lists/linux-bluetooth/msg72750.html
>    and discussed the force feedback in particular in August this year:
>    https://www.spinics.net/lists/linux-input/msg57744.html
> - why would we look for a "driver" when there's already one in the
> kernel that supports all the xbox controllers except this one? :)
> 
> Really, as much as it's nice to find working code for this device, it's
> surprising you didn't contact any kernel developer before, rather than
> us having to find you.

Fair enough :)

> Yes, but that's not the way the drivers are usually arranged. They're
> arranged by vendors, so this driver would need to be merged into the
> "hid-microsoft.c" driver.

That's probably the main reason for not getting in touch earlier, I 
really don't like the idea of putting everything into the same driver 
just because it is the same vendor - or at leas the same name (even if 
Microsoft Xbox has nearly nothing to do with other parts of Microsoft).

> I'm pretty sure that the USB version can also be made to use HID.

I really don't think so, I already gave it a try. At least not "out of 
the box".

> I have no idea how the RF protocol would work though. I imagine it
> requires a dongle, or does it actually use Wi-Fi? (that would be
> surprising...).

In theory it does need one, but it is nothing more than normal Wi-Fi 
(2,4 and 5 GHz) - you can talk to the gamepad using any Wi-Fi card / 
stick you want. The problem is, that the connection is secured somehow.
If you are interested, take a look here: 
https://github.com/atar-axis/xpadneo/wiki/Microsoft-Xbox-One-Wireless-Adapter

> Anyway, I don't have much time to work on it right this minute, but it
> would be great if you could send your Bluetooth patch to start with,
> and we can iterate on that, and fix the other problems as we clear the
> priority list.

Jap, I will do that - Thank you so far!

> Cheers

Dito.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: hid: microsoft: Add rumble support for Xbox One S controller
  2018-09-26 12:51 ` Dollinger Florian
@ 2018-09-26 13:45   ` Bastien Nocera
  2018-09-26 15:15     ` AW: " dollinger.florian
  0 siblings, 1 reply; 5+ messages in thread
From: Bastien Nocera @ 2018-09-26 13:45 UTC (permalink / raw)
  To: Dollinger Florian, andrew.smirnov
  Cc: linux-kernel, linux-input-owner, linux-input

Hey Florian,

On Wed, 2018-09-26 at 14:51 +0200, Dollinger Florian wrote:
> From: Florian Dollinger <dollinger.florian@gmx.de>
> 
> Hi there! Why do you re-engineer the wheel? :) There is already a
> fully functional and tested driver out there (
> https://github.com/atar-axis/xpadneo). Would be much easier to help
> me (the owner of xpadneo) to push it into the kernel.

Probably because he didn't know about it, and how would he? I also
didn't know about it, because it didn't exist last I worked on those
joypads.

I spent quite a bit of time trying to get the XBox One S controller
working over Bluetooth, without success, and I see that you have a
patch for that which you didn't send upstream either:
https://github.com/atar-axis/xpadneo/blob/master/misc/kernel_patches/0001-fix_bluetooth_reconnect.patch

I can imagine that a large portion of the driver can be integrated in
the existing XBox pad driver, with each feature added in individual
patches.

If I get the time, there are good chances I will send a patch to
integrate the battery reporting in the existing driver at least, and
then add support for missing buttons if there's a problem there (I see
that mentioned in the README).

"Trigger Force Feedback" is likely something that would need to be
integrated at a lower level, this is probably not something we'd want
to have replicated in each driver.

Cheers


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: hid: microsoft: Add rumble support for Xbox One S controller
  2018-08-10  0:17 [PATCH] " Andrey Smirnov
@ 2018-09-26 12:51 ` Dollinger Florian
  2018-09-26 13:45   ` Bastien Nocera
  0 siblings, 1 reply; 5+ messages in thread
From: Dollinger Florian @ 2018-09-26 12:51 UTC (permalink / raw)
  To: andrew.smirnov
  Cc: linux-kernel, linux-input-owner, linux-input, Florian Dollinger

From: Florian Dollinger <dollinger.florian@gmx.de>

Hi there! Why do you re-engineer the wheel? :) There is already a fully functional and tested driver out there (https://github.com/atar-axis/xpadneo). Would be much easier to help me (the owner of xpadneo) to push it into the kernel.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2018-09-26 22:50 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-09-26 15:23 hid: microsoft: Add rumble support for Xbox One S controller dollinger.florian
2018-09-26 15:23 ` dollinger.florian
  -- strict thread matches above, loose matches on Subject: below --
2018-08-10  0:17 [PATCH] " Andrey Smirnov
2018-09-26 12:51 ` Dollinger Florian
2018-09-26 13:45   ` Bastien Nocera
2018-09-26 15:15     ` AW: " dollinger.florian
2018-09-26 18:02       ` Bastien Nocera
2018-09-26 22:50         ` Florian Dollinger

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.