The SDL forums have moved to discourse.libsdl.org.
This is just a read-only archive of the previous forums, to keep old links working.


SDL Forum Index
SDL
Simple Directmedia Layer Forums
Android Lollipop, Xbox 360 wireless controllers: no mapping
theGiallo


Joined: 03 Nov 2014
Posts: 11
Location: Genova, IT
On NVidia shield tablet with android Jelly Bean the xbox 360 pads were correctly recognized as SDL_GameController and had a working mapping. Now I've updated to Lollipop and they have no more mapping. I made the mapping by hand (that is the same as it was before). When I add it it says it's new.

Code:
int ret = SDL_GameControllerAddMapping("58626f782033363020576972656c6573,Xbox 360 Wireless Controller,a:b0,b:b1,x:b2,y:b3,start:b6,leftstick:b7,rightstick:b8,leftshoulder:b9,rightshoulder:b10,dpup:b11,dpdown:b12,dpleft:b13,dpright:b14,leftx:a0,lefty:a1,rightx:a2,righty:a3,lefttrigger:a4,righttrigger:a5"); // returns 1 the first time called


The receiver has name "Xbox 360 Wireless Receiver". When I connect it to the tablet logcat says this: http://pastebin.com/zMrrxePd

Strange thing: with one pad connected the pad gets id 3 on android and 0 on linux.

I don't know if it's a problem of Android or of the Shield ROM, but maybe the mapping could be useful to others and/or be added to SDL.