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.

Coding > DMA 0, 1, and 2 don't work properly?!

#8587 - regularkid - Tue Jul 15, 2003 9:21 pm

I'm using DMA to clear the screen in mode 4 (filling the video buffer with a certain value....source fixed, destination increment, 16bit word size). Anyways, when I use DMA register 3, everything works perfectly, however when I use DMA registers 0, 1, or 2, they only fill a small part of the video buffer (even though I use the same word size and same number of words to transfer)! Does anyone know why these three DMA registers don't work like register 3? Thanks!
_________________
- RegularKid

#8588 - jma - Tue Jul 15, 2003 9:25 pm

DMA's 0, 1 & 2 can only transfer to/from certain RAM/ROM locations. Check a FAQ or spec sheet to get these (as I don't know them off the top of my head).

IIRC, though, DMA3 is the only one that can write to VRAM.

Jeff
_________________
massung@gmail.com
http://www.retrobyte.org

#8591 - regularkid - Tue Jul 15, 2003 11:24 pm

Thanks!
_________________
- RegularKid

#8592 - tepples - Tue Jul 15, 2003 11:29 pm

According to the CowBite spec:

DMA[0] cannot transfer from ROM; the rest can.
DMA[3] can transfer to ROM (for specialty hardware on the hardware); the rest can't.

In addition, DMA[0], DMA[1], and DMA[2] are limited to 16,384 word transfers. DMA[3] can move 65,536 words in a single transfer.
_________________
-- Where is he?
-- Who?
-- You know, the human.
-- I think he moved to Tilwick.