Download Print this page

Star Micronics 10X User Manual page 118

Advertisement

I
Gemini User's Manual
- - - - - - - -
extra wait is part of the price for BASIC's simplicity. In addition,
detailed graphics like this involves massive data manipulation.
If for any reason you didn't get an output that looks like it was
supposed to look (compare with Figure 7-5), then turn Gemini "off:'
reset it by turning it back "on:' enter LUST, and compare the resul-
tant printout to see where you went wrong. After you fix the
problem, RUN the program.
Analyzing the Program
110
This program will take about 3 minutes to run. It generates 900
bytes of data that will be printed using the ESC "K" function. The
first part of the program will initialize several constants as well as
an array to store our data. The array MASK%O contains the values
for each dot. Notice that we are using only six dots in this program.
This is to make sure that this program will work with all computers,
even those with 7-bit interfaces. LX and L Y provide a scale for our
image and XFAC and YFAC relate the scale to the overall size of
the image. RAD is the radius of the shape; X1 and Y1 are the
starting points for the curve.
The subroutine that starts at line 1000 will plot the pOints
around the curve and will call the subroutine starting at line 3000
to actually plot the line from Xl Y
1
to X
2
Y
2 •
This subroutine will call
yet another routine starting at line 4000; this routine actually "turns
on" the dots. It stores the element in BIT%O and then uses the
values in MASK%O to turn on the proper dots by use of an OR
function.
Note: Some of the computers used in this book do not have
an OR function; therefore, some of the programs use a machine
language subroutine that will simulate our OR function. This
routine is created by "POKE-ing" data into memory.
The last subroutine starts at line 2000. This subroutine will
get the data and send it to your Gemini printer. The routine star-
ting at line 2020 through 2110 uses a loop to go through the data.
It will print 12 lines and each line contains 375 dots. Data will be
sent to the printer one line at a time. The shape we plot will il-
lustrate our ability to plot mathematical curves. Since we need to
generate high quantities of data through our equations, please
note that it will take a few minutes to use this program.
• •
• •
• •
• •
• •
• •
• •
• •
• •
• •
• •
I

Advertisement

loading

This manual is also suitable for:

15xGemini-10xGemini-15x