nds/bios.h

Nintendo DS Bios functions [詳細]

#include <nds/jtypes.h>

データ構造

struct  DecompressionStream
struct  UnpackStruct

マクロ定義

#define COPY_MODE_HWORD   (0)
#define COPY_MODE_WORD   (1<<26)
#define COPY_MODE_COPY   (0)
#define COPY_MODE_FILL   (1<<24)

型定義

typedef struct DecompressionStream TDecompressionStream
typedef struct UnpackStruct TUnpackStruct
typedef struct UnpackStructPUnpackStruct

関数

void swiSoftReset (void)
 reset the DS.
void swiDelay (uint32 duration)
 delay
void swiIntrWait (int waitForSet, uint32 flags)
 wait for interrupt(s) to occur
void swiWaitForVBlank (void)
 Wait for vblank interrupt
int swiDivide (int numerator, int divisor)
int swiRemainder (int numerator, int divisor)
void swiDivMod (int numerator, int divisor, int *result, int *remainder)
void swiCopy (const void *source, void *dest, int flags)
void swiFastCopy (const void *source, void *dest, int flags)
int swiSqrt (int value)
uint16 swiCRC16 (uint16 crc, void *data, uint32 size)
int swiIsDebugger (void)
void swiUnpackBits (uint8 *source, uint32 *destination, PUnpackStruct params)
void swiDecompressLZSSWram (void *source, void *destination)
int swiDecompressLZSSVram (void *source, void *destination, uint32 toGetSize, TDecompressionStream *stream)
int swiDecompressHuffman (void *source, void *destination, uint32 toGetSize, TDecompressionStream *stream)
void swiDecompressRLEWram (void *source, void *destination)
int swiDecompressRLEVram (void *source, void *destination, uint32 toGetSize, TDecompressionStream *stream)
void swiWaitForIRQ (void)
 wait for any interrupt
void swiSetHaltCR (uint32 data)
void swiDecodeDelta8 (void *source, void *destination)
void swiDecodeDelta16 (void *source, void *destination)


説明

Nintendo DS Bios functions


マクロ定義

#define COPY_MODE_COPY   (0)

#define COPY_MODE_FILL   (1<<24)

#define COPY_MODE_HWORD   (0)

#define COPY_MODE_WORD   (1<<26)


型定義

typedef struct UnpackStruct * PUnpackStruct

typedef struct DecompressionStream TDecompressionStream

typedef struct UnpackStruct TUnpackStruct


関数

swiCopy ( const void *  source,
void *  dest,
int  flags 
)

引数:
source pointer to transfer source
dest dest = pointer to transfer destination
flags copy mode and size flags(26) = transfer width (0: halfwords, 1: words) flags(24) = transfer mode (0: copy, 1: fill) flags(20..0) = transfer count (always in words)

uint16 swiCRC16 ( uint16  crc,
void *  data,
uint32  size 
)

void swiDecodeDelta16 ( void *  source,
void *  destination 
)

void swiDecodeDelta8 ( void *  source,
void *  destination 
)

int swiDecompressHuffman ( void *  source,
void *  destination,
uint32  toGetSize,
TDecompressionStream stream 
)

int swiDecompressLZSSVram ( void *  source,
void *  destination,
uint32  toGetSize,
TDecompressionStream stream 
)

void swiDecompressLZSSWram ( void *  source,
void *  destination 
)

int swiDecompressRLEVram ( void *  source,
void *  destination,
uint32  toGetSize,
TDecompressionStream stream 
)

void swiDecompressRLEWram ( void *  source,
void *  destination 
)

swiDelay ( uint32  duration  ) 

delay

Delays for for a period X + Y*duration where X is the swi overhead and Y is a cycle of

     loop:
       sub r0, #1
       bgt loop
of thumb fetches in BIOS memory
引数:
duration length of delay
覚え書き:
Duration should be 1 or more, a duration of 0 is a huge delay

int swiDivide ( int  numerator,
int  divisor 
)

引数:
numerator signed integer to divide
divisor signed integer to divide by
戻り値:
numerator / divisor

void swiDivMod ( int  numerator,
int  divisor,
int *  result,
int *  remainder 
)

引数:
numerator signed integer to divide
divisor signed integer to divide by
result pointer to integer set to numerator / divisor
remainder pointer to integer set to numerator % divisor

swiFastCopy ( const void *  source,
void *  dest,
int  flags 
)

引数:
source pointer to transfer source
dest dest = pointer to transfer destination
flags copy mode and size flags(24) = transfer mode (0: copy, 1: fill) flags(20..0) = transfer count (in words)
覚え書き:
Transfers more quickly than swiCopy, but has higher interrupt latency

swiIntrWait ( int  waitForSet,
uint32  flags 
)

wait for interrupt(s) to occur

引数:
waitForSet 0: Return if the interrupt has already occured 1: Wait until the interrupt has been set since the call
flags interrupt mask to wait for

int swiIsDebugger ( void   ) 

int swiRemainder ( int  numerator,
int  divisor 
)

引数:
numerator signed integer to divide
divisor signed integer to divide by
戻り値:
numerator % divisor

void swiSetHaltCR ( uint32  data  ) 

swiSoftReset ( void   ) 

reset the DS.

int swiSqrt ( int  value  ) 

void swiUnpackBits ( uint8 source,
uint32 destination,
PUnpackStruct  params 
)

swiWaitForIRQ ( void   ) 

wait for any interrupt

覚え書き:
ARM9 exclusive

swiWaitForVBlank ( void   ) 

Wait for vblank interrupt

Waits for a vertical blank interrupt

覚え書き:
Identical to calling swiIntrWait(1, 1)


libnds(ARM9)に対してTue Jan 22 15:48:24 2008に生成されました。  doxygen 1.5.4