From 2ff7320409d1f6340bed2ea37b7ceb3a49a57525 Mon Sep 17 00:00:00 2001 From: Anghelo Carvajal Date: Wed, 22 Sep 2021 22:50:35 -0300 Subject: `ovl_daytelop` OK (#277) * eeeee * nonequivalents * draw * Import data * Match Daytelop_LoadGraphics * draw kinda better * extract daytelops and gameover * SEGMENT_ROM macros * Use extracted symbols for daytelop * match Daytelop_Draw * Fix bss * draw cleanup * Daytelop_Update from non equivalent to non matching * Some renames and spec * Run formatter * enum * sfx * Use SEGMENT_ROM_START macros everywhere * more macros * run formatter * Add description * update variables.txt * Remove extra stuff in gbi.h * Would this fix it? * and again * whoops * Apply suggestions from code review Co-authored-by: Tharo <17233964+Thar0@users.noreply.github.com> * Tharo's suggestions * match Daytelop_Update * run formatter * fix merge issues Co-authored-by: Tharo <17233964+Thar0@users.noreply.github.com> --- src/boot_O2_g3/idle.c | 6 +++--- src/boot_O2_g3/z_std_dma.c | 3 +-- 2 files changed, 4 insertions(+), 5 deletions(-) (limited to 'src/boot_O2_g3') diff --git a/src/boot_O2_g3/idle.c b/src/boot_O2_g3/idle.c index 4d01b4c37..4be8a1094 100644 --- a/src/boot_O2_g3/idle.c +++ b/src/boot_O2_g3/idle.c @@ -58,15 +58,15 @@ void Idle_InitCodeAndMemory(void) { oldSize = sDmaMgrDmaBuffSize; sDmaMgrDmaBuffSize = 0; - DmaMgr_SendRequestImpl(&dmaReq, _codeSegmentStart, _codeSegmentRomStart, _codeSegmentRomEnd - _codeSegmentRomStart, - 0, &queue, 0); + DmaMgr_SendRequestImpl(&dmaReq, SEGMENT_START(code), SEGMENT_ROM_START(code), + SEGMENT_ROM_END(code) - SEGMENT_ROM_START(code), 0, &queue, 0); Idle_InitScreen(); Idle_InitMemory(); osRecvMesg(&queue, NULL, 1); sDmaMgrDmaBuffSize = oldSize; - Idle_ClearMemory(_codeSegmentBssStart, _codeSegmentBssEnd); + Idle_ClearMemory(SEGMENT_BSS_START(code), SEGMENT_BSS_END(code)); } void Main_ThreadEntry(void* arg) { diff --git a/src/boot_O2_g3/z_std_dma.c b/src/boot_O2_g3/z_std_dma.c index 5a29d5d56..3a447b0e8 100644 --- a/src/boot_O2_g3/z_std_dma.c +++ b/src/boot_O2_g3/z_std_dma.c @@ -213,8 +213,7 @@ void DmaMgr_Start(void) { DmaEntry* iter; u32 idx; - DmaMgr_DMARomToRam((u32)_dmadataSegmentRomStart, (u32)dmadata, - (u32)_dmadataSegmentRomEnd - (u32)_dmadataSegmentRomStart); + DmaMgr_DMARomToRam(SEGMENT_ROM_START(dmadata), dmadata, SEGMENT_ROM_SIZE(dmadata)); dummy_label:; -- cgit v1.2.3