# 16K iNES ROM with some CHR MEMORY { ZP: start = $004, size = $0FC; STACK: start = $100, size = $100; RAM: start = $200, size = $600; HEADER: start = 0, size = $10, fill=yes, fillval=$00; ROM: start = $C000, size = $4000, fill=yes, fillval=$FF; CHARS: start = 0, size = $8000, fillval=$FF; } SEGMENTS { LIB_TEMPS: load = ZP, type = zp; TEST_RESULTS: load = ZP, type = zp; ZEROPAGE: load = ZP, type = zp; STACK: load = STACK, type = bss, optional=yes; TEMPLATE_BUF:load = RAM, type = bss, align=$10, optional=yes; OAM_BUF: load = RAM, type = bss, align=$100; CODE_BUF: load = RAM, type = bss, align=$100; BSS: load = RAM, type = bss, optional=yes; HEADER: load = HEADER, type = ro; FILLER: load = ROM, type = ro, start=$C000; # CODE: load = ROM, type = ro, align=$1; LIB: load = ROM, type = ro, align=$2; CHARS_PRG: load = ROM, type = ro, align=$200, optional=yes; CHARS_PRG_ASCII:load = ROM, type = ro, align=$200, optional=yes; POINTERS: load = ROM, type = ro, align=$2; RODATA: load = ROM, type = ro, align=$1; TEMPLATE2: load = ROM, type = ro, align=$1; DMA_TEST_MATERIAL: load = ROM, type = ro, align=$100; TEMPLATE1: load = ROM, type = ro, align=$1; # Note: Delay routines must not page-wrap. # Unfortunately, the linker script has no means to specify # this fact, other than to by specifying an "align" value, # which is not quite the same thing. In order to have them # properly stored without excess space, we use an explicit # starting address. It's a cheap solution. DELAY_65536YXA: load = ROM, type = ro, start=$FF66; DELAY_256: load = ROM, type = ro, start=$FFBC; DELAY_65536: load = ROM, type = ro, start=$FFCE; VECTORS: load = ROM, type = ro, start=$FFF4; # Bank 0: # 0: ASCII # 1: PART3 BG + PART3 SP CHARS: load = CHARS, type = ro; CHARS_GFX3b: load = CHARS, type = ro, start = $1000; # Bank 1: # 0: CODE + PART2 SP # 1: PART2 BG # CHARS_P2: load = CHARS, type = ro, start = $2000; CHARS_6C00: load = CHARS, type = ro, start = $2BE0; CHARS_GFX2: load = CHARS, type = ro, start = $3000; # Bank 2: # 0: PART1 SP + PART4 BG + PART4 SP # 1: PART1 BG CHARS_SPR1: load = CHARS, type = ro, start = $4000; CHARS_GFX3a: load = CHARS, type = ro, start = $42C0; CHARS_GFX1: load = CHARS, type = ro, start = $5000; CHARS_P4: load = CHARS, type = ro, start = $6000; }