Absolute Addressing

From NES Hacker Wiki
Jump to: navigation, search

In Zero-Page Addressing, the operand is a memory address rather than a value. Absolute addressing is very similar to Zero-Page Addressing, except that in absolute addressing you must supply the entire 2-byte address, while zero-page addressing only requires the low byte.


Examples

This example uses Absolute Addressing to load the accumulator with whatever value is stored in memory address $16A0. Notice that the address is store in little-endian.

0001:AD A0 16  LDA $16A0       ; Load A with whatever value is in memory address $16A0.


Opcodes

Since Absolute addressing is essentially the same as Zero-Page addressing, they use the same opcodes. The following opcodes support absolute addressing: