DS Wi-Fi: Partially implement W_POWERFORCE
Vicki Pfau vi@endrift.com
Mon, 13 Mar 2017 12:55:15 -0700
1 files changed,
15 insertions(+),
0 deletions(-)
jump to
M
src/ds/wifi.c
→
src/ds/wifi.c
@@ -27,6 +27,20 @@ }
static void DSWifiWriteReg(struct DS* ds, uint32_t address, uint16_t value) { switch (address) { + case 0x040: + value &= 0x8001; + if (value & 0x8000) { + uint16_t state = ds->wifi.io[0x03C >> 1]; + if (value & 0x1) { + state |= 0x200; + state &= ~0x100; + } else { + mLOG(DS_WIFI, STUB, "Stub Wi-Fi I/O register write: %06X:%04X", address, value); + state &= ~0x200; + } + ds->wifi.io[0x03C >> 1] = state; + } + break; case 0x158: if (value & 0x1000) { DSWifiWriteBB(ds, value & 0xFF, ds->wifi.io[0x15A >> 1]);@@ -46,6 +60,7 @@ }
static uint16_t DSWifiReadReg(struct DS* ds, uint32_t address) { switch (address) { + case 0x040: case 0x15C: break; default: