aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--melonDS.cbp2
-rw-r--r--src/DSi_NWifi.cpp49
-rw-r--r--src/DSi_NWifi.h39
-rw-r--r--src/DSi_SD.cpp5
4 files changed, 94 insertions, 1 deletions
diff --git a/melonDS.cbp b/melonDS.cbp
index 2346093..2fd6ed0 100644
--- a/melonDS.cbp
+++ b/melonDS.cbp
@@ -110,6 +110,8 @@
<Unit filename="src/DSi_I2C.h" />
<Unit filename="src/DSi_NDMA.cpp" />
<Unit filename="src/DSi_NDMA.h" />
+ <Unit filename="src/DSi_NWifi.cpp" />
+ <Unit filename="src/DSi_NWifi.h" />
<Unit filename="src/DSi_SD.cpp" />
<Unit filename="src/DSi_SD.h" />
<Unit filename="src/FIFO.h" />
diff --git a/src/DSi_NWifi.cpp b/src/DSi_NWifi.cpp
new file mode 100644
index 0000000..4e5d26d
--- /dev/null
+++ b/src/DSi_NWifi.cpp
@@ -0,0 +1,49 @@
+/*
+ Copyright 2016-2019 Arisotura
+
+ This file is part of melonDS.
+
+ melonDS is free software: you can redistribute it and/or modify it under
+ the terms of the GNU General Public License as published by the Free
+ Software Foundation, either version 3 of the License, or (at your option)
+ any later version.
+
+ melonDS is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License along
+ with melonDS. If not, see http://www.gnu.org/licenses/.
+*/
+
+#include <string.h>
+#include <stdio.h>
+#include "DSi.h"
+#include "DSi_NWifi.h"
+
+
+DSi_NWifi::DSi_NWifi(DSi_SDHost* host) : DSi_SDDevice(host)
+{
+ //
+}
+
+DSi_NWifi::~DSi_NWifi()
+{
+ //
+}
+
+
+void DSi_NWifi::SendCMD(u8 cmd, u32 param)
+{
+ printf("NWIFI: unknown CMD %d %08X\n", cmd, param);
+}
+
+void DSi_NWifi::SendACMD(u8 cmd, u32 param)
+{
+ printf("NWIFI: unknown ACMD %d %08X\n", cmd, param);
+}
+
+void DSi_NWifi::ContinueTransfer()
+{
+ //
+}
diff --git a/src/DSi_NWifi.h b/src/DSi_NWifi.h
new file mode 100644
index 0000000..34c3dd4
--- /dev/null
+++ b/src/DSi_NWifi.h
@@ -0,0 +1,39 @@
+/*
+ Copyright 2016-2019 Arisotura
+
+ This file is part of melonDS.
+
+ melonDS is free software: you can redistribute it and/or modify it under
+ the terms of the GNU General Public License as published by the Free
+ Software Foundation, either version 3 of the License, or (at your option)
+ any later version.
+
+ melonDS is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License along
+ with melonDS. If not, see http://www.gnu.org/licenses/.
+*/
+
+#ifndef DSI_NWIFI_H
+#define DSI_NWIFI_H
+
+#include "DSi_SD.h"
+
+class DSi_NWifi : public DSi_SDDevice
+{
+public:
+ DSi_NWifi(DSi_SDHost* host);
+ ~DSi_NWifi();
+
+ void SendCMD(u8 cmd, u32 param);
+ void SendACMD(u8 cmd, u32 param);
+
+ void ContinueTransfer();
+
+private:
+ //
+};
+
+#endif // DSI_NWIFI_H
diff --git a/src/DSi_SD.cpp b/src/DSi_SD.cpp
index 93431b5..6e73df5 100644
--- a/src/DSi_SD.cpp
+++ b/src/DSi_SD.cpp
@@ -20,6 +20,7 @@
#include <string.h>
#include "DSi.h"
#include "DSi_SD.h"
+#include "DSi_NWifi.h"
#include "Platform.h"
@@ -94,7 +95,9 @@ void DSi_SDHost::Reset()
}
else
{
- // TODO: SDIO (wifi)
+ DSi_NWifi* nwifi = new DSi_NWifi(this);
+
+ Ports[0] = nwifi;
}
}