aboutsummaryrefslogtreecommitdiff
path: root/src/core/hid/emulated_controller.cpp
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2022-02-19 00:57:47 -0700
committerGitHub <noreply@github.com>2022-02-19 00:57:47 -0700
commit298469526501b3bd576ff1ab53d089097506a2e7 (patch)
tree269412e42ab54fdef3132c77f173a098867aceb7 /src/core/hid/emulated_controller.cpp
parent83a84f1c2dce5a9f90404f2486da569e236f96fa (diff)
parentb57d61010f347e74875f0c8a1003b4f84fa7b062 (diff)
Merge pull request #7867 from german77/amiibo
nfp: Improve amiibo support
Diffstat (limited to 'src/core/hid/emulated_controller.cpp')
-rw-r--r--src/core/hid/emulated_controller.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/core/hid/emulated_controller.cpp b/src/core/hid/emulated_controller.cpp
index 2bee173b3..7e05666d6 100644
--- a/src/core/hid/emulated_controller.cpp
+++ b/src/core/hid/emulated_controller.cpp
@@ -885,6 +885,12 @@ bool EmulatedController::TestVibration(std::size_t device_index) {
return SetVibration(device_index, DEFAULT_VIBRATION_VALUE);
}
+bool EmulatedController::SetPollingMode(Common::Input::PollingMode polling_mode) {
+ LOG_INFO(Service_HID, "Set polling mode {}", polling_mode);
+ auto& output_device = output_devices[static_cast<std::size_t>(DeviceIndex::Right)];
+ return output_device->SetPollingMode(polling_mode) == Common::Input::PollingError::None;
+}
+
void EmulatedController::SetLedPattern() {
for (auto& device : output_devices) {
if (!device) {