From 1fc2021e29935b1b4930203ba7ec1a2b0380d9cb Mon Sep 17 00:00:00 2001 From: red031000 Date: Thu, 14 Jan 2021 21:28:45 +0000 Subject: decompile CTRDG_backup --- arm9/lib/include/MI_exMemory.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'arm9/lib/include/MI_exMemory.h') diff --git a/arm9/lib/include/MI_exMemory.h b/arm9/lib/include/MI_exMemory.h index df46b008..aa90a73c 100644 --- a/arm9/lib/include/MI_exMemory.h +++ b/arm9/lib/include/MI_exMemory.h @@ -22,6 +22,14 @@ typedef enum MI_CTRDG_ROMCYCLE2_4 = 1 } MICartridgeRomCycle2nd; +typedef enum +{ + MI_CTRDG_RAMCYCLE_10 = 0, + MI_CTRDG_RAMCYCLE_8 = 1, + MI_CTRDG_RAMCYCLE_6 = 2, + MI_CTRDG_RAMCYCLE_18 = 3 +} MICartridgeRamCycle; + static inline void MIi_SetCardProcessor(MIProcessor proc) { reg_MI_EXMEMCNT = @@ -54,4 +62,14 @@ static inline void MI_SetCartridgeRomCycle2nd(MICartridgeRomCycle2nd c2) reg_MI_EXMEMCNT = (u16)((reg_MI_EXMEMCNT & ~0x10) | (c2 << 4)); } +static inline void MI_SetCartridgeRamCycle(MICartridgeRamCycle c) +{ + reg_MI_EXMEMCNT = (u16)((reg_MI_EXMEMCNT & ~3) | (c << 0)); +} + +static inline MICartridgeRamCycle MI_GetCartridgeRamCycle(void) +{ + return (MICartridgeRamCycle)((reg_MI_EXMEMCNT & 3) >> 0); +} + #endif //POKEDIAMOND_MI_EXMEMORY_H -- cgit v1.2.3