gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

DS development > Write to WRAM from ARM7 hangs

#107097 - Lick - Thu Oct 26, 2006 3:22 pm

Code:

    u8   *arm7boot       = (u8*)(0x02100000);
    memcpy((void*)0x037FA800, arm7boot, 272);


The ARM7 hangs at memcpy(). How could that possibly be? :(

- Lick
_________________
http://licklick.wordpress.com

#107175 - masscat - Fri Oct 27, 2006 11:30 am

Have you given the ARM7 access to the shared memory region (0x3000000h-0x37FFFFF)? Otherwise you will be writing to a mirror of ARM7's private memory according to gdbtek.

#107179 - Lick - Fri Oct 27, 2006 12:52 pm

Fixed it. That location was hardcoded, while it should actually be read from the firmware. I am not sure what it was, but possibly memcpy overwriting it's own piece of code.
_________________
http://licklick.wordpress.com