• Login
  • Register
  • Dolphin Forums
  • Home
  • FAQ
  • Download
  • Wiki
  • Code


Dolphin, the GameCube and Wii emulator - Forums › Dolphin Emulator Discussion and Support › Android v
« Previous 1 ... 44 45 46 47 48 ... 128 Next »

Gamepad doesn't work on ChromeOS [includes fix]
View New Posts | View Today's Posts

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Thread Modes
Gamepad doesn't work on ChromeOS [includes fix]
03-30-2019, 12:48 PM
#1
ExceptionStock
Unregistered
 
Hello. When running on ChromeOS through Android subsystem the GamePad doesn't work. The issue comes from the fact that getDescriptor on ChromeOS returns "" for gamepad which is actually within the specs as the speconly guarantees the stability of ID, and "" is a valid ID. Then in Source/Android/jni/ButtonManager.cpp we have lines like:
sscanf(value.c_str(), "Device '%127[^\']'-Axis %d%c", dev, &bindnum, &modifier);
Unfortunately %127[^\'] doesn't accept empty string, so you need something like:
if (value.find(""Device ''") == 0) {
dev[0] = '\0';
sscanf(value.c_str(), "Device ''-Axis %d%c", &bindnum, &modifier);
} else {
sscanf(value.c_str(), "Device '%127[^\']'-Axis %d%c", dev, &bindnum, &modifier);
}
This needs to be modified in 4 places in Source/Android/jni/ButtonManager.cpp: 2 time with -Button and 2 times wit -Axis.
With this changes gamepad and Dolphin work perfectly on ChromeOS. Could somebody please fix this? I can't for some contract reasons
Reply
« Next Oldest | Next Newest »


Messages In This Thread
Gamepad doesn't work on ChromeOS [includes fix] - ExceptionStock - 03-30-2019, 12:48 PM
RE: Gamepad doesn't work on ChromeOS [includes fix] - Billiard26 - 04-03-2019, 08:48 AM
RE: Gamepad doesn't work on ChromeOS [includes fix] - ExceptionStock - 04-06-2019, 06:57 PM
RE: Gamepad doesn't work on ChromeOS [includes fix] - LazerTag - 04-24-2019, 08:08 AM

  • View a Printable Version
  • Subscribe to this thread
Forum Jump:


Users browsing this thread: 2 Guest(s)



Powered By MyBB | Theme by Fragma

Linear Mode
Threaded Mode