summaryrefslogtreecommitdiff
path: root/include/dolphin/GBAPriv.h
diff options
context:
space:
mode:
authormrb0nk500 <b0nk@b0nk.xyz>2023-02-01 18:45:02 -0400
committermrb0nk500 <b0nk@b0nk.xyz>2023-02-01 18:50:25 -0400
commit9fa0a7f1da1b70bee995f53c6c96c43189018772 (patch)
tree114548896790eaff23cdca84a025281de86bbb51 /include/dolphin/GBAPriv.h
parent2ba3289286bbfcf9fcc13fd135d976058d8b6c2e (diff)
global: Import Dolphin SDK
This version comes from the Metroid Prime decompilation project. https://github.com/PrimeDecomp/prime
Diffstat (limited to 'include/dolphin/GBAPriv.h')
-rw-r--r--include/dolphin/GBAPriv.h62
1 files changed, 62 insertions, 0 deletions
diff --git a/include/dolphin/GBAPriv.h b/include/dolphin/GBAPriv.h
new file mode 100644
index 0000000..43d23e1
--- /dev/null
+++ b/include/dolphin/GBAPriv.h
@@ -0,0 +1,62 @@
+#ifndef _DOLPHIN_GBAPRIV
+#define _DOLPHIN_GBAPRIV
+
+#include "types.h"
+
+#include <dolphin/gba.h>
+#include <dolphin/os.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+typedef void (*GBATransferCallback)(s32 chan);
+
+typedef struct GBASecParams {
+ u8 data[0x40];
+} GBASecParams;
+
+typedef struct GBA {
+ u8 command;
+ u8 src[4];
+ u8 dst[4];
+ u8 _09;
+ s8 _0a;
+ s8 _0b;
+ s32 _0c;
+ s32 _10;
+ u8* status;
+ u8* buffer;
+ GBACallback callback;
+ s32 result;
+ OSThreadQueue thread_queue;
+ OSTime delay;
+ GBATransferCallback _38;
+ s32 _3c;
+ s32 palette_color;
+ s32 palette_speed;
+ u8* program;
+ s32 program_length;
+ s32 jboot_status;
+ GBACallback jboot_callback;
+ char data2[0x74u - 0x58u];
+ u8* challenge_cipher;
+ char data3[0xf8 - 0x78u];
+ GBASecParams* param;
+ char data4[0x100u - 0xfcu];
+} GBA;
+
+extern GBA __GBA[4];
+extern BOOL __GBAReset;
+
+void __GBAHandler(s32 chan, u32 sr, OSContext* context);
+void __GBASyncCallback(s32 chan, s32 ret);
+s32 __GBASync(s32 chan);
+OSTime __GBASetDelay(s32 chan, OSTime delay);
+s32 __GBATransfer(s32 chan, s32 w1, s32 w2, GBATransferCallback callback);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif // _DOLPHIN_GBAPRIV