mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2025-07-21 18:05:46 +00:00
hid_core: Move hid to it's own subproject
This commit is contained in:
parent
8da33ba38a
commit
146975c880
141 changed files with 479 additions and 436 deletions
50
src/hid_core/hidbus/stubbed.cpp
Normal file
50
src/hid_core/hidbus/stubbed.cpp
Normal file
|
@ -0,0 +1,50 @@
|
|||
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
|
||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
#include "hid_core/frontend/emulated_controller.h"
|
||||
#include "hid_core/hid_core.h"
|
||||
#include "hid_core/hidbus/stubbed.h"
|
||||
|
||||
namespace Service::HID {
|
||||
constexpr u8 DEVICE_ID = 0xFF;
|
||||
|
||||
HidbusStubbed::HidbusStubbed(Core::System& system_, KernelHelpers::ServiceContext& service_context_)
|
||||
: HidbusBase(system_, service_context_) {}
|
||||
HidbusStubbed::~HidbusStubbed() = default;
|
||||
|
||||
void HidbusStubbed::OnInit() {
|
||||
return;
|
||||
}
|
||||
|
||||
void HidbusStubbed::OnRelease() {
|
||||
return;
|
||||
};
|
||||
|
||||
void HidbusStubbed::OnUpdate() {
|
||||
if (!is_activated) {
|
||||
return;
|
||||
}
|
||||
if (!device_enabled) {
|
||||
return;
|
||||
}
|
||||
if (!polling_mode_enabled || transfer_memory == 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
LOG_ERROR(Service_HID, "Polling mode not supported {}", polling_mode);
|
||||
}
|
||||
|
||||
u8 HidbusStubbed::GetDeviceId() const {
|
||||
return DEVICE_ID;
|
||||
}
|
||||
|
||||
std::vector<u8> HidbusStubbed::GetReply() const {
|
||||
return {};
|
||||
}
|
||||
|
||||
bool HidbusStubbed::SetCommand(std::span<const u8> data) {
|
||||
LOG_ERROR(Service_HID, "Command not implemented");
|
||||
return false;
|
||||
}
|
||||
|
||||
} // namespace Service::HID
|
Loading…
Add table
Add a link
Reference in a new issue