diff options
Diffstat (limited to 'src/hid_core/hidbus/stubbed.h')
| -rw-r--r-- | src/hid_core/hidbus/stubbed.h | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/src/hid_core/hidbus/stubbed.h b/src/hid_core/hidbus/stubbed.h new file mode 100644 index 000000000..7a711cea0 --- /dev/null +++ b/src/hid_core/hidbus/stubbed.h | |||
| @@ -0,0 +1,37 @@ | |||
| 1 | // SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project | ||
| 2 | // SPDX-License-Identifier: GPL-2.0-or-later | ||
| 3 | |||
| 4 | #pragma once | ||
| 5 | |||
| 6 | #include "common/common_types.h" | ||
| 7 | #include "hid_core/hidbus/hidbus_base.h" | ||
| 8 | |||
| 9 | namespace Core::HID { | ||
| 10 | class EmulatedController; | ||
| 11 | } // namespace Core::HID | ||
| 12 | |||
| 13 | namespace Service::HID { | ||
| 14 | |||
| 15 | class HidbusStubbed final : public HidbusBase { | ||
| 16 | public: | ||
| 17 | explicit HidbusStubbed(Core::System& system_, KernelHelpers::ServiceContext& service_context_); | ||
| 18 | ~HidbusStubbed() override; | ||
| 19 | |||
| 20 | void OnInit() override; | ||
| 21 | |||
| 22 | void OnRelease() override; | ||
| 23 | |||
| 24 | // Updates ringcon transfer memory | ||
| 25 | void OnUpdate() override; | ||
| 26 | |||
| 27 | // Returns the device ID of the joycon | ||
| 28 | u8 GetDeviceId() const override; | ||
| 29 | |||
| 30 | // Assigns a command from data | ||
| 31 | bool SetCommand(std::span<const u8> data) override; | ||
| 32 | |||
| 33 | // Returns a reply from a command | ||
| 34 | std::vector<u8> GetReply() const override; | ||
| 35 | }; | ||
| 36 | |||
| 37 | } // namespace Service::HID | ||