diff --git a/CHANGES.md b/CHANGES.md index a1fa5e4865..ff6cb64f98 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,5 +1,8 @@ # 1.6.4 (future) +- ANDROID: Fire Stick & Fire TV remote overrides gamepad port 0 on button press and viceversa like SHIELD devices +- INPUT: input swap override flag (for remotes) is cleared correctly + # 1.6.3 - IOS: Fix GL regression - 32bit color format cores were no longer rendering - CHEEVOS: Add support for N64 cheevos and other small fixes. diff --git a/input/drivers/android_input.c b/input/drivers/android_input.c index 70f80f75b9..adf3f18404 100644 --- a/input/drivers/android_input.c +++ b/input/drivers/android_input.c @@ -1072,6 +1072,32 @@ static void handle_hotplug(android_input_t *android, } } + /* Amazon Fire TV & Fire stick */ + else if(strstr(device_model, "AFTB") || strstr(device_model, "AFTT") || + strstr(device_model, "AFTS") || strstr(device_model, "AFTM") || + strstr(device_model, "AFTRS")) + { + RARCH_LOG("Special Device Detected: %s\n", device_model); + { + /* always map remote to port #0 */ + if (strstr(device_name, "Amazon Fire TV Remote")) + { + android->pads_connected = 0; + *port = 0; + strlcpy(name_buf, device_name, sizeof(name_buf)); + } + /* remove the remote when a gamepad enters */ + else if(strstr(android->pad_states[0].name,"Amazon Fire TV Remote")) + { + android->pads_connected = 0; + *port = 0; + strlcpy(name_buf, device_name, sizeof(name_buf)); + } + else + strlcpy(name_buf, device_name, sizeof(name_buf)); + } + } + /* Other uncommon devices * These are mostly remote control type devices, bind them always to port 0 * And overwrite the binding whenever a controller button is pressed diff --git a/tasks/task_autodetect.c b/tasks/task_autodetect.c index e3da649000..b43bf8e87e 100644 --- a/tasks/task_autodetect.c +++ b/tasks/task_autodetect.c @@ -189,6 +189,8 @@ static void input_autoconfigure_joypad_add(config_file_t *conf, { if (config_get_bool(conf, "input_swap_override", &tmp)) input_autoconfigure_swap_override = tmp; + else + input_autoconfigure_swap_override = false; } if (!block_osd_spam)