I've been working on a MOS 6502 core for an 8-bit NES core that I'm putting in a Xilinx 7-Series FPGA. My testbench combines a 64KB block memory with the CPU core. The block memory uses a couple of different input files to specify its initial contents. I had been doing initial programming manually, which was extremely tedious and very error prone. So, I built an assembler to take 6502 assembly source code and assemble it into the coefficients and memory initialization files.
https://github.com/gmcastil/oddballIf anyone else is working on an FPGA-based 6502 design, check it out. The documentation should make it relatively clear what the syntax for the input files are. The output files are full 64KB memory maps that contain assembled source code at the indicated locations. In addition, you can also provide it with a second input file containing a memory map. The assembler will populate the output memory files with whatever additional data is desired. This lets you provide a program (an .asm file) as well as data (a .map file). This is not a particularly normal use case, which explains the name of the project.