1/*****************************************************************************\
2 Snes9x - Portable Super Nintendo Entertainment System (TM) emulator.
3 This file is licensed under the Snes9x License.
4 For further information, consult the LICENSE file in the root directory.
5\*****************************************************************************/
6
7#ifndef _DMA_H_
8#define _DMA_H_
9
10struct SDMA
11{
12 bool8 ReverseTransfer;
13 bool8 HDMAIndirectAddressing;
14 bool8 UnusedBit43x0;
15 bool8 AAddressFixed;
16 bool8 AAddressDecrement;
17 uint8 TransferMode;
18 uint8 BAddress;
19 uint16 AAddress;
20 uint8 ABank;
21 uint16 DMACount_Or_HDMAIndirectAddress;
22 uint8 IndirectBank;
23 uint16 Address;
24 uint8 Repeat;
25 uint8 LineCount;
26 uint8 UnknownByte;
27 uint8 DoTransfer;
28};
29
30#define TransferBytes DMACount_Or_HDMAIndirectAddress
31#define IndirectAddress DMACount_Or_HDMAIndirectAddress
32
33extern struct SDMA DMA[8];
34
35bool8 S9xDoDMA (uint8);
36void S9xStartHDMA (void);
37uint8 S9xDoHDMA (uint8);
38void S9xResetDMA (void);
39
40#endif
41