The NES Interrupt Vectors are pointers to interrupt functions in code which gets executed upon certain events.
Vector Declarations
#startfunction
The #start directive specifies the function which the start (reset) interrupt vector should point to. When the NES is turned on or reset, this function will be executed.
Examples
#start main
interrupt main() { // main code }
#nmifunction
The #nmi directive specifies the function which the non maskable (vblank) interrupt vector should point to. When the NES' screen refresh is complete, the nmi interrupt function is executed. It is called on a 60hz basis on NTSC systems, and 50hz on PAL. It can be used for timing as well as writing to the video RAM. Writes to the video RAM during the screen refresh will usually cause serious problems with the graphics, so to write to it, you should either do it during the nmi or turn the screen off first.
Examples
#nmi vblank
interrupt vblank() { // vblank code }
#irqfunction
The #irq directive specifies the function which the interrupt request vector should point to. Mappers control the IRQ, and it is generally executed upon hblank (when a scanline is complete), but can be controlled to execute on any event the mapper needs.