Skip to navigation

Elite on the BBC Micro

Workspaces: ZP [Electron version, Loader]

Name: ZP [Show more] Type: Workspace Address: &0004 to &0005 and &0070 to &0086 Category: Workspaces Summary: Important variables used by the loader
Context: See this workspace in context in the source code Variations: See code variations for this workspace in the different versions References: This workspace is used as follows: * Elite loader (Part 2 of 5) calls ZP * Elite loader (Part 3 of 5) calls ZP * Elite loader (Part 5 of 5) calls ZP * PIX calls ZP * PLL1 calls ZP * ROOT calls ZP * crunchit calls ZP
ORG &0004 .TRTB% SKIP 2 \ Contains the address of the keyboard translation \ table, which is used to translate internal key \ numbers to ASCII ORG &0070 .ZP SKIP 2 \ Stores addresses used for moving content around .P SKIP 1 \ Temporary storage, used in a number of places .Q SKIP 1 \ Temporary storage, used in a number of places .YY SKIP 1 \ Temporary storage, used in a number of places .T SKIP 1 \ Temporary storage, used in a number of places .SC SKIP 1 \ Screen address (low byte) \ \ Elite draws on-screen by poking bytes directly into \ screen memory, and SC(1 0) is typically set to the \ address of the character block containing the pixel \ we want to draw (see the deep dives on "Drawing \ monochrome pixels in mode 4" and "Drawing pixels \ in the Electron version" for more details) .SCH SKIP 1 \ Screen address (high byte) .BLPTR SKIP 2 \ Gets set to &03CA as part of the obfuscation code .V219 SKIP 2 \ Gets set to &0218 as part of the obfuscation code SKIP 4 \ These bytes appear to be unused .K3 SKIP 1 \ Temporary storage, used in a number of places .BLCNT SKIP 2 \ Stores the tape loader block count as part of the copy \ protection code in IRQ1 .BLN SKIP 2 \ Gets set to &03C6 as part of the obfuscation code .EXCN SKIP 2 \ Gets set to &03C2 as part of the obfuscation code