(Android) Add FC30 Gamepad to autodetection list (untested)

This commit is contained in:
twinaphex 2013-09-19 02:13:34 +02:00
parent a36f7a6b9a
commit 737520143f
3 changed files with 23 additions and 0 deletions

View File

@ -1514,6 +1514,26 @@ static void android_input_set_keybinds(void *data, unsigned device,
keycode_lut[AKEYCODE_BUTTON_START] |= ((RETRO_DEVICE_ID_JOYPAD_START+1) << shift);
keycode_lut[AKEYCODE_BACK] |= ((RETRO_DEVICE_ID_JOYPAD_SELECT+1) << shift);
break;
case DEVICE_FC30_GAMEPAD:
g_settings.input.device[port] = device;
strlcpy(g_settings.input.device_names[port], "FC30 Gamepad",
sizeof(g_settings.input.device_names[port]));
g_settings.input.dpad_emulation[port] = ANALOG_DPAD_NONE;
keycode_lut[AKEYCODE_DPAD_UP] |= ((RETRO_DEVICE_ID_JOYPAD_UP+1) << shift);
keycode_lut[AKEYCODE_DPAD_DOWN] |= ((RETRO_DEVICE_ID_JOYPAD_DOWN+1) << shift);
keycode_lut[AKEYCODE_DPAD_LEFT] |= ((RETRO_DEVICE_ID_JOYPAD_LEFT+1) << shift);
keycode_lut[AKEYCODE_DPAD_RIGHT]|= ((RETRO_DEVICE_ID_JOYPAD_RIGHT+1) << shift);
keycode_lut[AKEYCODE_BUTTON_A] |= ((RETRO_DEVICE_ID_JOYPAD_A+1) << shift);
keycode_lut[AKEYCODE_BUTTON_B] |= ((RETRO_DEVICE_ID_JOYPAD_B+1) << shift);
keycode_lut[AKEYCODE_BUTTON_X] |= ((RETRO_DEVICE_ID_JOYPAD_X+1) << shift);
keycode_lut[AKEYCODE_BUTTON_Y] |= ((RETRO_DEVICE_ID_JOYPAD_Y+1) << shift);
keycode_lut[AKEYCODE_BUTTON_L1] |= ((RETRO_DEVICE_ID_JOYPAD_L+1) << shift);
keycode_lut[AKEYCODE_BUTTON_R1] |= ((RETRO_DEVICE_ID_JOYPAD_R+1) << shift);
keycode_lut[AKEYCODE_BUTTON_C] |= ((RETRO_DEVICE_ID_JOYPAD_SELECT+1) << shift);
keycode_lut[AKEYCODE_BUTTON_START] |= ((RETRO_DEVICE_ID_JOYPAD_START+1) << shift);
break;
case DEVICE_CCPCREATIONS_WIIUSE_IME:
g_settings.input.device[port] = device;
strlcpy(g_settings.input.device_names[port], "ccpCreations WiiUse IME",

View File

@ -189,6 +189,8 @@ void input_autodetect_setup(void *data, char *msg, size_t sizeof_msg, unsigned p
device = DEVICE_USB_2_AXIS_8_BUTTON_GAMEPAD;
else if (strstr(name_buf, "BUFFALO BGC-FC801"))
device = DEVICE_BUFFALO_BGC_FC801;
else if (strstr(name_buf, "8Bitdo FC30"))
device = DEVICE_FC30_GAMEPAD;
else if (strstr(name_buf, "RetroUSB.com RetroPad"))
device = DEVICE_RETROUSB_RETROPAD;
else if (strstr(name_buf, "RetroUSB.com SNES RetroPort"))

View File

@ -273,6 +273,7 @@ enum input_devices
DEVICE_NVIDIA_SHIELD,
DEVICE_MUCH_IREADGO_I5,
DEVICE_WIKIPAD,
DEVICE_FC30_GAMEPAD,
#elif defined(GEKKO)
DEVICE_GAMECUBE = 0,
#ifdef HW_RVL