From 89ca9b51ad511bb7b4293e405e0842306c5403c4 Mon Sep 17 00:00:00 2001 From: Jordan Woyak Date: Wed, 22 Jul 2020 16:54:17 -0500 Subject: [PATCH] Bluetooth/WiimoteDevice: Remove some silly comments. --- .../Core/IOS/USB/Bluetooth/WiimoteDevice.cpp | 78 ------------------- .../Core/IOS/USB/Bluetooth/WiimoteDevice.h | 3 - 2 files changed, 81 deletions(-) diff --git a/Source/Core/Core/IOS/USB/Bluetooth/WiimoteDevice.cpp b/Source/Core/Core/IOS/USB/Bluetooth/WiimoteDevice.cpp index 4cdc16a3b2..9c7516f8bf 100644 --- a/Source/Core/Core/IOS/USB/Bluetooth/WiimoteDevice.cpp +++ b/Source/Core/Core/IOS/USB/Bluetooth/WiimoteDevice.cpp @@ -116,18 +116,6 @@ void WiimoteDevice::DoState(PointerWrap& p) p.Do(m_channel); } - -// -// -// -// -// --- Simple and ugly state machine -// -// -// -// -// - bool WiimoteDevice::LinkChannel() { if (m_connection_state != ConnectionState::Linking) @@ -186,16 +174,6 @@ bool WiimoteDevice::LinkChannel() return false; } -// -// -// -// -// --- Events -// -// -// -// -// void WiimoteDevice::Activate(bool ready) { if (ready && (m_connection_state == ConnectionState::Inactive)) @@ -242,21 +220,9 @@ void WiimoteDevice::ResetChannels() m_hid_interrupt_channel = {}; } -// -// -// -// -// --- Input parsing -// -// -// -// -// - // This function receives L2CAP commands from the CPU void WiimoteDevice::ExecuteL2capCmd(u8* ptr, u32 size) { - // parse the command l2cap_hdr_t* header = (l2cap_hdr_t*)ptr; u8* data = ptr + sizeof(l2cap_hdr_t); const u32 data_size = size - sizeof(l2cap_hdr_t); @@ -365,17 +331,6 @@ void WiimoteDevice::SignalChannel(u8* data, u32 size) } } -// -// -// -// -// --- Receive Commands from CPU -// -// -// -// -// - void WiimoteDevice::ReceiveConnectionReq(u8 ident, u8* data, u32 size) { l2cap_con_req_cp* command_connection_req = (l2cap_con_req_cp*)data; @@ -543,17 +498,6 @@ void WiimoteDevice::ReceiveDisconnectionReq(u8 ident, u8* data, u32 size) SendCommandToACL(ident, L2CAP_DISCONNECT_RSP, sizeof(l2cap_discon_req_cp), (u8*)&rsp); } -// -// -// -// -// --- Send Commands To CPU -// -// -// -// -// - // We assume Wiimote is always connected void WiimoteDevice::SendConnectionRequest(u16 scid, u16 psm) { @@ -643,17 +587,6 @@ void WiimoteDevice::SendConfigurationRequest(u16 scid, u16 mtu, u16 flush_time_o SendCommandToACL(L2CAP_CONFIG_REQ, L2CAP_CONFIG_REQ, offset, buffer); } -// -// -// -// -// --- SDP -// -// -// -// -// - #define SDP_UINT8 0x08 #define SDP_UINT16 0x09 #define SDP_UINT32 0x0A @@ -849,17 +782,6 @@ void WiimoteDevice::HandleSDP(u16 cid, u8* data, u32 size) } } -// -// -// -// -// --- Data Send Functions -// -// -// -// -// - void WiimoteDevice::SendCommandToACL(u8 ident, u8 code, u8 command_length, u8* command_data) { u8 data_frame[1024]; diff --git a/Source/Core/Core/IOS/USB/Bluetooth/WiimoteDevice.h b/Source/Core/Core/IOS/USB/Bluetooth/WiimoteDevice.h index c6cadf0cf7..e5d4509116 100644 --- a/Source/Core/Core/IOS/USB/Bluetooth/WiimoteDevice.h +++ b/Source/Core/Core/IOS/USB/Bluetooth/WiimoteDevice.h @@ -27,9 +27,6 @@ public: void DoState(PointerWrap& p); - // ugly Host handling.... - // we really have to clean all this code - bool IsConnected() const { return m_connection_state == ConnectionState::Complete; } bool IsInactive() const { return m_connection_state == ConnectionState::Inactive; } bool LinkChannel();