I downloaded
lesson1.zip and took a peek. I don't know how this would work exactly with Visual Studio because I'm not familiar with that. There is a general Makefile (GNU-ish, sort of), and also a compile.bat. It appears to have reliance on the cc65 suite and nes.lib. There is indeed a nes.cfg (for ld65). There is a bunch of assembly code also involved. There is an 8kByte .chr file called Alpha.chr that appears to be a basic alphabet, ASCII-mapped.
nes.cfg contains the below (comments removed for brevity):
Code:
MEMORY {
ZP: start = $00, size = $100, type = rw, define = yes;
OAM1: start = $0200, size = $0100, define = yes;
RAM: start = $0300, size = $0400, define = yes;
HEADER: start = $0, size = $10, file = %O ,fill = yes;
PRG: start = $c000, size = $3ffa, file = %O ,fill = yes, define = yes;
VECTORS: start = $fffa, size = $6, file = %O, fill = yes;
CHR: start = $0000, size = $2000, file = %O, fill = yes;
}
SEGMENTS {
HEADER: load = HEADER, type = ro;
STARTUP: load = PRG, type = ro, define = yes;
LOWCODE: load = PRG, type = ro, optional = yes;
INIT: load = PRG, type = ro, define = yes, optional = yes;
CODE: load = PRG, type = ro, define = yes;
RODATA: load = PRG, type = ro, define = yes;
DATA: load = PRG, run = RAM, type = rw, define = yes;
VECTORS: load = VECTORS, type = rw;
CHARS: load = CHR, type = rw;
BSS: load = RAM, type = bss, define = yes;
HEAP: load = RAM, type = bss, optional = yes;
ZEROPAGE: load = ZP, type = zp;
ONCE: load = PRG, type = ro, define = yes;
}
FEATURES {
CONDES: segment = INIT,
type = constructor,
label = __CONSTRUCTOR_TABLE__,
count = __CONSTRUCTOR_COUNT__;
CONDES: segment = RODATA,
type = destructor,
label = __DESTRUCTOR_TABLE__,
count = __DESTRUCTOR_COUNT__;
CONDES: type = interruptor,
segment = RODATA,
label = __INTERRUPTOR_TABLE__,
count = __INTERRUPTOR_COUNT__;
}
SYMBOLS {
__STACKSIZE__: type = weak, value = $0100;
__STACK_START__: type = weak, value = $700;
}
reset.s contains this, which comes after
.segment "VECTORS"; rest of the assembly code omitted for brevity:
Code:
.segment "CHARS"
.incbin "Alpha.chr"