summaryrefslogtreecommitdiff
path: root/include/dolphin/db/db.h
blob: 5727c9e2b38ac49c1a3136c0bab56456185777dd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#ifndef DB_H
#define DB_H

#include "dolphin/amcstubs/AmcExi2Stubs.h"

#ifdef __cplusplus
extern "C" {
#endif

#define OS_DBINTERFACE_ADDR 0x00000040

typedef struct DBInterface {
    /* 0x0 */ u32 bPresent;
    /* 0x4 */ u32 exceptionMask;
    /* 0x8 */ void (*ExceptionDestination)(void);
    /* 0xC */ void* exceptionReturn;
} DBInterface;

extern DBInterface* __DBInterface;

void DBInit(void);
void __DBExceptionDestinationAux(void);
void __DBExceptionDestination(void);
BOOL __DBIsExceptionMarked(__OSException);
void DBPrintf(char* format, ...);
void DBInitComm(vu8**, AmcEXICallback); // possibly not this type, but some similar construction
void DBInitInterrupts();
u32 DBQueryData();
BOOL DBRead(void*, u32);
BOOL DBWrite(const void*, u32);
void DBOpen();
void DBClose();

#ifdef __cplusplus
}
#endif

#endif /* DB_H */