2020-06-02 21:24:40 +00:00
|
|
|
#pragma once
|
|
|
|
#include "wiicontroller.hpp"
|
|
|
|
|
2020-07-11 11:43:21 +00:00
|
|
|
namespace ams::controller {
|
2020-06-02 21:24:40 +00:00
|
|
|
|
2020-06-09 20:39:30 +00:00
|
|
|
|
|
|
|
|
2020-06-02 21:24:40 +00:00
|
|
|
class WiimoteController : public WiiController {
|
|
|
|
|
|
|
|
public:
|
|
|
|
static constexpr const HardwareID hardwareIds[] = {
|
|
|
|
{0x057e, 0x0306}, // Official wiimote
|
|
|
|
};
|
|
|
|
|
2020-07-11 11:43:21 +00:00
|
|
|
WiimoteController(const bluetooth::Address *address);
|
2020-06-02 21:24:40 +00:00
|
|
|
|
2020-07-09 22:46:11 +00:00
|
|
|
Result initialize(void);
|
|
|
|
|
2020-07-11 11:43:21 +00:00
|
|
|
void convertReportFormat(const bluetooth::HidReport *inReport, bluetooth::HidReport *outReport);
|
2020-06-09 20:39:30 +00:00
|
|
|
|
2020-06-02 21:24:40 +00:00
|
|
|
private:
|
2020-07-11 21:19:56 +00:00
|
|
|
void handleInputReport0x20(const WiiReportData *src, SwitchReportData *dst);
|
2020-07-11 11:43:21 +00:00
|
|
|
void handleInputReport0x30(const WiiReportData *src, SwitchReportData *dst);
|
|
|
|
void handleInputReport0x31(const WiiReportData *src, SwitchReportData *dst);
|
2020-07-09 22:46:11 +00:00
|
|
|
|
2020-06-02 21:24:40 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|