suyu/src/hid_core/hidbus/starlink.cpp

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

51 lines
1.1 KiB
C++
Raw Normal View History

// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
// SPDX-License-Identifier: GPL-2.0-or-later
2021-05-02 23:41:03 +00:00
#include "hid_core/frontend/emulated_controller.h"
#include "hid_core/hid_core.h"
#include "hid_core/hidbus/starlink.h"
2021-05-02 23:41:03 +00:00
namespace Service::HID {
constexpr u8 DEVICE_ID = 0x28;
Starlink::Starlink(Core::System& system_, KernelHelpers::ServiceContext& service_context_)
: HidbusBase(system_, service_context_) {}
2021-05-02 23:41:03 +00:00
Starlink::~Starlink() = default;
void Starlink::OnInit() {
return;
}
void Starlink::OnRelease() {
return;
};
void Starlink::OnUpdate() {
if (!is_activated) {
return;
}
if (!device_enabled) {
return;
}
if (!polling_mode_enabled || transfer_memory == 0) {
2021-05-02 23:41:03 +00:00
return;
}
LOG_ERROR(Service_HID, "Polling mode not supported {}", polling_mode);
}
u8 Starlink::GetDeviceId() const {
return DEVICE_ID;
}
std::vector<u8> Starlink::GetReply() const {
return {};
}
bool Starlink::SetCommand(std::span<const u8> data) {
2021-05-02 23:41:03 +00:00
LOG_ERROR(Service_HID, "Command not implemented");
return false;
}
} // namespace Service::HID