MCPcopy Create free account
hub / github.com/devkitPro/libctru / DSP_RecvDataIsReady

Function DSP_RecvDataIsReady

libctru/source/services/dsp.c:302–311  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

300}
301
302Result DSP_RecvDataIsReady(u16 regNo, bool* is_ready)
303{
304 Result ret = 0;
305 u32* cmdbuf = getThreadCommandBuffer();
306 cmdbuf[0] = IPC_MakeHeader(0x2,1,0);
307 cmdbuf[1] = regNo;
308 if (R_FAILED(ret = svcSendSyncRequest(dspHandle))) return ret;
309 *is_ready = cmdbuf[2] & 0xFF;
310 return cmdbuf[1];
311}
312
313// Writes data to the reg regNo
314// *(_WORD *)(8 * regNo + 0x1ED03024) = value

Callers 1

ndspFinalizeFunction · 0.85

Calls 2

getThreadCommandBufferFunction · 0.85
IPC_MakeHeaderFunction · 0.85

Tested by

no test coverage detected