CARDCreateAsync

C Specification

#include <revolution/card.h>

#define CARD_FILENAME_MAX   32

typedef void (*CARDCallback)( s32 chan, s32 result );
s32 CARDCreateAsync(s32 chan, const char* fileName, u32 size, CARDFileInfo* fileInfo,
CARDCallback callback );

Arguments

chan EXI channel number.
fileName Pointer to the file name to create. The maximum number of bytes in a file name is given by CARD_FILENAME_MAX.
size Size of the file to create. The size must be multiples of the card sector size returned by the CARDGetSectorSize function.
fileInfo Pointer to file info to use.
callback Callback function to notify about the result.

Return Values

One of the following codes:

CARD_RESULT_FATAL_ERROR
CARD_RESULT_NOCARD
CARD_RESULT_BUSY
CARD_RESULT_EXIST
CARD_RESULT_NOENT
CARD_RESULT_INSSPACE
CARD_RESULT_NAMETOOLONG
CARD_RESULT_IOERROR
CARD_RESULT_READY

Description

Asynchronously creates a file. The Memory Card must be mounted with the CARDMount[Async] function before creating a file.

Note: This function is provided for debugging. Do not use in programs.

See Also

CARDMount[Async], CARDGetSectorSize

Revision History

03/01/2006 Initial version.