GBAtemp.net - The Independent Video Game Community

Foxi4
Foxi4
Don't we already know that? :P
Coto
Coto
yep, but from ARM9, ARM7 has a different method.. some small algebra is required to reserve an address, and reallocate it for dynamic heap management
Foxi4
Foxi4
Are there any particularly interesting benefits springing from reserving it from ARM7? Isn't the ARM7 core normally responsible for sound, WiFi and other peripheral thigamajigs? :)
Coto
Coto
thanks to ichichfly:
Size = 0x02400000 - ((u32)sbrk(0) + 0x5000 + 0x2000);
buffer = (u8 *)(sbrk(0) + 0x2000/*8K for future alloc*/);
Where size gets the (max GBA ROM address - (dinamic block collector + arm stub + 8k (for user) ). sbrk is a handy way of reusing allocated memory by OS so it points to even newer heap pointers as the program flows.
Coto
Coto
This will be very useful for allocating audio frames on the ARM7 , so timers can interrupt:
65536(timer top) -(ndsclock/wavfrequency or sample rate) per sample. this generates the sample frequency . Given audiowaves use the sine : n samples are known to interrupt at certain speed: (n/speed)*t (digital audio waves require at least amplitude(raw noise), frequency, wave length and speed)
General chit-chat
Help Users
  • No one is chatting at the moment.
    Veho @ Veho: Click on your profile pic in the top right corner, and you'll get the profile menu popup, with... +1