CMD | DICMDBUF0 | DICMDBUF1 | DICMDBUF2 | RET | Description |
DI_INQUIRY | 0x12000000 | - | - | 32 bytes: - Bytes 0-3: 0x00000000; - Bytes 4-7: 0x20196c64; - Bytes 8-11: 0x61000000; - Rest is zeros |
Normal inquiry command. This code can be used to uniquely identify GC Loader. |
DI_GCODE_READ_ID | 0xB0000000 | - | - | 0xAAAAAAAA | Get GCODE ID. |
DI_GCODE_GET_VERSION | 0xB10000yy | - | - |
If yy=1: length of version string (4 bytes) If yy=0: version string (arbitrary nr of bytes) |
Get GCODE firmware version. |
DI_GCODE_READ | 0xB2000000 | ‘Start block’ to read from. | nr of bytes to read | - | Read bytes from SD Card. |
DI_GCODE_SET_DISK_FRAGS | 0xB300000yy | Disc number | If yy=1: nr of frags If yy=2: unused |
If yy = 1: - 0x00: ready to receive frag table - 0x04: Error; Disc number too high (GC Loader supports up to 2 discs) - 0x03: Error; too many fragments (can store up to 40 fragments per disc) If yy=2: - 0x00: Success; changed active disc - 0x04: Error; Disc number too high (GC Loader supports up to 2 discs) |
Set the disk frags or change active disc. yy=1: Initialize frag table transfer yy=2: set active disc |
DI_GCODE_SET_DISK_FRAGS
After initializing a fragment table transfer (DICMDBUF0=0xB3000001), GCLoader expects the actual fragments from the GameCube. In one single transfer, one fragment can be sent. Arguments should be as follows:
- DICMDBUF0: Offset in file (byte offset)
- DICMDBUF1: Size of the fragment (in bytes)
- DICMDBUF2: Sector of the fragment
After each fragment transfer, the GC Loader replies with one of the following values:
- 0x00000000: done; received all fragments.
- 0x00000002: expecting more fragments.