This page is a mirror of Tepples' nesdev forum mirror (URL TBD).
Last updated on Oct-18-2019 Download

iNES header macros for ASM6

iNES header macros for ASM6
by on (#67991)
Hey, everyone.

I'm a longtime lurker here and thought I'd finally come out of the shadows and say hi. I've written some macros for ASM6 to help make the process of generating iNES headers a lot simpler and more human-readable, and I thought I'd go ahead and share them. Instead of having to manually code (and de-code) your iNES headers, using these macros you can instead write something like:

INCLUDE iNES_header.asm6

iNES_Mapper iNES_UxROM
iNES_PRG_ROM_Pages 8
iNES_CHR_ROM_Pages 1


...and the macros will automatically generate all of the correct header information. The code is also capable of seamlessly switching from version 1 to (the proposed) version 2 of the iNES standard and will do so transparently without any additional work if the header requires it. All of this is done solely with ASM6 preprocessor directives and requires no external executables or different compilation procedures than what would already be used for your code.

The code should be available from here: I've not used Google to store files before, so if the URL breaks please tell me and I'll find somewhere else to put it.

The source is public domain, so feel free to do whatever you want with it. Use it in any of your projects (paid or otherwise) or print it out and wear it as a hat if you'd like. That said, I'd love it if you let me know if this helps you make something cool - feel free to drop me a line either here on the forums or via email.

Happy coding! (And hi, everybody!)