#include <nnsys/mcs.h>
BOOL NNS_McsOpen(NNSMcsDeviceCaps* pCaps);
pCaps | Pointer to the structure that stores information regarding the opened device |
TRUE if the device was opened successfully. Returns FALSE if it failed.
Opens a device and stores that device's information in the variable specified by pCaps
.
The NNSMcsDeviceCaps
structure is defined as follows:
typedef struct NNSMcsDeviceCaps NNSMcsDeviceCaps;
struct NNSMcsDeviceCaps
{
u32 deviceID;
u32 maskResource;
};
The contents of each member is shown below:
deviceID | Device ID |
maskResource | Resource information necessary for operating the device. For details, see the following. |
The maskResource
member is a combination of following values:
NITROMASK_RESOURCE_POLL | Call the function NNS_McsPollingIdle repeatedly within the main loop. |
NITROMASK_RESOURCE_VBLANK | Call the function NNS_McsVBlankInterrupt in every frame. |
NITROMASK_RESOURCE_CARTRIDGE | Call the function NNS_McsCartridgeInterrupt when the cartridge interrupt is generated. |
If more than one connected device exists, the discovered devices are opened in the following order:
NNS_McsClose, NNS_McsReadStream, NNS_McsWriteStream, NNS_McsPollingIdle, NNS_McsVBlankInterrupt, NNS_McsCartridgeInterrupt
2005/01/24 Added an explanation about the NNSMcsDeviceCaps
structure. Deleted the description regarding IS-CGB-EMULATOR.
2004/06/01 Initial version.
CONFIDENTIAL