diff options
author | Arisotura <thetotalworm@gmail.com> | 2019-07-24 18:48:52 +0200 |
---|---|---|
committer | Arisotura <thetotalworm@gmail.com> | 2019-07-24 18:48:52 +0200 |
commit | 06716794a1d69512312e1dc251b9762d27b15c8d (patch) | |
tree | 5904121abd1512b08c616b67694e1a21aec2db8d /src/DSi_NWifi.h | |
parent | c5e14074c3b999d09b8a8612cfa7f011423e83ab (diff) |
lots of things. attempting to make wifi init work. not there yet.
Diffstat (limited to 'src/DSi_NWifi.h')
-rw-r--r-- | src/DSi_NWifi.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/src/DSi_NWifi.h b/src/DSi_NWifi.h index 5d61951..4ec010e 100644 --- a/src/DSi_NWifi.h +++ b/src/DSi_NWifi.h @@ -20,6 +20,7 @@ #define DSI_NWIFI_H #include "DSi_SD.h" +#include "FIFO.h" class DSi_NWifi : public DSi_SDDevice { @@ -48,6 +49,32 @@ private: void ReadBlock(); void WriteBlock(); + + void BMI_Command(); + + void WindowRead(); + void WindowWrite(); + + u32 MB_Read32(int n) + { + u32 ret = Mailbox[n]->Read(); + ret |= (Mailbox[n]->Read() << 8); + ret |= (Mailbox[n]->Read() << 16); + ret |= (Mailbox[n]->Read() << 24); + return ret; + } + + void MB_Write32(int n, u32 val) + { + Mailbox[n]->Write(val & 0xFF); val >>= 8; + Mailbox[n]->Write(val & 0xFF); val >>= 8; + Mailbox[n]->Write(val & 0xFF); val >>= 8; + Mailbox[n]->Write(val & 0xFF); + } + + FIFO<u8>* Mailbox[8]; + + u32 WindowData, WindowReadAddr, WindowWriteAddr; }; #endif // DSI_NWIFI_H |