Zeropage

The Zero Page (ie literally " page zero") refers to a very limited address space within the RAM or ROM memory ( for a microprocessor ), which is physically seen from the first byte or the first block or just the first " page " of memory.

6502

For the MOS Technology 6502 microprocessor ( a variant of which was built in 6510 known Commodore 64) is the zero page of the first 256 bytes of RAM.

This Page is Zero for machine programs of this processor is of great importance, because some addressing modes can only be used in or with this area. Two consecutive bytes in the zero page can any address up to 64 KB represent (from hex 0000 to hex FFFF ). This is used in the indirect addressing in that it is interpreted as a base address for the access to another memory location.

Examples:

The assembler instruction LDA ($ FE), Y is:    Read the value of the two memory addresses FE Hex and Hex FF and use them to form    an absolute memory address, then add the contents of the Y register to    and fill the accumulator with the contents of the physical address thus formed.    ( " Indirectly - indexed " addressing the Y-register ) The assembler instruction LDA ($ F0, X ) means:    Add the contents of the X register to the hex value F0 and use them to form an address    ( in the zero page ), read the content of this and the following address,    them to form an absolute memory address, and fill the accumulator with the    Contents of absolute address so formed.    ( " Indexed - indirect" addressing with the X- register) Thus, if in the Zero Page, the values ​​of hex or hex FF FE (or the values ​​in the jump destination table from hex F0) change, then the absolute ( or effective ) address which is read changes. This so-called indirect addressing can be performed in this type of processor only on the zero page. The Zero Page acts as a register bank with 128 16 -bit index registers.

Other processors

Even with other microprocessors often have a special meaning, but also entirely different, such as the fixed place for reset and interrupt vectors have those memory areas which are physically seen at the beginning of the memory ( the Motorola 68000 ), or when reset you jumped program section ( the Zilog Z80 ), etc. In these processors, this memory area is not necessarily called Zero Page.

  • Memory management
835911
de