Skip to content

Commit

Permalink
Add docs for VPEEK function
Browse files Browse the repository at this point in the history
  • Loading branch information
jestin committed Jun 12, 2024
1 parent 5420436 commit 6aeefed
Showing 1 changed file with 18 additions and 4 deletions.
22 changes: 18 additions & 4 deletions appendix/basic_commands.tex
Original file line number Diff line number Diff line change
Expand Up @@ -2848,14 +2848,14 @@ \subsection{VPOKE}

\codeblock{

10 FOR I=1 to 256*64 STEP 2\\
10 FOR I=1 TO 256*64 STEP 2\\
20 VPOKE 1,\$B000+I,0 :REM SET COLOR\\
30 NEXT I\\

}

The above BASIC code will fill the screen with black spaces one character at a
time by writing directly to the area of the VERA's VRAM where the X16 stores
The above BASIC program will fill the screen with black spaces one character at
a time by writing directly to the area of the VERA's VRAM where the X16 stores
the text mode screen data. The {\ttfamily VPOKE} sets the background and
forground color to black, although the character data does not change.\\

Expand Down Expand Up @@ -3665,5 +3665,19 @@ \subsection{VAL}

\subsection{VPEEK}

<TODO>
The {\ttfamily VPEEK} function gets a single byte of vidoe RAM (VRAM) from the
VERA's onboard memory. The allows a BASIC program to read the data being
interpreted by the VERA to produce graphics and sound. The {\ttfamily VPEEK}
function takes two arguments: the bank and the memory location within the bank.\\

Example:\\

\codeblock {
10 FOR I=0 TO 256*64-1\\
20 PRINT VPEEK(1,\$B000+I),;\\
30 NEXT I\\
}

The above BASIC program will print out the data being used to display the text
mode screen data, including the attribute data responsible for coloring the
text.\\

0 comments on commit 6aeefed

Please sign in to comment.