Cpasjuste / pemu

GNU General Public License v3.0
443 stars 50 forks source link

[Switch] Single joycons handling not working #160

Closed R-YaTian closed 2 years ago

R-YaTian commented 2 years ago

I build pfbneo c62f785 myself, and single joycons mode not working...

Cpasjuste commented 2 years ago

Hi,

I'm waiting the "go" from the devkitpro maintener to merge latest changes : https://github.com/devkitPro/SDL/tree/switch-sdl2-2.0.14-dev

R-YaTian commented 2 years ago

Hi,

I'm waiting the "go" from the devkitpro maintener to merge latest changes : https://github.com/devkitPro/SDL/tree/switch-sdl2-2.0.14-dev

Hello! Thanks for you quick reply. I try to rebuild it with "SDL2_2.0.14-dev". But I got this error: "skipping incompatible /opt/devkitpro/portlibs/switch/lib/libSDL2.a when searching for -lSDL2"

Cpasjuste commented 2 years ago

Are you using configure scripts? If so then I may have to fix that. Locally I'm using cmake to build it, so the cmake way should work for you

R-YaTian commented 2 years ago

Are you using configure scripts? If so then I may have to fix that. Locally I'm using cmake to build it, so the cmake way should work for you

Maybe I should use cmake with "-DNINTENDO_SWITCH=ON", idk...hmmm

Cpasjuste commented 2 years ago

This flag should be automatically set when you use the switch cmake toolchain file (-DCMAKE_TOOLCHAIN_FILE=/opt/devkitpro/...) (Sorry I'm on phone it's hard to fully help :) )

Also, single joycons is handled here now if you have some suggested changes: https://github.com/devkitPro/SDL/blob/switch-sdl2-2.0.14-dev/src/joystick/switch/SDL_sysjoystick.c

R-YaTian commented 2 years ago

This flag should be automatically set when you use the switch cmake toolchain file (-DCMAKE_TOOLCHAIN_FILE=/opt/devkitpro/...) (Sorry I'm on phone it's hard to fully help :) )

Also, single joycons is handled here now if you have some suggested changes: https://github.com/devkitPro/SDL/blob/switch-sdl2-2.0.14-dev/src/joystick/switch/SDL_sysjoystick.c

OK. I succeed in building "SDL2_2.0.14-dev". Thanks for your help! I will test new sdl single joycons later on.

R-YaTian commented 2 years ago

This flag should be automatically set when you use the switch cmake toolchain file (-DCMAKE_TOOLCHAIN_FILE=/opt/devkitpro/...) (Sorry I'm on phone it's hard to fully help :) )

Also, single joycons is handled here now if you have some suggested changes: https://github.com/devkitPro/SDL/blob/switch-sdl2-2.0.14-dev/src/joystick/switch/SDL_sysjoystick.c

Single joycons mode works fine now, but I think we should set NpadJoyHoldType_Horizontal for it. I opened a new PR for that.