OSDN Git Service

スクリプトファイルの属性を変更
[unagi/old-svn-converted.git] / client / trunk / anago / sunsoft-4.ae
1 board <- {
2         mappernum = 68, ppu_ramfind = false, vram_mirrorfind = false,
3         cpu_rom = {
4                 size_base = 1 * mega, size_max = 2 * mega,
5                 banksize = 0x4000
6         },
7         cpu_ram = {
8                 size_base = 0x2000, size_max = 0x2000, banksize = 0x2000
9         },
10         ppu_rom = {
11                 size_base = 1 * mega, size_max = 2 * mega,
12                 banksize = 0x0800
13         }
14 };
15
16 function cpu_dump(d, pagesize, banksize)
17 {
18         for(local i = 0; i < pagesize - 1; i += 1){
19                 cpu_write(d, 0xf000, i);
20                 cpu_read(d, 0x8000, banksize);
21         }
22         cpu_read(d, 0xc000, banksize);
23 }
24
25 /*
26 After Burner CRC32 list
27 0x88f202f0 Program ROM
28 0x10935d10 Charcter ROM #0
29 0x0bc56f7a Charcter ROM #1
30 0xa75cb06d Charcter ROM #0+#1
31 0xf2ce3641 total
32 */
33 function ppu_dump(d, pagesize, banksize)
34 {
35         //dump uses 0x0000-0x1fff
36 /*      for(local i = 0; i < pagesize; i += 4){
37                 cpu_write(d, 0x8000, i);
38                 cpu_write(d, 0x9000, i | 1);
39                 cpu_write(d, 0xa000, i | 2);
40                 cpu_write(d, 0xb000, i | 3);
41                 ppu_read(d, 0, banksize * 4);
42         }
43         //dump uses 0x2000-0x27ff*/
44 /*      cpu_write(d, 0xe000, 0x10);
45         for(local i = 0; i < pagesize*2; i += 2){
46                 cpu_write(d, 0xc000, i);
47                 cpu_write(d, 0xd000, i | 1);
48                 ppu_read(d, 0x2000, banksize);
49         }*/
50         //dump uses 0x2000-0x23ff*/
51         cpu_write(d, 0xe000, 0x13);
52         for(local i = 0; i < pagesize*2; i += 1){
53                 cpu_write(d, 0xd000, i);
54                 ppu_read(d, 0x2000, 0x400);
55         }
56 }
57
58 function cpu_ram_access(d, pagesize, banksize)
59 {
60         cpu_write(d, 0xf000, 0x10);
61         cpu_ramrw(d, 0x6000, banksize);
62         cpu_write(d, 0xf000, 0);
63 }