diff options
| author | 2022-12-22 01:07:46 -0600 | |
|---|---|---|
| committer | 2023-01-19 18:05:21 -0600 | |
| commit | 6d6b7bdbc327528d155f0422ef096846559844c0 (patch) | |
| tree | 6954aaa23abe6d725f8452afb1fd19a59e962800 /src/input_common/helpers/joycon_protocol/poller.cpp | |
| parent | input_common: Add dual joycon support (diff) | |
| download | yuzu-6d6b7bdbc327528d155f0422ef096846559844c0.tar.gz yuzu-6d6b7bdbc327528d155f0422ef096846559844c0.tar.xz yuzu-6d6b7bdbc327528d155f0422ef096846559844c0.zip | |
input_common: Implement joycon nfc
Diffstat (limited to 'src/input_common/helpers/joycon_protocol/poller.cpp')
| -rw-r--r-- | src/input_common/helpers/joycon_protocol/poller.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/input_common/helpers/joycon_protocol/poller.cpp b/src/input_common/helpers/joycon_protocol/poller.cpp index cb76e1e06..fd05d98f3 100644 --- a/src/input_common/helpers/joycon_protocol/poller.cpp +++ b/src/input_common/helpers/joycon_protocol/poller.cpp | |||
| @@ -74,6 +74,10 @@ void JoyconPoller::UpdateColor(const Color& color) { | |||
| 74 | callbacks.on_color_data(color); | 74 | callbacks.on_color_data(color); |
| 75 | } | 75 | } |
| 76 | 76 | ||
| 77 | void JoyconPoller::updateAmiibo(const std::vector<u8>& amiibo_data) { | ||
| 78 | callbacks.on_amiibo_data(amiibo_data); | ||
| 79 | } | ||
| 80 | |||
| 77 | void JoyconPoller::UpdateRing(s16 value, const RingStatus& ring_status) { | 81 | void JoyconPoller::UpdateRing(s16 value, const RingStatus& ring_status) { |
| 78 | float normalized_value = static_cast<float>(value - ring_status.default_value); | 82 | float normalized_value = static_cast<float>(value - ring_status.default_value); |
| 79 | if (normalized_value > 0) { | 83 | if (normalized_value > 0) { |