Skip to navigation

Elite on the BBC Micro

Workspaces: ZP [Elite-A, I/O processor]

Name: ZP [Show more] Type: Workspace Address: &008B to &009F Category: Workspaces Summary: Important variables used by the I/O processor
Context: See this workspace in context in the source code References: No direct references to this workspace in this source file
ORG &008B .DL SKIP 1 \ Vertical sync flag \ \ DL gets set to 30 every time we reach vertical sync on \ the video system, which happens 50 times a second \ (50Hz). The WSCAN routine uses this to pause until the \ vertical sync, by setting DL to 0 and then monitoring \ its value until it changes to 30 ORG &0090 .key_tube SKIP 2 \ Contains the address of the I/O processor's keyboard \ translation table (as opposed to the parasite's \ table), which is used to translate internal key \ numbers to ASCII in the I/O processor code .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 colour \ pixels in mode 5" for more details) .SCH SKIP 1 \ Screen address (high byte) .font .ZZ .bar_1 .angle_1 .missle_1 .picture_1 .print_bits .X1 SKIP 1 \ Temporary storage, typically used for x-coordinates in \ line-drawing routines .bar_2 .picture_2 .Y1 SKIP 1 \ Temporary storage, typically used for y-coordinates in \ line-drawing routines .bar_3 .K3 .COL .X2 SKIP 1 \ Temporary storage, typically used for x-coordinates in \ line-drawing routines .XSAV2 .Y2 SKIP 1 \ Temporary storage, typically used for y-coordinates in \ line-drawing routines .YSAV2 .P SKIP 1 \ Temporary storage, used in a number of places .T .Q SKIP 1 \ Temporary storage, used in a number of places .R SKIP 1 \ Temporary storage, used in a number of places .S SKIP 1 \ Temporary storage, used in a number of places .SWAP SKIP 1 \ Temporary storage, used to store a flag that records \ whether or not we had to swap a line's start and end \ coordinates around when clipping the line in routine \ LL145 (the flag is used in places like BLINE to swap \ them back) SKIP 1 .XC SKIP 1 \ The x-coordinate of the text cursor (i.e. the text \ column), which can be from 0 to 32 \ \ A value of 0 denotes the leftmost column and 32 the \ rightmost column, but because the top part of the \ screen (the space view) has a white border that \ clashes with columns 0 and 32, text is only shown \ in columns 1-31 .YC SKIP 1 \ The y-coordinate of the text cursor (i.e. the text \ row), which can be from 0 to 23 \ \ The screen actually has 31 character rows if you \ include the dashboard, but the text printing routines \ only work on the top part (the space view), so the \ text cursor only goes up to a maximum of 23, the row \ just before the screen splits \ \ A value of 0 denotes the top row, but because the \ top part of the screen has a white border that clashes \ with row 0, text is always shown at row 1 or greater